aQute.lib.osgi
Class Instruction
java.lang.Object
aQute.lib.osgi.Instruction
public class Instruction
- extends Object
Instruction
public Instruction(String instruction,
boolean negated)
matches
public boolean matches(String value)
isNegated
public boolean isNegated()
getPattern
public String getPattern()
getPattern
public static Instruction getPattern(String string)
- Convert a string based pattern to a regular expression based pattern.
This is called an instruction, this object makes it easier to handle the
different cases
- Parameters:
string
-
- Returns:
toString
public String toString()
- Overrides:
toString
in class Object
getMatcher
public Matcher getMatcher(String value)
hashCode
public int hashCode()
- Overrides:
hashCode
in class Object
equals
public boolean equals(Object other)
- Overrides:
equals
in class Object
setOptional
public void setOptional()
isOptional
public boolean isOptional()
replaceWithInstruction
public static Map<Instruction,Map<String,String>> replaceWithInstruction(Map<String,Map<String,String>> header)
select
public static <T> Collection<T> select(Collection<Instruction> matchers,
Collection<T> targets)
Copyright © 2012 aQute SARL. All Rights Reserved.