public class ModulePrefs extends Object
| Constructor and Description |
|---|
ModulePrefs(Element element,
Uri base) |
| Modifier and Type | Method and Description |
|---|---|
List<Feature> |
getAllFeatures()
All features elements defined in ModulePrefs
|
String |
getAttribute(String name) |
String |
getAttribute(String name,
String defaultValue) |
String |
getAuthor()
ModulePrefs@author
Message Bundles
|
String |
getAuthorAboutme()
ModulePrefs@author_aboutme
Message Bundles
|
String |
getAuthorAffiliation()
ModulePrefs@author_affiliation
Message Bundles
|
String |
getAuthorEmail()
ModulePrefs@author_email
Message Bundles
|
Uri |
getAuthorLink()
ModulePrefs@author_link
Message Bundles
|
String |
getAuthorLocation()
ModulePrefs@author_location
Message Bundles
|
Uri |
getAuthorPhoto()
ModulePrefs@author_photo
Message Bundles
|
String |
getAuthorQuote()
ModulePrefs@author_quote
Message Bundles
|
boolean |
getBoolAttribute(String name) |
List<String> |
getCategories() |
String |
getDescription()
ModulePrefs@description
Message Bundles
|
String |
getDirectoryTitle()
ModulePrefs@directory_title
Message Bundles
|
String |
getDoctype()
Returns this Gadget's doctype mode.
|
com.google.common.collect.Multimap<String,Node> |
getExtraElements() |
Map<String,Feature> |
getFeatures()
All features are included in ModulePrefs.
|
LocaleSpec |
getGlobalLocale(Locale locale)
Gets the global locale spec for the given locale, if any exists.
|
int |
getHeight()
ModuleSpec@height
|
List<Icon> |
getIcons() |
int |
getIntAttribute(String name) |
Map<String,LinkSpec> |
getLinks() |
LocaleSpec |
getLocale(Locale locale,
String view)
Gets the locale spec for the given locale and view, if any exists.
|
Map<Locale,LocaleSpec> |
getLocales() |
OAuth2Spec |
getOAuth2Spec() |
OAuthSpec |
getOAuthSpec() |
List<Preload> |
getPreloads() |
boolean |
getScaling()
ModulePrefs@scaling
|
Uri |
getScreenshot()
ModulePrefs@screenshot
Message Bundles
|
boolean |
getScrolling()
ModulePrefs@scrolling
|
boolean |
getShowInDirectory()
ModulePrefs@show_in_directory
|
boolean |
getShowStats()
ModulePrefs@show_stats
|
boolean |
getSingleton()
ModulePrefs@singleton
|
Uri |
getThumbnail()
ModulePrefs@thumbnail
Message Bundles
|
String |
getTitle()
ModulePrefs@title
User Pref + Message Bundle + Bidi
|
Uri |
getTitleUrl()
ModulePrefs@title_url
User Pref + Message Bundle + Bidi
|
Uri |
getUriAttribute(String name) |
Map<String,Feature> |
getViewFeatures(String view)
Returns Map of features to load for the given View
|
int |
getWidth()
ModuleSpec@width
|
boolean |
needsUserPrefSubstitution()
Note: not part of the spec.
|
ModulePrefs |
substitute(Substitutions substituter)
Produces a new ModulePrefs by substituting hangman variables from
substituter.
|
String |
toString() |
public ModulePrefs(Element element, Uri base) throws SpecParserException
SpecParserExceptionpublic String getTitle()
public Uri getTitleUrl()
public String getDescription()
public String getAuthor()
public String getAuthorEmail()
public Uri getScreenshot()
public Uri getThumbnail()
public String getDirectoryTitle()
public String getAuthorAffiliation()
public String getAuthorLocation()
public Uri getAuthorPhoto()
public String getAuthorAboutme()
public String getAuthorQuote()
public Uri getAuthorLink()
public boolean getShowStats()
public boolean getShowInDirectory()
public boolean getSingleton()
public boolean getScaling()
public boolean getScrolling()
public int getWidth()
public int getHeight()
public String getDoctype()
public String getAttribute(String name)
name - the attribute namepublic String getAttribute(String name, String defaultValue)
name - the attribute namedefaultValue - the default Valuepublic Uri getUriAttribute(String name)
name - the attribute namepublic boolean getBoolAttribute(String name)
name - the attribute namepublic int getIntAttribute(String name)
name - the attribute namepublic List<String> getCategories()
public Map<String,Feature> getFeatures()
public List<Feature> getAllFeatures()
public Map<String,Feature> getViewFeatures(String view)
public List<Preload> getPreloads()
public Map<Locale,LocaleSpec> getLocales()
public Map<String,LinkSpec> getLinks()
public OAuthSpec getOAuthSpec()
public OAuth2Spec getOAuth2Spec()
public com.google.common.collect.Multimap<String,Node> getExtraElements()
public boolean needsUserPrefSubstitution()
public LocaleSpec getGlobalLocale(Locale locale)
public LocaleSpec getLocale(Locale locale, String view)
public ModulePrefs substitute(Substitutions substituter)
substituter - the substituter to executeCopyright © 2007-2014 The Apache Software Foundation. All Rights Reserved.