home *** CD-ROM | disk | FTP | other *** search
- /**
- * SchemaInt.java
- *
- * This file was generated by XMLSPY 5 Enterprise Edition.
- *
- * YOU SHOULD NOT MODIFY THIS FILE, BECAUSE IT WILL BE
- * OVERWRITTEN WHEN YOU RE-RUN CODE GENERATION.
- *
- * Refer to the XMLSPY Documentation for further details.
- * http://www.altova.com/xmlspy
- */
-
- package com.altova.xml.types;
-
- public class SchemaInt implements SchemaType {
- protected int value;
-
- public SchemaInt(int newvalue) {
- value = newvalue;
- }
-
- public SchemaInt(String newvalue) {
- value = Integer.parseInt(newvalue);
- }
-
- public int getValue() {
- return value;
- }
-
- public void setValue(int newvalue) {
- value = newvalue;
- }
-
- public void setValue(String newvalue) {
- value = Integer.parseInt(newvalue);
- }
-
- public int hashCode() {
- return value;
- }
-
- public boolean equals(Object obj) {
- if (!(obj instanceof SchemaInt))
- return false;
- return value == ((SchemaInt)obj).value;
- }
-
- public Object clone() {
- return new SchemaInt(value);
- }
-
- public String toString() {
- return Integer.toString(value);
- }
-
- public String asString() {
- return toString();
- }
-
- public int compareTo(Object obj) {
- return compareTo((SchemaInt)obj);
- }
-
- public int compareTo(SchemaInt obj) {
- return new Integer(value).compareTo(new Integer(obj.value));
- }
- }
-