|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectcom.android.sdklib.repository.local.PackageParserUtils
public class PackageParserUtils
Misc utilities to help extracting elements and attributes out of a repository XML document.
Constructor Summary | |
---|---|
PackageParserUtils()
|
Method Summary | |
---|---|
static java.lang.String |
getProperty(java.util.Properties props,
java.lang.String propKey,
java.lang.String defaultValue)
Utility method that returns a property from a Properties object. |
static com.android.repository.Revision |
getRevisionProperty(java.util.Properties props,
java.lang.String propKey)
Utility method to parse the PkgProps.PKG_REVISION property as a revision
(major.minor.micro.preview). |
static java.util.List<java.io.File> |
parseSkinFolder(java.io.File skinRootFolder,
com.android.repository.io.FileOp fileOp)
Parses the skin folder and builds the skin list. |
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Constructor Detail |
---|
public PackageParserUtils()
Method Detail |
---|
@Nullable public static com.android.repository.Revision getRevisionProperty(@Nullable java.util.Properties props, @NonNull java.lang.String propKey)
PkgProps.PKG_REVISION
property as a revision
(major.minor.micro.preview).
props
- The properties to parse.propKey
- The name of the property. Must not be null.
Revision
or null if there is no such property or it couldn't be parsed.@Nullable public static java.lang.String getProperty(@Nullable java.util.Properties props, @NonNull java.lang.String propKey, @Nullable java.lang.String defaultValue)
Properties
object. Returns the default
value if props is null or if the property is not defined.
props
- The Properties
to search into. If null, the default value is
returned.propKey
- The name of the property. Must not be null.defaultValue
- The default value to return if props
is null or if the key is not
found. Can be null.
props
is null.@NonNull public static java.util.List<java.io.File> parseSkinFolder(@NonNull java.io.File skinRootFolder, @NonNull com.android.repository.io.FileOp fileOp)
skinRootFolder
- The path to the skin root folder.
|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |