Package org.harctoolbox.irp
Class ParameterSpec
java.lang.Object
org.harctoolbox.irp.IrpObject
org.harctoolbox.irp.ParameterSpec
- All Implemented Interfaces:
Serializable,XmlExport
- See Also:
-
Constructor Summary
ConstructorsConstructorDescriptionParameterSpec(String str) ParameterSpec(String name, boolean memory, int length) ParameterSpec(String name, boolean memory, long min, long max) ParameterSpec(String name, boolean memory, long min, long max, Expression deflt) ParameterSpec(IrpParser.NameContext name, boolean hasMemory, IrpParser.NumberContext min, IrpParser.NumberContext max, IrpParser.ExpressionContext deflt) -
Method Summary
Modifier and TypeMethodDescriptionvoidcheck(NameEngine nameEngine) voidcheckDomain(long value) booleanlonggetMax()longgetMin()getName()booleaninthashCode()booleanstatic voidinitRandom(long seed) static booleanisStandardName(String name) booleanisWithinDomain(long x) longrandom()longtoIrpString(int radix) Returns a computed IRP (-segment) string representation of current IrpObject.intweight()Returns a (somewhat arbitrary) measure of the complexity of the object.Methods inherited from class org.harctoolbox.irp.IrpObject
createParameterSpecs, getParseTree, numberOfBits, numberOfBitSpecs, numberOfInfiniteRepeats, prerender, propertiesMap, toDocument, toIrpString, toString, toString, toStringTree, toStringTree, toTreeViewer, toTreeViewer, toTreeViewer, updateStateWhenEntering, updateStateWhenExiting
-
Constructor Details
-
ParameterSpec
-
ParameterSpec
-
ParameterSpec
public ParameterSpec(IrpParser.NameContext name, boolean hasMemory, IrpParser.NumberContext min, IrpParser.NumberContext max, IrpParser.ExpressionContext deflt) -
ParameterSpec
public ParameterSpec(String name, boolean memory, long min, long max, Expression deflt) throws InvalidNameException - Throws:
InvalidNameException
-
ParameterSpec
- Throws:
InvalidNameException
-
ParameterSpec
- Throws:
InvalidNameException
-
-
Method Details
-
isStandardName
-
initRandom
public static void initRandom(long seed) -
toIrpString
Description copied from class:IrpObjectReturns a computed IRP (-segment) string representation of current IrpObject. Numerical parameters, but not durations etc, will be printed using the radix in the argument.- Specified by:
toIrpStringin classIrpObject- Parameters:
radix- Radix for parameters.- Returns:
- Formatted string.
-
check
public void check(NameEngine nameEngine) throws InvalidNameException, DomainViolationException, NameUnassignedException -
checkDomain
- Throws:
DomainViolationException
-
isWithinDomain
public boolean isWithinDomain(long x) -
toElement
-
domainAsString
-
getName
-
getDefault
-
hasDefault
public boolean hasDefault() -
getMin
public long getMin() -
getMax
public long getMax() -
hasMemory
public boolean hasMemory() -
random
public long random() -
random
-
weight
public int weight()Description copied from class:IrpObjectReturns a (somewhat arbitrary) measure of the complexity of the object. Can be used for determining if a decode is "simpler" than another decode. -
equals
-
hashCode
public int hashCode()
-