aQute.lib.env
Class Header

java.lang.Object
  extended by aQute.lib.env.Header
All Implemented Interfaces:
Map<String,Props>

public class Header
extends Object
implements Map<String,Props>


Nested Class Summary
 
Nested classes/interfaces inherited from interface java.util.Map
Map.Entry<K,V>
 
Field Summary
static char DUPLICATE_MARKER
           
static Pattern TOKEN_P
           
 
Constructor Summary
Header()
           
Header(String header)
           
Header(String header, Reporter reporter)
           
 
Method Summary
 void add(String key, Props attrs)
           
 void append(StringBuilder sb)
           
 Map<String,? extends Map<String,String>> asMapMap()
           
 void clear()
           
 boolean containsKey(Object name)
          Deprecated. 
 boolean containsKey(String name)
           
 boolean containsValue(Object value)
          Deprecated. 
 boolean containsValue(Props value)
           
 Set<Map.Entry<String,Props>> entrySet()
           
 boolean equals(Object other)
          Deprecated. 
 Props get(Object key)
          Deprecated. 
 Props get(String key)
           
 int hashCode()
          Deprecated. 
static boolean isDuplicate(String name)
           
 boolean isEmpty()
           
 boolean isEqual(Header other)
           
 Set<String> keySet()
           
static Header parseHeader(String value)
           
static Header parseHeader(String value, Reporter logger)
          Standard OSGi header parser.
static Header parseHeader(String value, Reporter logger, Header result)
           
static Props parseProperties(String input)
           
static Props parseProperties(String input, Reporter logger)
           
 Props put(String key, Props value)
           
 void putAll(Map<? extends String,? extends Props> map)
           
 void putAllIfAbsent(Map<String,? extends Props> map)
           
static boolean quote(Appendable sb, String value)
           
 Props remove(Object var0)
          Deprecated. 
 Props remove(String var0)
           
static String removeDuplicateMarker(String key)
           
 int size()
           
 String toString()
           
 Collection<Props> values()
           
 
Methods inherited from class java.lang.Object
clone, finalize, getClass, notify, notifyAll, wait, wait, wait
 

Field Detail

TOKEN_P

public static final Pattern TOKEN_P

DUPLICATE_MARKER

public static final char DUPLICATE_MARKER
See Also:
Constant Field Values
Constructor Detail

Header

public Header()

Header

public Header(String header)

Header

public Header(String header,
              Reporter reporter)
Method Detail

clear

public void clear()
Specified by:
clear in interface Map<String,Props>

add

public void add(String key,
                Props attrs)

containsKey

public boolean containsKey(String name)

containsKey

@Deprecated
public boolean containsKey(Object name)
Deprecated. 

Specified by:
containsKey in interface Map<String,Props>

containsValue

public boolean containsValue(Props value)

containsValue

@Deprecated
public boolean containsValue(Object value)
Deprecated. 

Specified by:
containsValue in interface Map<String,Props>

entrySet

public Set<Map.Entry<String,Props>> entrySet()
Specified by:
entrySet in interface Map<String,Props>

get

@Deprecated
public Props get(Object key)
Deprecated. 

Specified by:
get in interface Map<String,Props>

get

public Props get(String key)

isEmpty

public boolean isEmpty()
Specified by:
isEmpty in interface Map<String,Props>

keySet

public Set<String> keySet()
Specified by:
keySet in interface Map<String,Props>

put

public Props put(String key,
                 Props value)
Specified by:
put in interface Map<String,Props>

putAll

public void putAll(Map<? extends String,? extends Props> map)
Specified by:
putAll in interface Map<String,Props>

putAllIfAbsent

public void putAllIfAbsent(Map<String,? extends Props> map)

remove

@Deprecated
public Props remove(Object var0)
Deprecated. 

Specified by:
remove in interface Map<String,Props>

remove

public Props remove(String var0)

size

public int size()
Specified by:
size in interface Map<String,Props>

values

public Collection<Props> values()
Specified by:
values in interface Map<String,Props>

toString

public String toString()
Overrides:
toString in class Object

append

public void append(StringBuilder sb)

equals

@Deprecated
public boolean equals(Object other)
Deprecated. 

Specified by:
equals in interface Map<String,Props>
Overrides:
equals in class Object

hashCode

@Deprecated
public int hashCode()
Deprecated. 

Specified by:
hashCode in interface Map<String,Props>
Overrides:
hashCode in class Object

isEqual

public boolean isEqual(Header other)

asMapMap

public Map<String,? extends Map<String,String>> asMapMap()

parseHeader

public static Header parseHeader(String value)

parseHeader

public static Header parseHeader(String value,
                                 Reporter logger)
Standard OSGi header parser. This parser can handle the format clauses ::= clause ( ',' clause ) + clause ::= name ( ';' name ) (';' key '=' value ) This is mapped to a Map { name => Map { attr|directive => value } }

Parameters:
value - A string
Returns:
a Map>

parseHeader

public static Header parseHeader(String value,
                                 Reporter logger,
                                 Header result)

parseProperties

public static Props parseProperties(String input)

parseProperties

public static Props parseProperties(String input,
                                    Reporter logger)

removeDuplicateMarker

public static String removeDuplicateMarker(String key)

isDuplicate

public static boolean isDuplicate(String name)

quote

public static boolean quote(Appendable sb,
                            String value)
                     throws IOException
Parameters:
sb -
value -
Returns:
Throws:
IOException


Copyright © 2014 aQute SARL. All rights reserved.