public class RemoteSet extends Object implements Serializable
Modifier and Type | Field and Description |
---|---|
static String |
girrVersion
String of the form major.minor identifying the protocol version
(not to be confused with the version of an implementation).
|
Constructor and Description |
---|
RemoteSet(Document doc)
This constructor is used to import an XML document.
|
RemoteSet(String creatingUser,
String source,
HashMap<String,Remote> remotes)
Convenience version of the many-remote constructor.
|
RemoteSet(String source,
String creatingUser,
IrSignal irSignal,
String name,
String comment,
String deviceName)
This constructor creates a RemoteSet from a single IrSignal.
|
RemoteSet(String creatingUser,
String source,
Remote remote)
Convenience version of the one-remote constructor.
|
RemoteSet(String creatingUser,
String source,
String creationDate,
String tool,
String toolVersion,
String tool2,
String tool2Version,
String notes,
HashMap<String,Remote> remotes)
This constructor sets up a RemoteSet from a given HashMap of Remotes, so that it can later be used through
the xmlExport or xmlExportDocument to generate an XML export.
|
RemoteSet(String creatingUser,
String source,
String creationDate,
String tool,
String toolVersion,
String tool2,
String tool2Version,
String notes,
Remote remote)
This constructor sets up a RemoteSet from one single Remote.
|
Modifier and Type | Method and Description |
---|---|
void |
addFormat(Command.CommandTextFormat format,
int repeatCount)
Applies the format argument to all Command's in the CommandSet.
|
void |
append(RemoteSet remoteSet)
Copies the Remotes in the RemoteSet as argument, possibly replacing already existing.
|
ArrayList<Command> |
getAllCommands()
Generates a list of the commands in all contained remotes.
|
String |
getCreatingUser() |
String |
getCreationDate() |
String |
getNotes() |
Remote |
getRemote(String name)
Returns a particular remote.
|
Collection<Remote> |
getRemotes() |
String |
getSource() |
String |
getTool() |
String |
getTool2() |
String |
getTool2Version() |
String |
getToolVersion() |
static void |
main(String[] args)
For testing only, not deployment.
|
static void |
setDateFormatString(String aDateFormatString) |
Element |
xmlExport(Document doc,
String title,
boolean fatRaw,
boolean createSchemaLocation,
boolean generateRaw,
boolean generateCcf,
boolean generateParameters)
Generates an W3C Element from a RemoteList.
|
Document |
xmlExportDocument(String title,
String stylesheetType,
String stylesheetUrl,
boolean fatRaw,
boolean createSchemaLocation,
boolean generateRaw,
boolean generateCcf,
boolean generateParameters)
Generates an XML Document from a RemoteSet.
|
public static final String girrVersion
public RemoteSet(Document doc) throws ParseException
doc
- W3C DocumentParseException
public RemoteSet(String creatingUser, String source, String creationDate, String tool, String toolVersion, String tool2, String tool2Version, String notes, HashMap<String,Remote> remotes)
creatingUser
- Comment field for the creating user, if wanted.source
- Comment field describing the origin of the data; e.g. name of human author or creating program.creationDate
- Date of creation, as text string.tool
- Name of creating tool.toolVersion
- Version of creating tool.tool2
- Name of secondary tppl, if applicable.tool2Version
- Version of secondary tool.notes
- Textual notes.remotes
- HashMap of remotes.public RemoteSet(String creatingUser, String source, String creationDate, String tool, String toolVersion, String tool2, String tool2Version, String notes, Remote remote)
creatingUser
- source
- creationDate
- tool
- toolVersion
- tool2
- tool2Version
- notes
- remote
- public RemoteSet(String creatingUser, String source, Remote remote)
creatingUser
- source
- remote
- public RemoteSet(String creatingUser, String source, HashMap<String,Remote> remotes)
creatingUser
- source
- remotes
- public static void setDateFormatString(String aDateFormatString)
aDateFormatString
- the dateFormatString to set, default "yyyy-MM-dd_HH:mm:ss";public static void main(String[] args)
args
- public void append(RemoteSet remoteSet)
remoteSet
- public Element xmlExport(Document doc, String title, boolean fatRaw, boolean createSchemaLocation, boolean generateRaw, boolean generateCcf, boolean generateParameters)
doc
- title
- fatRaw
- createSchemaLocation
- generateRaw
- generateCcf
- generateParameters
- public Document xmlExportDocument(String title, String stylesheetType, String stylesheetUrl, boolean fatRaw, boolean createSchemaLocation, boolean generateRaw, boolean generateCcf, boolean generateParameters)
title
- Textual title of document.stylesheetType
- Type of stylesheet, normally "css" or "xsl".fatRaw
- For the raw form, generate elements for each flash and gap, otherwise a long PCDATA text string of durations will be generated.stylesheetUrl
- URL of stylesheet to be linked in a processing instruction.createSchemaLocation
- if schema location attributes (for validation) should be included.generateRaw
- If true, the raw form will be generated.generateCcf
- If true, the CCF ("Pronto hex") form will be generated.generateParameters
- If true, the protocol/parameter description will be generated.public void addFormat(Command.CommandTextFormat format, int repeatCount) throws IrpMasterException
format
- repeatCount
- IrpMasterException
public ArrayList<Command> getAllCommands()
public String getCreatingUser()
public String getSource()
public String getCreationDate()
public String getTool()
public String getToolVersion()
public String getTool2()
public String getTool2Version()
public String getNotes()
public Collection<Remote> getRemotes()
Copyright © 2016. All rights reserved.