com.topcoder.shared.problem
Class MinSizeConstraint
java.lang.Object
|
+--com.topcoder.shared.problem.BaseElement
|
+--com.topcoder.shared.problem.Constraint
|
+--com.topcoder.shared.problem.SizeConstraint
|
+--com.topcoder.shared.problem.MinSizeConstraint
- All Implemented Interfaces:
- java.lang.Cloneable, com.topcoder.shared.netCommon.CustomSerializable, Element, java.io.Serializable
- public class MinSizeConstraint
- extends SizeConstraint
The MinSizeConstraint class is for constraints related to the
minimum size (length) of a parameter. This class is not currently being used
but is reserved for future use.
- Author:
- mitalub
- See Also:
- Serialized Form
|
Constructor Summary |
MinSizeConstraint()
Empty constructor required by custom serialization. |
MinSizeConstraint(int size,
int dimension,
java.lang.String paramName)
Constructs the Min Size constraint from the given parms. |
|
Method Summary |
void |
customReadObject(com.topcoder.shared.netCommon.CSReader reader)
Custom serializiation |
void |
customWriteObject(com.topcoder.shared.netCommon.CSWriter writer)
Custom serializiation |
java.lang.String |
toXML()
Returns the constraint as XML. |
| Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
MinSizeConstraint
public MinSizeConstraint(int size,
int dimension,
java.lang.String paramName)
- Constructs the Min Size constraint from the given parms.
- Parameters:
size - the size.dimension - the dimension the size applies to.paramName - the parameter name.
MinSizeConstraint
public MinSizeConstraint()
- Empty constructor required by custom serialization.
customWriteObject
public void customWriteObject(com.topcoder.shared.netCommon.CSWriter writer)
throws java.io.IOException
- Custom serializiation
- Specified by:
customWriteObject in interface Element- Overrides:
customWriteObject in class SizeConstraint
- Parameters:
writer - the writer to write to.
- Throws:
java.io.IOException - if an I/O error has occurred in the stream that backs the writer.
customReadObject
public void customReadObject(com.topcoder.shared.netCommon.CSReader reader)
throws java.io.IOException,
java.io.ObjectStreamException
- Custom serializiation
- Specified by:
customReadObject in interface Element- Overrides:
customReadObject in class SizeConstraint
- Parameters:
reader - the reader to read from.
- Throws:
java.io.ObjectStreamException - if the information that is read is inconsistent (stream corrupted
or incompatibility between writers and readers)
java.io.IOException - if an I/O error has occurred in the stream that backs the reader.
toXML
public java.lang.String toXML()
- Returns the constraint as XML.
Note: Currently returns a blank - TODO logan.
- Returns:
- the constraint as XMl.