public class DefaultAboutManager extends java.lang.Object implements AboutManager
Modifier and Type | Field and Description |
---|---|
protected java.util.List<AboutDeveloper> |
developers |
protected int |
ICON_SIZE |
protected DefaultAboutProject |
root |
protected java.util.List<AboutSponsor> |
sponsors |
protected java.util.List<AboutTranslator> |
translators |
Constructor and Description |
---|
DefaultAboutManager() |
Modifier and Type | Method and Description |
---|---|
AboutParticipant |
addDeveloper(java.lang.String name,
java.net.URL description,
int priority)
Add a developer information if not exists
|
AboutParticipant |
addDeveloper(java.lang.String name,
java.net.URL description,
int priority,
java.net.URL icon) |
AboutParticipant |
addSponsor(java.lang.String name,
java.net.URL description,
int priority)
Add a sponsor information if not exists
|
AboutParticipant |
addSponsor(java.lang.String name,
java.net.URL description,
int priority,
java.net.URL icon) |
AboutParticipant |
addTranslator(java.lang.String name,
java.net.URL description,
int priority)
Add a translator information if not exists
|
AboutParticipant |
addTranslator(java.lang.String name,
java.net.URL description,
int priority,
java.net.URL icon) |
java.lang.String |
expandVars(java.lang.String data,
java.util.Map<java.lang.String,java.lang.String> vars) |
javax.swing.JPanel |
getAboutPanel() |
java.util.List<AboutContribution> |
getContributions(AboutParticipant participant) |
AboutDeveloper |
getDeveloper(java.lang.String name) |
java.util.List<AboutDeveloper> |
getDevelopers() |
javax.swing.ImageIcon |
getImageIcon(java.lang.String name) |
javax.swing.ImageIcon |
getImageIcon(java.lang.String name,
java.lang.String defaultName) |
javax.swing.ImageIcon |
getImageIcon(java.net.URL url) |
javax.swing.ImageIcon |
getImageIcon(java.net.URL url,
java.lang.String defaultName) |
AboutProject |
getProject() |
AboutSponsor |
getSponsor(java.lang.String name) |
java.util.List<AboutSponsor> |
getSponsors() |
java.lang.String |
getStringFromFile(java.lang.String filename) |
java.lang.String |
getStringFromUrl(java.net.URL url) |
java.lang.String |
getStringFromUrl(java.net.URL url,
java.util.Map<java.lang.String,java.lang.String> vars) |
AboutTranslator |
getTranslator(java.lang.String name) |
java.util.List<AboutTranslator> |
getTranslators() |
java.lang.String |
getURLBase(java.net.URL fileURL)
Returns the base path of a file URL.
|
void |
setProject(java.lang.String name,
java.net.URL description,
java.net.URL icon) |
void |
setProject(java.lang.String name,
java.net.URL description,
java.net.URL icon,
java.util.Map<java.lang.String,java.lang.String> vars) |
protected java.util.List<AboutDeveloper> developers
protected java.util.List<AboutTranslator> translators
protected java.util.List<AboutSponsor> sponsors
protected DefaultAboutProject root
protected int ICON_SIZE
public void setProject(java.lang.String name, java.net.URL description, java.net.URL icon)
setProject
in interface AboutManager
public void setProject(java.lang.String name, java.net.URL description, java.net.URL icon, java.util.Map<java.lang.String,java.lang.String> vars)
setProject
in interface AboutManager
public AboutParticipant addDeveloper(java.lang.String name, java.net.URL description, int priority)
AboutManager
addDeveloper
in interface AboutManager
public AboutParticipant addDeveloper(java.lang.String name, java.net.URL description, int priority, java.net.URL icon)
addDeveloper
in interface AboutManager
public AboutParticipant addSponsor(java.lang.String name, java.net.URL description, int priority)
AboutManager
addSponsor
in interface AboutManager
public AboutParticipant addSponsor(java.lang.String name, java.net.URL description, int priority, java.net.URL icon)
addSponsor
in interface AboutManager
public AboutParticipant addTranslator(java.lang.String name, java.net.URL description, int priority)
AboutManager
addTranslator
in interface AboutManager
public AboutParticipant addTranslator(java.lang.String name, java.net.URL description, int priority, java.net.URL icon)
addTranslator
in interface AboutManager
public javax.swing.JPanel getAboutPanel()
getAboutPanel
in interface AboutManager
public java.util.List<AboutContribution> getContributions(AboutParticipant participant)
public javax.swing.ImageIcon getImageIcon(java.lang.String name)
public javax.swing.ImageIcon getImageIcon(java.net.URL url)
public javax.swing.ImageIcon getImageIcon(java.lang.String name, java.lang.String defaultName)
public javax.swing.ImageIcon getImageIcon(java.net.URL url, java.lang.String defaultName)
public AboutProject getProject()
getProject
in interface AboutManager
public java.util.List<AboutDeveloper> getDevelopers()
getDevelopers
in interface AboutManager
public java.util.List<AboutSponsor> getSponsors()
getSponsors
in interface AboutManager
public java.util.List<AboutTranslator> getTranslators()
getTranslators
in interface AboutManager
public AboutDeveloper getDeveloper(java.lang.String name)
getDeveloper
in interface AboutManager
public AboutSponsor getSponsor(java.lang.String name)
getSponsor
in interface AboutManager
public AboutTranslator getTranslator(java.lang.String name)
getTranslator
in interface AboutManager
public java.lang.String getStringFromFile(java.lang.String filename) throws java.io.FileNotFoundException, java.io.IOException
java.io.FileNotFoundException
java.io.IOException
public java.lang.String getStringFromUrl(java.net.URL url)
public java.lang.String getStringFromUrl(java.net.URL url, java.util.Map<java.lang.String,java.lang.String> vars)
public java.lang.String expandVars(java.lang.String data, java.util.Map<java.lang.String,java.lang.String> vars)
public java.lang.String getURLBase(java.net.URL fileURL)
AboutManager
The method will simply cut the last path of the URL. For example, if the URL is:
http://www.gvsig.org/docs/file.htmlThe returned base string would be:
http://www.gvsig.org/docs/getURLBase
in interface AboutManager
fileURL
- the URL
of the file