本文整理了Java中aQute.bnd.osgi.Builder.parseHeader()
方法的一些代码示例,展示了Builder.parseHeader()
的具体用法。这些代码示例主要来源于Github
/Stackoverflow
/Maven
等平台,是从一些精选项目中提取出来的代码,具有较强的参考意义,能在一定程度帮忙到你。Builder.parseHeader()
方法的具体详情如下:
包路径:aQute.bnd.osgi.Builder
类名称:Builder
方法名:parseHeader
暂无
代码示例来源:origin: biz.aQute.bnd/bndlib
private void doIncludeResource(Jar jar, String includes) throws Exception {
Parameters clauses = parseHeader(includes);
doIncludeResource(jar, clauses);
}
代码示例来源:origin: biz.aQute.bnd/biz.aQute.bndlib
private void doIncludeResource(Jar jar, String includes) throws Exception {
Parameters clauses = parseHeader(includes);
doIncludeResource(jar, clauses);
}
代码示例来源:origin: biz.aQute/bndlib
private void doIncludeResource(Jar jar, String includes) throws Exception {
Parameters clauses = parseHeader(includes);
doIncludeResource(jar, clauses);
}
代码示例来源:origin: biz.aQute.bnd/bnd
private void doIncludeResource(Jar jar, String includes) throws Exception {
Parameters clauses = parseHeader(includes);
doIncludeResource(jar, clauses);
}
代码示例来源:origin: biz.aQute.bnd/biz.aQute.bnd
private void doIncludeResource(Jar jar, String includes) throws Exception {
Parameters clauses = parseHeader(includes);
doIncludeResource(jar, clauses);
}
代码示例来源:origin: biz.aQute/bndlib
Map<Instruction,Map<String,String>> getMakeHeader() {
if (make != null)
return make;
make = Processor.newMap();
String s = builder.getProperty(Builder.MAKE);
Parameters make = builder.parseHeader(s);
for (Entry<String,Attrs> entry : make.entrySet()) {
String pattern = Processor.removeDuplicateMarker(entry.getKey());
Instruction instr = new Instruction(pattern);
this.make.put(instr, entry.getValue());
}
return this.make;
}
}
代码示例来源:origin: biz.aQute.bnd/bnd
Map<Instruction,Map<String,String>> getMakeHeader() {
if (make != null)
return make;
make = Processor.newMap();
String s = builder.getProperty(Builder.MAKE);
Parameters make = builder.parseHeader(s);
for (Entry<String,Attrs> entry : make.entrySet()) {
String pattern = Processor.removeDuplicateMarker(entry.getKey());
Instruction instr = new Instruction(pattern);
this.make.put(instr, entry.getValue());
}
return this.make;
}
}
代码示例来源:origin: biz.aQute.bnd/bndlib
Map<Instruction,Map<String,String>> getMakeHeader() {
if (make != null)
return make;
make = Processor.newMap();
String s = builder.getProperty(Builder.MAKE);
Parameters make = builder.parseHeader(s);
for (Entry<String,Attrs> entry : make.entrySet()) {
String pattern = Processor.removeDuplicateMarker(entry.getKey());
Instruction instr = new Instruction(pattern);
this.make.put(instr, entry.getValue());
}
return this.make;
}
}
代码示例来源:origin: biz.aQute/bndlib
public Collection<File> getSourcePath() {
if (firstUse) {
firstUse = false;
String sp = getProperty(SOURCEPATH);
if (sp != null) {
Parameters map = parseHeader(sp);
for (Iterator<String> i = map.keySet().iterator(); i.hasNext();) {
String file = i.next();
if (!isDuplicate(file)) {
File f = getFile(file);
if (!f.isDirectory()) {
error("Adding a sourcepath that is not a directory: " + f);
} else {
sourcePath.add(f);
}
}
}
}
}
return sourcePath;
}
代码示例来源:origin: biz.aQute.bnd/bnd
public Collection<File> getSourcePath() {
if (firstUse) {
firstUse = false;
String sp = getProperty(SOURCEPATH);
if (sp != null) {
Parameters map = parseHeader(sp);
for (Iterator<String> i = map.keySet().iterator(); i.hasNext();) {
String file = i.next();
if (!isDuplicate(file)) {
File f = getFile(file);
if (!f.isDirectory()) {
error("Adding a sourcepath that is not a directory: " + f);
} else {
sourcePath.add(f);
}
}
}
}
}
return sourcePath;
}
代码示例来源:origin: biz.aQute.bnd/bndlib
public Collection<File> getSourcePath() {
if (firstUse) {
firstUse = false;
String sp = getProperty(SOURCEPATH);
if (sp != null) {
Parameters map = parseHeader(sp);
for (Iterator<String> i = map.keySet().iterator(); i.hasNext();) {
String file = i.next();
if (!isDuplicate(file)) {
File f = getFile(file);
if (!f.isDirectory()) {
error("Adding a sourcepath that is not a directory: " + f);
} else {
sourcePath.add(f);
}
}
}
}
}
return sourcePath;
}
代码示例来源:origin: biz.aQute.bnd/biz.aQute.bndlib
/**
* Sign the jar file. -sign : <alias> [ ';' 'password:=' <password> ] [ ';'
* 'keystore:=' <keystore> ] [ ';' 'sign-password:=' <pw> ] ( ',' ... )*
*/
void sign(@SuppressWarnings("unused") Jar jar) throws Exception {
String signing = getProperty(SIGN);
if (signing == null)
return;
logger.debug("Signing {}, with {}", getBsn(), signing);
List<SignerPlugin> signers = getPlugins(SignerPlugin.class);
Parameters infos = parseHeader(signing);
for (Entry<String, Attrs> entry : infos.entrySet()) {
for (SignerPlugin signer : signers) {
signer.sign(this, entry.getKey());
}
}
}
代码示例来源:origin: biz.aQute.bnd/biz.aQute.bnd
/**
* Sign the jar file. -sign : <alias> [ ';' 'password:=' <password> ] [ ';'
* 'keystore:=' <keystore> ] [ ';' 'sign-password:=' <pw> ] ( ',' ... )*
*/
void sign(@SuppressWarnings("unused") Jar jar) throws Exception {
String signing = getProperty(SIGN);
if (signing == null)
return;
logger.debug("Signing {}, with {}", getBsn(), signing);
List<SignerPlugin> signers = getPlugins(SignerPlugin.class);
Parameters infos = parseHeader(signing);
for (Entry<String, Attrs> entry : infos.entrySet()) {
for (SignerPlugin signer : signers) {
signer.sign(this, entry.getKey());
}
}
}
代码示例来源:origin: biz.aQute.bnd/biz.aQute.bndlib
public Collection<File> getSourcePath() {
if (firstUse) {
firstUse = false;
String sp = mergeProperties(SOURCEPATH);
if (sp != null) {
Parameters map = parseHeader(sp);
for (Iterator<String> i = map.keySet()
.iterator(); i.hasNext();) {
String file = i.next();
if (!isDuplicate(file)) {
File f = getFile(file);
if (!f.isDirectory()) {
error("Adding a sourcepath that is not a directory: %s", f).header(SOURCEPATH)
.context(file);
} else {
sourcePath.add(f);
}
}
}
}
}
return sourcePath;
}
代码示例来源:origin: biz.aQute.bnd/biz.aQute.bnd
public Collection<File> getSourcePath() {
if (firstUse) {
firstUse = false;
String sp = mergeProperties(SOURCEPATH);
if (sp != null) {
Parameters map = parseHeader(sp);
for (Iterator<String> i = map.keySet()
.iterator(); i.hasNext();) {
String file = i.next();
if (!isDuplicate(file)) {
File f = getFile(file);
if (!f.isDirectory()) {
error("Adding a sourcepath that is not a directory: %s", f).header(SOURCEPATH)
.context(file);
} else {
sourcePath.add(f);
}
}
}
}
}
return sourcePath;
}
代码示例来源:origin: biz.aQute.bnd/biz.aQute.bndlib
/**
* Turn this normal bundle in a web and add any resources.
*
* @throws Exception
*/
private Jar doWab(Jar dot) throws Exception {
String wab = getProperty(WAB);
String wablib = getProperty(WABLIB);
if (wab == null && wablib == null)
return dot;
logger.debug("wab {} {}", wab, wablib);
setBundleClasspath(append("WEB-INF/classes", getProperty(BUNDLE_CLASSPATH)));
Set<String> paths = new HashSet<>(dot.getResources()
.keySet());
for (String path : paths) {
if (path.indexOf('/') > 0 && !Character.isUpperCase(path.charAt(0))) {
logger.debug("wab: moving: {}", path);
dot.rename(path, "WEB-INF/classes/" + path);
}
}
Parameters clauses = parseHeader(getProperty(WABLIB));
for (Map.Entry<String, Attrs> entry : clauses.entrySet()) {
File f = getFile(entry.getKey());
addWabLib(dot, f, entry.getKey(), entry.getValue());
}
doIncludeResource(dot, wab);
return dot;
}
代码示例来源:origin: biz.aQute/bndlib
/**
* Sign the jar file. -sign : <alias> [ ';' 'password:=' <password> ] [ ';'
* 'keystore:=' <keystore> ] [ ';' 'sign-password:=' <pw> ] ( ',' ... )*
*
* @return
*/
void sign(@SuppressWarnings("unused") Jar jar) throws Exception {
String signing = getProperty("-sign");
if (signing == null)
return;
trace("Signing %s, with %s", getBsn(), signing);
List<SignerPlugin> signers = getPlugins(SignerPlugin.class);
Parameters infos = parseHeader(signing);
for (Entry<String,Attrs> entry : infos.entrySet()) {
for (SignerPlugin signer : signers) {
signer.sign(this, entry.getKey());
}
}
}
代码示例来源:origin: biz.aQute.bnd/bndlib
/**
* Sign the jar file. -sign : <alias> [ ';' 'password:=' <password> ] [ ';'
* 'keystore:=' <keystore> ] [ ';' 'sign-password:=' <pw> ] ( ',' ... )*
*
* @return
*/
void sign(@SuppressWarnings("unused")
Jar jar) throws Exception {
String signing = getProperty(SIGN);
if (signing == null)
return;
trace("Signing %s, with %s", getBsn(), signing);
List<SignerPlugin> signers = getPlugins(SignerPlugin.class);
Parameters infos = parseHeader(signing);
for (Entry<String,Attrs> entry : infos.entrySet()) {
for (SignerPlugin signer : signers) {
signer.sign(this, entry.getKey());
}
}
}
代码示例来源:origin: biz.aQute.bnd/bnd
/**
* Sign the jar file. -sign : <alias> [ ';' 'password:=' <password> ] [ ';'
* 'keystore:=' <keystore> ] [ ';' 'sign-password:=' <pw> ] ( ',' ... )*
*
* @return
*/
void sign(@SuppressWarnings("unused")
Jar jar) throws Exception {
String signing = getProperty(SIGN);
if (signing == null)
return;
trace("Signing %s, with %s", getBsn(), signing);
List<SignerPlugin> signers = getPlugins(SignerPlugin.class);
Parameters infos = parseHeader(signing);
for (Entry<String,Attrs> entry : infos.entrySet()) {
for (SignerPlugin signer : signers) {
signer.sign(this, entry.getKey());
}
}
}
代码示例来源:origin: biz.aQute/bndlib
/**
* Turn this normal bundle in a web and add any resources.
*
* @throws Exception
*/
private Jar doWab(Jar dot) throws Exception {
String wab = getProperty(WAB);
String wablib = getProperty(WABLIB);
if (wab == null && wablib == null)
return dot;
trace("wab %s %s", wab, wablib);
setBundleClasspath(append("WEB-INF/classes", getProperty(BUNDLE_CLASSPATH)));
Set<String> paths = new HashSet<String>(dot.getResources().keySet());
for (String path : paths) {
if (path.indexOf('/') > 0 && !Character.isUpperCase(path.charAt(0))) {
trace("wab: moving: %s", path);
dot.rename(path, "WEB-INF/classes/" + path);
}
}
Parameters clauses = parseHeader(getProperty(WABLIB));
for (String key : clauses.keySet()) {
File f = getFile(key);
addWabLib(dot, f);
}
doIncludeResource(dot, wab);
return dot;
}
内容来源于网络,如有侵权,请联系作者删除!