1b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato/*
2b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato * ProGuard -- shrinking, optimization, obfuscation, and preverification
3b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato *             of Java bytecode.
4b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato *
5b9cc48a43ed984587c939d02fba5316bf5c0df6eYing Wang * Copyright (c) 2002-2013 Eric Lafortune (eric@graphics.cornell.edu)
6b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato *
7b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato * This program is free software; you can redistribute it and/or modify it
8b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato * under the terms of the GNU General Public License as published by the Free
9b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato * Software Foundation; either version 2 of the License, or (at your option)
10b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato * any later version.
11b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato *
12b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato * This program is distributed in the hope that it will be useful, but WITHOUT
13b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
14b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato * FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License for
15b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato * more details.
16b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato *
17b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato * You should have received a copy of the GNU General Public License along
18b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato * with this program; if not, write to the Free Software Foundation, Inc.,
19b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato * 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
20b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato */
21b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onoratopackage proguard.evaluation.value;
22b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato
23b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onoratoimport proguard.classfile.ClassConstants;
24b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato
25b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato/**
26b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato * This class represents a partially evaluated integer value.
27b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato *
28b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato * @author Eric Lafortune
29b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato */
30b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onoratopublic abstract class IntegerValue extends Category1Value
31b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato{
32b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato    /**
33b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato     * Returns the specific integer value, if applicable.
34b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato     */
35b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato    public int value()
36b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato    {
37b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato        return 0;
38b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato    }
39b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato
40b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato
41b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato    // Basic unary methods.
42b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato
43b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato    /**
44b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato     * Returns the negated value of this IntegerValue.
45b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato     */
46b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato    public abstract IntegerValue negate();
47b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato
48b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato    /**
49b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato     * Converts this IntegerValue to a byte IntegerValue.
50b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato     */
51b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato    public abstract IntegerValue convertToByte();
52b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato
53b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato    /**
54b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato     * Converts this IntegerValue to a character IntegerValue.
55b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato     */
56b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato    public abstract IntegerValue convertToCharacter();
57b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato
58b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato    /**
59b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato     * Converts this IntegerValue to a short IntegerValue.
60b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato     */
61b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato    public abstract IntegerValue convertToShort();
62b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato
63b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato    /**
64b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato     * Converts this IntegerValue to a LongValue.
65b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato     */
66b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato    public abstract LongValue convertToLong();
67b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato
68b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato    /**
69b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato     * Converts this IntegerValue to a FloatValue.
70b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato     */
71b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato    public abstract FloatValue convertToFloat();
72b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato
73b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato    /**
74b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato     * Converts this IntegerValue to a DoubleValue.
75b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato     */
76b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato    public abstract DoubleValue convertToDouble();
77b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato
78b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato
79b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato    // Basic binary methods.
80b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato
81b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato    /**
82b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato     * Returns the generalization of this IntegerValue and the given other
83b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato     * IntegerValue.
84b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato     */
85b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato    public abstract IntegerValue generalize(IntegerValue other);
86b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato
87b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato    /**
88b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato     * Returns the sum of this IntegerValue and the given IntegerValue.
89b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato     */
90b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato    public abstract IntegerValue add(IntegerValue other);
91b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato
92b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato    /**
93b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato     * Returns the difference of this IntegerValue and the given IntegerValue.
94b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato     */
95b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato    public abstract IntegerValue subtract(IntegerValue other);
96b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato
97b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato    /**
98b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato     * Returns the difference of the given IntegerValue and this IntegerValue.
99b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato     */
100b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato    public abstract IntegerValue subtractFrom(IntegerValue other);
101b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato
102b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato    /**
103b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato     * Returns the product of this IntegerValue and the given IntegerValue.
104b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato     */
105b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato    public abstract IntegerValue multiply(IntegerValue other)
106b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato    throws ArithmeticException;
107b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato
108b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato    /**
109b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato     * Returns the quotient of this IntegerValue and the given IntegerValue.
110b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato     */
111b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato    public abstract IntegerValue divide(IntegerValue other)
112b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato    throws ArithmeticException;
113b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato
114b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato    /**
115b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato     * Returns the quotient of the given IntegerValue and this IntegerValue.
116b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato     */
117b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato    public abstract IntegerValue divideOf(IntegerValue other)
118b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato    throws ArithmeticException;
119b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato
120b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato    /**
121b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato     * Returns the remainder of this IntegerValue divided by the given
122b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato     * IntegerValue.
123b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato     */
124b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato    public abstract IntegerValue remainder(IntegerValue other)
125b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato    throws ArithmeticException;
126b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato
127b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato    /**
128b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato     * Returns the remainder of the given IntegerValue divided by this
129b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato     * IntegerValue.
130b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato     */
131b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato    public abstract IntegerValue remainderOf(IntegerValue other)
132b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato    throws ArithmeticException;
133b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato
134b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato    /**
135b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato     * Returns this IntegerValue, shifted left by the given IntegerValue.
136b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato     */
137b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato    public abstract IntegerValue shiftLeft(IntegerValue other);
138b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato
139b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato    /**
140b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato     * Returns this IntegerValue, shifted right by the given IntegerValue.
141b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato     */
142b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato    public abstract IntegerValue shiftRight(IntegerValue other);
143b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato
144b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato    /**
145b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato     * Returns this unsigned IntegerValue, shifted left by the given
146b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato     * IntegerValue.
147b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato     */
148b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato    public abstract IntegerValue unsignedShiftRight(IntegerValue other);
149b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato
150b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato    /**
151b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato     * Returns the given IntegerValue, shifted left by this IntegerValue.
152b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato     */
153b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato    public abstract IntegerValue shiftLeftOf(IntegerValue other);
154b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato
155b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato    /**
156b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato     * Returns the given IntegerValue, shifted right by this IntegerValue.
157b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato     */
158b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato    public abstract IntegerValue shiftRightOf(IntegerValue other);
159b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato
160b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato    /**
161b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato     * Returns the given unsigned IntegerValue, shifted left by this
162b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato     * IntegerValue.
163b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato     */
164b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato    public abstract IntegerValue unsignedShiftRightOf(IntegerValue other);
165b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato
166b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato    /**
167b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato     * Returns the given LongValue, shifted left by this IntegerValue.
168b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato     */
169b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato    public abstract LongValue shiftLeftOf(LongValue other);
170b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato
171b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato    /**
172b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato     * Returns the given LongValue, shifted right by this IntegerValue.
173b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato     */
174b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato    public abstract LongValue shiftRightOf(LongValue other);
175b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato
176b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato    /**
177b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato     * Returns the given unsigned LongValue, shifted right by this IntegerValue.
178b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato     */
179b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato    public abstract LongValue unsignedShiftRightOf(LongValue other);
180b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato
181b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato    /**
182b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato     * Returns the logical <i>and</i> of this IntegerValue and the given
183b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato     * IntegerValue.
184b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato     */
185b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato    public abstract IntegerValue and(IntegerValue other);
186b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato
187b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato    /**
188b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato     * Returns the logical <i>or</i> of this IntegerValue and the given
189b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato     * IntegerValue.
190b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato     */
191b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato    public abstract IntegerValue or(IntegerValue other);
192b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato
193b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato    /**
194b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato     * Returns the logical <i>xor</i> of this IntegerValue and the given
195b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato     * IntegerValue.
196b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato     */
197b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato    public abstract IntegerValue xor(IntegerValue other);
198b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato
199b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato    /**
200b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato     * Returns whether this IntegerValue and the given IntegerValue are equal:
201b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato     * <code>NEVER</code>, <code>MAYBE</code>, or <code>ALWAYS</code>.
202b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato     */
203b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato    public abstract int equal(IntegerValue other);
204b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato
205b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato    /**
206b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato     * Returns whether this IntegerValue is less than the given IntegerValue:
207b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato     * <code>NEVER</code>, <code>MAYBE</code>, or <code>ALWAYS</code>.
208b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato     */
209b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato    public abstract int lessThan(IntegerValue other);
210b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato
211b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato    /**
212b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato     * Returns whether this IntegerValue is less than or equal to the given
213b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato     * IntegerValue: <code>NEVER</code>, <code>MAYBE</code>, or
214b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato     * <code>ALWAYS</code>.
215b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato     */
216b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato    public abstract int lessThanOrEqual(IntegerValue other);
217b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato
218b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato
219b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato    // Derived binary methods.
220b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato
221b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato    /**
222b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato     * Returns whether this IntegerValue and the given IntegerValue are different:
223b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato     * <code>NEVER</code>, <code>MAYBE</code>, or <code>ALWAYS</code>.
224b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato     */
225b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato    public final int notEqual(IntegerValue other)
226b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato    {
227b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato        return -equal(other);
228b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato    }
229b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato
230b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato    /**
231b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato     * Returns whether this IntegerValue is greater than the given IntegerValue:
232b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato     * <code>NEVER</code>, <code>MAYBE</code>, or <code>ALWAYS</code>.
233b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato     */
234b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato    public final int greaterThan(IntegerValue other)
235b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato    {
236b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato        return -lessThanOrEqual(other);
237b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato    }
238b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato
239b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato    /**
240b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato     * Returns whether this IntegerValue is greater than or equal to the given IntegerValue:
241b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato     * <code>NEVER</code>, <code>MAYBE</code>, or <code>ALWAYS</code>.
242b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato     */
243b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato    public final int greaterThanOrEqual(IntegerValue other)
244b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato    {
245b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato        return -lessThan(other);
246b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato    }
247b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato
248b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato
249b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato    // Similar binary methods, but this time with unknown arguments.
250b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato
251b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato    /**
252b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato     * Returns the generalization of this IntegerValue and the given other
253b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato     * UnknownIntegerValue.
254b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato     */
255b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato    public IntegerValue generalize(UnknownIntegerValue other)
256b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato    {
257b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato        return generalize((IntegerValue)other);
258b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato    }
259b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato
260b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato
261b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato    /**
262b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato     * Returns the sum of this IntegerValue and the given UnknownIntegerValue.
263b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato     */
264b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato    public IntegerValue add(UnknownIntegerValue other)
265b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato    {
266b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato        return add((IntegerValue)other);
267b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato    }
268b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato
269b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato    /**
270b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato     * Returns the difference of this IntegerValue and the given UnknownIntegerValue.
271b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato     */
272b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato    public IntegerValue subtract(UnknownIntegerValue other)
273b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato    {
274b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato        return subtract((IntegerValue)other);
275b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato    }
276b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato
277b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato    /**
278b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato     * Returns the difference of the given UnknownIntegerValue and this IntegerValue.
279b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato     */
280b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato    public IntegerValue subtractFrom(UnknownIntegerValue other)
281b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato    {
282b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato        return subtractFrom((IntegerValue)other);
283b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato    }
284b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato
285b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato    /**
286b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato     * Returns the product of this IntegerValue and the given UnknownIntegerValue.
287b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato     */
288b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato    public IntegerValue multiply(UnknownIntegerValue other)
289b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato    {
290b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato        return multiply((IntegerValue)other);
291b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato    }
292b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato
293b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato    /**
294b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato     * Returns the quotient of this IntegerValue and the given
295b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato     * UnknownIntegerValue.
296b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato     */
297b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato    public IntegerValue divide(UnknownIntegerValue other)
298b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato    {
299b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato        return divide((IntegerValue)other);
300b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato    }
301b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato
302b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato    /**
303b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato     * Returns the quotient of the given UnknownIntegerValue and this
304b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato     * IntegerValue.
305b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato     */
306b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato    public IntegerValue divideOf(UnknownIntegerValue other)
307b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato    {
308b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato        return divideOf((IntegerValue)other);
309b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato    }
310b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato
311b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato    /**
312b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato     * Returns the remainder of this IntegerValue divided by the given
313b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato     * UnknownIntegerValue.
314b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato     */
315b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato    public IntegerValue remainder(UnknownIntegerValue other)
316b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato    {
317b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato        return remainder((IntegerValue)other);
318b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato    }
319b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato
320b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato    /**
321b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato     * Returns the remainder of the given UnknownIntegerValue divided by this
322b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato     * IntegerValue.
323b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato     */
324b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato    public IntegerValue remainderOf(UnknownIntegerValue other)
325b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato    {
326b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato        return remainderOf((IntegerValue)other);
327b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato    }
328b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato
329b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato    /**
330b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato     * Returns this IntegerValue, shifted left by the given UnknownIntegerValue.
331b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato     */
332b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato    public IntegerValue shiftLeft(UnknownIntegerValue other)
333b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato    {
334b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato        return shiftLeft((IntegerValue)other);
335b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato    }
336b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato
337b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato    /**
338b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato     * Returns this IntegerValue, shifted right by the given UnknownIntegerValue.
339b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato     */
340b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato    public IntegerValue shiftRight(UnknownIntegerValue other)
341b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato    {
342b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato        return shiftRight((IntegerValue)other);
343b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato    }
344b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato
345b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato    /**
346b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato     * Returns this unsigned IntegerValue, shifted right by the given
347b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato     * UnknownIntegerValue.
348b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato     */
349b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato    public IntegerValue unsignedShiftRight(UnknownIntegerValue other)
350b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato    {
351b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato        return unsignedShiftRight((IntegerValue)other);
352b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato    }
353b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato
354b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato    /**
355b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato     * Returns the given UnknownIntegerValue, shifted left by this IntegerValue.
356b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato     */
357b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato    public IntegerValue shiftLeftOf(UnknownIntegerValue other)
358b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato    {
359b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato        return shiftLeftOf((IntegerValue)other);
360b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato    }
361b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato
362b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato    /**
363b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato     * Returns the given UnknownIntegerValue, shifted right by this IntegerValue.
364b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato     */
365b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato    public IntegerValue shiftRightOf(UnknownIntegerValue other)
366b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato    {
367b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato        return shiftRightOf((IntegerValue)other);
368b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato    }
369b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato
370b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato    /**
371b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato     * Returns the given unsigned UnknownIntegerValue, shifted right by this
372b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato     * IntegerValue.
373b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato     */
374b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato    public IntegerValue unsignedShiftRightOf(UnknownIntegerValue other)
375b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato    {
376b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato        return unsignedShiftRightOf((IntegerValue)other);
377b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato    }
378b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato
379b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato    /**
380b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato     * Returns the given UnknownLongValue, shifted left by this IntegerValue.
381b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato     */
382b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato    public LongValue shiftLeftOf(UnknownLongValue other)
383b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato    {
384b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato        return shiftLeftOf((LongValue)other);
385b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato    }
386b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato
387b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato    /**
388b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato     * Returns the given UnknownLongValue, shifted right by this IntegerValue.
389b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato     */
390b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato    public LongValue shiftRightOf(UnknownLongValue other)
391b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato    {
392b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato        return shiftRightOf((LongValue)other);
393b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato    }
394b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato
395b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato    /**
396b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato     * Returns the given unsigned UnknownLongValue, shifted right by this
397b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato     * IntegerValue.
398b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato     */
399b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato    public LongValue unsignedShiftRightOf(UnknownLongValue other)
400b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato    {
401b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato        return unsignedShiftRightOf((LongValue)other);
402b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato    }
403b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato
404b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato    /**
405b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato     * Returns the logical <i>and</i> of this IntegerValue and the given
406b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato     * UnknownIntegerValue.
407b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato     */
408b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato    public IntegerValue and(UnknownIntegerValue other)
409b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato    {
410b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato        return and((IntegerValue)other);
411b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato    }
412b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato
413b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato    /**
414b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato     * Returns the logical <i>or</i> of this IntegerValue and the given
415b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato     * UnknownIntegerValue.
416b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato     */
417b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato    public IntegerValue or(UnknownIntegerValue other)
418b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato    {
419b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato        return or((IntegerValue)other);
420b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato    }
421b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato
422b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato    /**
423b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato     * Returns the logical <i>xor</i> of this IntegerValue and the given
424b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato     * UnknownIntegerValue.
425b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato     */
426b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato    public IntegerValue xor(UnknownIntegerValue other)
427b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato    {
428b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato        return xor((IntegerValue)other);
429b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato    }
430b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato
431b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato    /**
432b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato     * Returns whether this IntegerValue and the given UnknownIntegerValue are
433b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato     * equal: <code>NEVER</code>, <code>MAYBE</code>, or <code>ALWAYS</code>.
434b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato     */
435b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato    public int equal(UnknownIntegerValue other)
436b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato    {
437b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato        return equal((IntegerValue)other);
438b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato    }
439b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato
440b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato    /**
441b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato     * Returns whether this IntegerValue is less than the given
442b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato     * UnknownIntegerValue: <code>NEVER</code>, <code>MAYBE</code>, or
443b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato     * <code>ALWAYS</code>.
444b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato     */
445b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato    public int lessThan(UnknownIntegerValue other)
446b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato    {
447b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato        return lessThan((IntegerValue)other);
448b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato    }
449b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato
450b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato    /**
451b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato     * Returns whether this IntegerValue is less than or equal to the given
452b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato     * UnknownIntegerValue: <code>NEVER</code>, <code>MAYBE</code>, or
453b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato     * <code>ALWAYS</code>.
454b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato     */
455b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato    public int lessThanOrEqual(UnknownIntegerValue other)
456b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato    {
457b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato        return lessThanOrEqual((IntegerValue)other);
458b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato    }
459b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato
460b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato
461b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato    // Derived binary methods.
462b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato
463b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato    /**
464b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato     * Returns whether this IntegerValue and the given UnknownIntegerValue are
465b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato     * different: <code>NEVER</code>, <code>MAYBE</code>, or <code>ALWAYS</code>.
466b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato     */
467b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato    public final int notEqual(UnknownIntegerValue other)
468b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato    {
469b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato        return -equal(other);
470b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato    }
471b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato
472b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato    /**
473b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato     * Returns whether this IntegerValue is greater than the given
474b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato     * UnknownIntegerValue: <code>NEVER</code>, <code>MAYBE</code>, or
475b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato     * <code>ALWAYS</code>.
476b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato     */
477b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato    public final int greaterThan(UnknownIntegerValue other)
478b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato    {
479b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato        return -lessThanOrEqual(other);
480b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato    }
481b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato
482b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato    /**
483b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato     * Returns whether this IntegerValue is greater than or equal to the given
484b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato     * UnknownIntegerValue: <code>NEVER</code>, <code>MAYBE</code>, or
485b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato     * <code>ALWAYS</code>.
486b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato     */
487b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato    public final int greaterThanOrEqual(UnknownIntegerValue other)
488b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato    {
489b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato        return -lessThan(other);
490b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato    }
491b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato
492b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato
493b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato    // Similar binary methods, but this time with specific arguments.
494b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato
495b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato    /**
496b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato     * Returns the generalization of this IntegerValue and the given other
497b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato     * SpecificIntegerValue.
498b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato     */
499b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato    public IntegerValue generalize(SpecificIntegerValue other)
500b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato    {
501b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato        return generalize((IntegerValue)other);
502b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato    }
503b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato
504b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato
505b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato    /**
506b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato     * Returns the sum of this IntegerValue and the given SpecificIntegerValue.
507b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato     */
508b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato    public IntegerValue add(SpecificIntegerValue other)
509b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato    {
510b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato        return add((IntegerValue)other);
511b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato    }
512b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato
513b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato    /**
514b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato     * Returns the difference of this IntegerValue and the given SpecificIntegerValue.
515b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato     */
516b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato    public IntegerValue subtract(SpecificIntegerValue other)
517b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato    {
518b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato        return subtract((IntegerValue)other);
519b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato    }
520b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato
521b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato    /**
522b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato     * Returns the difference of the given SpecificIntegerValue and this IntegerValue.
523b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato     */
524b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato    public IntegerValue subtractFrom(SpecificIntegerValue other)
525b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato    {
526b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato        return subtractFrom((IntegerValue)other);
527b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato    }
528b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato
529b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato    /**
530b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato     * Returns the product of this IntegerValue and the given SpecificIntegerValue.
531b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato     */
532b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato    public IntegerValue multiply(SpecificIntegerValue other)
533b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato    {
534b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato        return multiply((IntegerValue)other);
535b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato    }
536b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato
537b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato    /**
538b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato     * Returns the quotient of this IntegerValue and the given
539b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato     * SpecificIntegerValue.
540b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato     */
541b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato    public IntegerValue divide(SpecificIntegerValue other)
542b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato    {
543b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato        return divide((IntegerValue)other);
544b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato    }
545b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato
546b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato    /**
547b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato     * Returns the quotient of the given SpecificIntegerValue and this
548b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato     * IntegerValue.
549b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato     */
550b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato    public IntegerValue divideOf(SpecificIntegerValue other)
551b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato    {
552b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato        return divideOf((IntegerValue)other);
553b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato    }
554b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato
555b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato    /**
556b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato     * Returns the remainder of this IntegerValue divided by the given
557b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato     * SpecificIntegerValue.
558b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato     */
559b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato    public IntegerValue remainder(SpecificIntegerValue other)
560b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato    {
561b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato        return remainder((IntegerValue)other);
562b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato    }
563b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato
564b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato    /**
565b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato     * Returns the remainder of the given SpecificIntegerValue divided by this
566b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato     * IntegerValue.
567b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato     */
568b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato    public IntegerValue remainderOf(SpecificIntegerValue other)
569b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato    {
570b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato        return remainderOf((IntegerValue)other);
571b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato    }
572b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato
573b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato    /**
574b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato     * Returns this IntegerValue, shifted left by the given SpecificIntegerValue.
575b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato     */
576b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato    public IntegerValue shiftLeft(SpecificIntegerValue other)
577b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato    {
578b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato        return shiftLeft((IntegerValue)other);
579b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato    }
580b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato
581b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato    /**
582b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato     * Returns this IntegerValue, shifted right by the given SpecificIntegerValue.
583b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato     */
584b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato    public IntegerValue shiftRight(SpecificIntegerValue other)
585b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato    {
586b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato        return shiftRight((IntegerValue)other);
587b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato    }
588b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato
589b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato    /**
590b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato     * Returns this unsigned IntegerValue, shifted right by the given
591b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato     * SpecificIntegerValue.
592b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato     */
593b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato    public IntegerValue unsignedShiftRight(SpecificIntegerValue other)
594b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato    {
595b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato        return unsignedShiftRight((IntegerValue)other);
596b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato    }
597b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato
598b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato    /**
599b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato     * Returns the given SpecificIntegerValue, shifted left by this IntegerValue.
600b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato     */
601b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato    public IntegerValue shiftLeftOf(SpecificIntegerValue other)
602b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato    {
603b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato        return shiftLeftOf((IntegerValue)other);
604b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato    }
605b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato
606b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato    /**
607b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato     * Returns the given SpecificIntegerValue, shifted right by this IntegerValue.
608b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato     */
609b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato    public IntegerValue shiftRightOf(SpecificIntegerValue other)
610b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato    {
611b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato        return shiftRightOf((IntegerValue)other);
612b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato    }
613b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato
614b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato    /**
615b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato     * Returns the given unsigned SpecificIntegerValue, shifted right by this
616b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato     * IntegerValue.
617b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato     */
618b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato    public IntegerValue unsignedShiftRightOf(SpecificIntegerValue other)
619b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato    {
620b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato        return unsignedShiftRightOf((IntegerValue)other);
621b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato    }
622b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato
623b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato    /**
624b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato     * Returns the given SpecificLongValue, shifted left by this IntegerValue.
625b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato     */
626b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato    public LongValue shiftLeftOf(SpecificLongValue other)
627b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato    {
628b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato        return shiftLeftOf((LongValue)other);
629b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato    }
630b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato
631b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato    /**
632b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato     * Returns the given SpecificLongValue, shifted right by this IntegerValue.
633b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato     */
634b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato    public LongValue shiftRightOf(SpecificLongValue other)
635b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato    {
636b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato        return shiftRightOf((LongValue)other);
637b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato    }
638b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato
639b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato    /**
640b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato     * Returns the given unsigned SpecificLongValue, shifted right by this
641b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato     * IntegerValue.
642b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato     */
643b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato    public LongValue unsignedShiftRightOf(SpecificLongValue other)
644b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato    {
645b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato        return unsignedShiftRightOf((LongValue)other);
646b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato    }
647b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato
648b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato    /**
649b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato     * Returns the logical <i>and</i> of this IntegerValue and the given
650b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato     * SpecificIntegerValue.
651b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato     */
652b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato    public IntegerValue and(SpecificIntegerValue other)
653b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato    {
654b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato        return and((IntegerValue)other);
655b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato    }
656b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato
657b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato    /**
658b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato     * Returns the logical <i>or</i> of this IntegerValue and the given
659b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato     * SpecificIntegerValue.
660b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato     */
661b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato    public IntegerValue or(SpecificIntegerValue other)
662b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato    {
663b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato        return or((IntegerValue)other);
664b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato    }
665b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato
666b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato    /**
667b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato     * Returns the logical <i>xor</i> of this IntegerValue and the given
668b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato     * SpecificIntegerValue.
669b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato     */
670b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato    public IntegerValue xor(SpecificIntegerValue other)
671b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato    {
672b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato        return xor((IntegerValue)other);
673b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato    }
674b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato
675b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato    /**
676b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato     * Returns whether this IntegerValue and the given SpecificIntegerValue are
677b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato     * equal: <code>NEVER</code>, <code>MAYBE</code>, or <code>ALWAYS</code>.
678b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato     */
679b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato    public int equal(SpecificIntegerValue other)
680b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato    {
681b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato        return equal((IntegerValue)other);
682b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato    }
683b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato
684b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato    /**
685b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato     * Returns whether this IntegerValue is less than the given
686b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato     * SpecificIntegerValue: <code>NEVER</code>, <code>MAYBE</code>, or
687b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato     * <code>ALWAYS</code>.
688b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato     */
689b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato    public int lessThan(SpecificIntegerValue other)
690b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato    {
691b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato        return lessThan((IntegerValue)other);
692b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato    }
693b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato
694b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato    /**
695b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato     * Returns whether this IntegerValue is less than or equal to the given
696b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato     * SpecificIntegerValue: <code>NEVER</code>, <code>MAYBE</code>, or
697b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato     * <code>ALWAYS</code>.
698b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato     */
699b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato    public int lessThanOrEqual(SpecificIntegerValue other)
700b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato    {
701b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato        return lessThanOrEqual((IntegerValue)other);
702b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato    }
703b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato
704b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato
705b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato    // Derived binary methods.
706b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato
707b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato    /**
708b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato     * Returns whether this IntegerValue and the given SpecificIntegerValue are
709b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato     * different: <code>NEVER</code>, <code>MAYBE</code>, or <code>ALWAYS</code>.
710b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato     */
711b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato    public final int notEqual(SpecificIntegerValue other)
712b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato    {
713b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato        return -equal(other);
714b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato    }
715b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato
716b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato    /**
717b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato     * Returns whether this IntegerValue is greater than the given
718b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato     * SpecificIntegerValue: <code>NEVER</code>, <code>MAYBE</code>, or
719b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato     * <code>ALWAYS</code>.
720b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato     */
721b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato    public final int greaterThan(SpecificIntegerValue other)
722b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato    {
723b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato        return -lessThanOrEqual(other);
724b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato    }
725b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato
726b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato    /**
727b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato     * Returns whether this IntegerValue is greater than or equal to the given
728b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato     * SpecificIntegerValue: <code>NEVER</code>, <code>MAYBE</code>, or
729b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato     * <code>ALWAYS</code>.
730b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato     */
731b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato    public final int greaterThanOrEqual(SpecificIntegerValue other)
732b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato    {
733b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato        return -lessThan(other);
734b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato    }
735b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato
736b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato
737b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato    // Similar binary methods, but this time with particular arguments.
738b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato
739b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato    /**
740b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato     * Returns the generalization of this IntegerValue and the given other
741b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato     * ParticularIntegerValue.
742b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato     */
743b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato    public IntegerValue generalize(ParticularIntegerValue other)
744b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato    {
745b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato        return generalize((SpecificIntegerValue)other);
746b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato    }
747b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato
748b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato
749b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato    /**
750b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato     * Returns the sum of this IntegerValue and the given ParticularIntegerValue.
751b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato     */
752b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato    public IntegerValue add(ParticularIntegerValue other)
753b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato    {
754b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato        return add((SpecificIntegerValue)other);
755b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato    }
756b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato
757b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato    /**
758b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato     * Returns the difference of this IntegerValue and the given ParticularIntegerValue.
759b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato     */
760b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato    public IntegerValue subtract(ParticularIntegerValue other)
761b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato    {
762b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato        return subtract((SpecificIntegerValue)other);
763b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato    }
764b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato
765b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato    /**
766b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato     * Returns the difference of the given ParticularIntegerValue and this IntegerValue.
767b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato     */
768b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato    public IntegerValue subtractFrom(ParticularIntegerValue other)
769b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato    {
770b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato        return subtractFrom((SpecificIntegerValue)other);
771b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato    }
772b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato
773b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato    /**
774b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato     * Returns the product of this IntegerValue and the given ParticularIntegerValue.
775b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato     */
776b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato    public IntegerValue multiply(ParticularIntegerValue other)
777b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato    {
778b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato        return multiply((SpecificIntegerValue)other);
779b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato    }
780b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato
781b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato    /**
782b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato     * Returns the quotient of this IntegerValue and the given
783b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato     * ParticularIntegerValue.
784b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato     */
785b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato    public IntegerValue divide(ParticularIntegerValue other)
786b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato    {
787b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato        return divide((SpecificIntegerValue)other);
788b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato    }
789b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato
790b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato    /**
791b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato     * Returns the quotient of the given ParticularIntegerValue and this
792b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato     * IntegerValue.
793b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato     */
794b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato    public IntegerValue divideOf(ParticularIntegerValue other)
795b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato    {
796b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato        return divideOf((SpecificIntegerValue)other);
797b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato    }
798b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato
799b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato    /**
800b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato     * Returns the remainder of this IntegerValue divided by the given
801b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato     * ParticularIntegerValue.
802b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato     */
803b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato    public IntegerValue remainder(ParticularIntegerValue other)
804b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato    {
805b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato        return remainder((SpecificIntegerValue)other);
806b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato    }
807b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato
808b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato    /**
809b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato     * Returns the remainder of the given ParticularIntegerValue divided by this
810b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato     * IntegerValue.
811b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato     */
812b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato    public IntegerValue remainderOf(ParticularIntegerValue other)
813b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato    {
814b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato        return remainderOf((SpecificIntegerValue)other);
815b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato    }
816b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato
817b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato    /**
818b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato     * Returns this IntegerValue, shifted left by the given ParticularIntegerValue.
819b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato     */
820b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato    public IntegerValue shiftLeft(ParticularIntegerValue other)
821b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato    {
822b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato        return shiftLeft((SpecificIntegerValue)other);
823b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato    }
824b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato
825b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato    /**
826b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato     * Returns this IntegerValue, shifted right by the given ParticularIntegerValue.
827b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato     */
828b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato    public IntegerValue shiftRight(ParticularIntegerValue other)
829b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato    {
830b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato        return shiftRight((SpecificIntegerValue)other);
831b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato    }
832b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato
833b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato    /**
834b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato     * Returns this unsigned IntegerValue, shifted right by the given
835b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato     * ParticularIntegerValue.
836b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato     */
837b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato    public IntegerValue unsignedShiftRight(ParticularIntegerValue other)
838b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato    {
839b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato        return unsignedShiftRight((SpecificIntegerValue)other);
840b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato    }
841b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato
842b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato    /**
843b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato     * Returns the given ParticularIntegerValue, shifted left by this IntegerValue.
844b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato     */
845b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato    public IntegerValue shiftLeftOf(ParticularIntegerValue other)
846b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato    {
847b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato        return shiftLeftOf((SpecificIntegerValue)other);
848b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato    }
849b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato
850b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato    /**
851b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato     * Returns the given ParticularIntegerValue, shifted right by this IntegerValue.
852b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato     */
853b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato    public IntegerValue shiftRightOf(ParticularIntegerValue other)
854b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato    {
855b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato        return shiftRightOf((SpecificIntegerValue)other);
856b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato    }
857b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato
858b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato    /**
859b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato     * Returns the given unsigned ParticularIntegerValue, shifted right by this
860b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato     * IntegerValue.
861b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato     */
862b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato    public IntegerValue unsignedShiftRightOf(ParticularIntegerValue other)
863b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato    {
864b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato        return unsignedShiftRightOf((SpecificIntegerValue)other);
865b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato    }
866b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato
867b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato    /**
868b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato     * Returns the given ParticularLongValue, shifted left by this IntegerValue.
869b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato     */
870b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato    public LongValue shiftLeftOf(ParticularLongValue other)
871b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato    {
872b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato        return shiftLeftOf((SpecificLongValue)other);
873b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato    }
874b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato
875b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato    /**
876b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato     * Returns the given ParticularLongValue, shifted right by this IntegerValue.
877b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato     */
878b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato    public LongValue shiftRightOf(ParticularLongValue other)
879b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato    {
880b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato        return shiftRightOf((SpecificLongValue)other);
881b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato    }
882b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato
883b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato    /**
884b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato     * Returns the given unsigned ParticularLongValue, shifted right by this
885b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato     * IntegerValue.
886b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato     */
887b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato    public LongValue unsignedShiftRightOf(ParticularLongValue other)
888b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato    {
889b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato        return unsignedShiftRightOf((SpecificLongValue)other);
890b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato    }
891b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato
892b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato    /**
893b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato     * Returns the logical <i>and</i> of this IntegerValue and the given
894b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato     * ParticularIntegerValue.
895b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato     */
896b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato    public IntegerValue and(ParticularIntegerValue other)
897b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato    {
898b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato        return and((SpecificIntegerValue)other);
899b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato    }
900b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato
901b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato    /**
902b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato     * Returns the logical <i>or</i> of this IntegerValue and the given
903b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato     * ParticularIntegerValue.
904b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato     */
905b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato    public IntegerValue or(ParticularIntegerValue other)
906b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato    {
907b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato        return or((SpecificIntegerValue)other);
908b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato    }
909b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato
910b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato    /**
911b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato     * Returns the logical <i>xor</i> of this IntegerValue and the given
912b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato     * ParticularIntegerValue.
913b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato     */
914b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato    public IntegerValue xor(ParticularIntegerValue other)
915b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato    {
916b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato        return xor((SpecificIntegerValue)other);
917b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato    }
918b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato
919b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato    /**
920b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato     * Returns whether this IntegerValue and the given ParticularIntegerValue are
921b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato     * equal: <code>NEVER</code>, <code>MAYBE</code>, or <code>ALWAYS</code>.
922b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato     */
923b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato    public int equal(ParticularIntegerValue other)
924b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato    {
925b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato        return equal((SpecificIntegerValue)other);
926b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato    }
927b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato
928b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato    /**
929b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato     * Returns whether this IntegerValue is less than the given
930b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato     * ParticularIntegerValue: <code>NEVER</code>, <code>MAYBE</code>, or
931b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato     * <code>ALWAYS</code>.
932b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato     */
933b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato    public int lessThan(ParticularIntegerValue other)
934b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato    {
935b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato        return lessThan((SpecificIntegerValue)other);
936b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato    }
937b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato
938b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato    /**
939b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato     * Returns whether this IntegerValue is less than or equal to the given
940b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato     * ParticularIntegerValue: <code>NEVER</code>, <code>MAYBE</code>, or
941b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato     * <code>ALWAYS</code>.
942b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato     */
943b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato    public int lessThanOrEqual(ParticularIntegerValue other)
944b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato    {
945b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato        return lessThanOrEqual((SpecificIntegerValue)other);
946b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato    }
947b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato
948b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato
949b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato    // Derived binary methods.
950b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato
951b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato    /**
952b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato     * Returns whether this IntegerValue and the given ParticularIntegerValue are
953b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato     * different: <code>NEVER</code>, <code>MAYBE</code>, or <code>ALWAYS</code>.
954b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato     */
955b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato    public final int notEqual(ParticularIntegerValue other)
956b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato    {
957b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato        return -equal(other);
958b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato    }
959b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato
960b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato    /**
961b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato     * Returns whether this IntegerValue is greater than the given
962b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato     * ParticularIntegerValue: <code>NEVER</code>, <code>MAYBE</code>, or
963b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato     * <code>ALWAYS</code>.
964b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato     */
965b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato    public final int greaterThan(ParticularIntegerValue other)
966b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato    {
967b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato        return -lessThanOrEqual(other);
968b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato    }
969b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato
970b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato    /**
971b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato     * Returns whether this IntegerValue is greater than or equal to the given
972b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato     * ParticularIntegerValue: <code>NEVER</code>, <code>MAYBE</code>, or
973b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato     * <code>ALWAYS</code>.
974b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato     */
975b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato    public final int greaterThanOrEqual(ParticularIntegerValue other)
976b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato    {
977b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato        return -lessThan(other);
978b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato    }
979b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato
980b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato
981b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato    // Implementations for Value.
982b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato
983b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato    public final IntegerValue integerValue()
984b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato    {
985b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato        return this;
986b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato    }
987b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato
988b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato    public final Value generalize(Value other)
989b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato    {
990b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato        return this.generalize(other.integerValue());
991b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato    }
992b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato
993b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato    public final int computationalType()
994b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato    {
995b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato        return TYPE_INTEGER;
996b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato    }
997b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato
998b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato    public final String internalType()
999b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato    {
1000b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato        return String.valueOf(ClassConstants.INTERNAL_TYPE_INT);
1001b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato    }
1002b72c5c2e5482cf10117b2b25f642f7616b2326c3Joe Onorato}
1003