|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectorg.apache.felix.bundlerepository.metadataparser.MetadataHandler
public abstract class MetadataHandler
Field Summary | |
---|---|
protected XmlCommonHandler |
handler
|
Constructor Summary | |
---|---|
MetadataHandler()
constructor |
Method Summary | |
---|---|
void |
addPI(java.lang.String piname,
java.lang.Class clazz)
Add a type to process the processing instruction |
void |
addType(java.lang.String qname,
java.lang.Object instanceFactory)
Add a type for a element |
void |
addType(java.lang.String qname,
java.lang.Object instanceFactory,
java.lang.Class castClass)
Add a type for a element |
void |
addType(java.lang.String qname,
java.lang.Object instanceFactory,
java.lang.Class castClass,
java.lang.reflect.Method defaultAddMethod)
Add a type for a element |
java.lang.Object |
getMetadata()
return the metadata after the parsing |
abstract void |
parse(java.io.InputStream is)
Called to parse the InputStream and set bundle list and package hash map |
void |
setDefaultType(java.lang.Object instanceFactory)
Add a type for the default element |
void |
setDefaultType(java.lang.Object instanceFactory,
java.lang.Class castClass)
Add a type for the default element |
void |
setDefaultType(java.lang.Object instanceFactory,
java.lang.Class castClass,
java.lang.reflect.Method defaultAddMethod)
Add a type for the default element |
void |
setMissingPIExceptionFlag(boolean flag)
set the missing PI exception flag. |
void |
setTrace(boolean trace)
|
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Field Detail |
---|
protected XmlCommonHandler handler
Constructor Detail |
---|
public MetadataHandler()
Method Detail |
---|
public abstract void parse(java.io.InputStream is) throws java.lang.Exception
java.lang.Exception
public final java.lang.Object getMetadata()
public final void addType(java.lang.String qname, java.lang.Object instanceFactory) throws java.lang.Exception
qname
- the name of the element to processinstanceFactory
- the factory of objects representing an element. Must have a newInstance method. could be a class.
java.lang.Exception
public final void addType(java.lang.String qname, java.lang.Object instanceFactory, java.lang.Class castClass) throws java.lang.Exception
qname
- the name of the element to processinstanceFactory
- the factory of objects representing an element. Must have a newInstance method. could be a class.castClass
- the class used to introspect the adder/setter and parameters in parent adder/setter. if null the castClass is by default the class returned by the newInstance method of the instanceFactory.
java.lang.Exception
public final void addType(java.lang.String qname, java.lang.Object instanceFactory, java.lang.Class castClass, java.lang.reflect.Method defaultAddMethod) throws java.lang.Exception
qname
- the name of the element to processinstanceFactory
- the factory of objects representing an element. Must have a newInstance method. could be a class.castClass
- the class used to introspect the adder/setter and parameters in parent adder/setter. if null the castClass is by default the class returned by the newInstance method of the instanceFactory.defaultAddMethod
- the method used to add the sub-elements and attributes if no adder/setter is founded. could be omitted.
java.lang.Exception
public final void setDefaultType(java.lang.Object instanceFactory) throws java.lang.Exception
instanceFactory
- the factory of objects representing an element. Must have a newInstance method. could be a class.
java.lang.Exception
public final void setDefaultType(java.lang.Object instanceFactory, java.lang.Class castClass) throws java.lang.Exception
instanceFactory
- the factory of objects representing an element. Must have a newInstance method. could be a class.castClass
- the class used to introspect the adder/setter and parameters in parent adder/setter. if null the castClass is by default the class returned by the newInstance method of the instanceFactory.
java.lang.Exception
public final void setDefaultType(java.lang.Object instanceFactory, java.lang.Class castClass, java.lang.reflect.Method defaultAddMethod) throws java.lang.Exception
instanceFactory
- the factory of objects representing an element. Must have a newInstance method. could be a class.castClass
- the class used to introspect the adder/setter and parameters in parent adder/setter. if null the castClass is by default the class returned by the newInstance method of the instanceFactory.defaultAddMethod
- the method used to add the sub-elements and attributes if no adder/setter is founded. could be omitted.
java.lang.Exception
public final void addPI(java.lang.String piname, java.lang.Class clazz)
piname
- clazz
- public final void setMissingPIExceptionFlag(boolean flag)
flag
- public final void setTrace(boolean trace)
trace
-
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |