001: /*
002: * <copyright>
003: *
004: * Copyright 1997-2004 BBNT Solutions, LLC
005: * under sponsorship of the Defense Advanced Research Projects
006: * Agency (DARPA).
007: *
008: * You can redistribute this software and/or modify it under the
009: * terms of the Cougaar Open Source License as published on the
010: * Cougaar Open Source Website (www.cougaar.org).
011: *
012: * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS
013: * "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT
014: * LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR
015: * A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT
016: * OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
017: * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
018: * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,
019: * DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY
020: * THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
021: * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE
022: * OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
023: *
024: * </copyright>
025: */
026:
027: /* @generated Thu Sep 27 15:26:05 EDT 2007 from /u01/builds/cougaar/B12_4/B12_4/070927151721/src/albbn/src/org/cougaar/logistics/ldm/asset/consumerprops.def - DO NOT HAND EDIT */
028: /** Abstract Asset Skeleton implementation
029: * Implements default property getters, and additional property
030: * lists.
031: * Intended to be extended by org.cougaar.planning.ldm.asset.Asset
032: **/package org.cougaar.logistics.ldm.asset;
033:
034: import org.cougaar.planning.ldm.measure.*;
035: import org.cougaar.planning.ldm.asset.*;
036: import org.cougaar.planning.ldm.plan.*;
037: import java.util.*;
038:
039: import org.cougaar.logistics.ldm.MEIPrototypeProvider;
040: import org.cougaar.logistics.ldm.ClassIConsumerPrototypeProvider;
041: import org.cougaar.util.TimeSpan;
042:
043: import java.io.Serializable;
044: import java.beans.PropertyDescriptor;
045: import java.beans.IndexedPropertyDescriptor;
046:
047: public abstract class AssetSkeleton extends
048: org.cougaar.planning.ldm.asset.Asset {
049:
050: protected AssetSkeleton() {
051: }
052:
053: protected AssetSkeleton(AssetSkeleton prototype) {
054: super (prototype);
055: }
056:
057: /** Default PG accessors **/
058:
059: /** Search additional properties for a RationPG instance.
060: * @return instance of RationPG or null.
061: **/
062: public RationPG getRationPG() {
063: RationPG _tmp = (RationPG) resolvePG(RationPG.class);
064: return (_tmp == RationPG.nullPG) ? null : _tmp;
065: }
066:
067: /** Test for existence of a RationPG
068: **/
069: public boolean hasRationPG() {
070: return (getRationPG() != null);
071: }
072:
073: /** Set the RationPG property.
074: * The default implementation will create a new RationPG
075: * property and add it to the otherPropertyGroup list.
076: * Many subclasses override with local slots.
077: **/
078: public void setRationPG(PropertyGroup aRationPG) {
079: if (aRationPG == null) {
080: removeOtherPropertyGroup(RationPG.class);
081: } else {
082: addOtherPropertyGroup(aRationPG);
083: }
084: }
085:
086: /** Search additional properties for a PackagedPOLConsumerPG instance.
087: * @return instance of PackagedPOLConsumerPG or null.
088: **/
089: public PackagedPOLConsumerPG getPackagedPOLConsumerPG() {
090: PackagedPOLConsumerPG _tmp = (PackagedPOLConsumerPG) resolvePG(PackagedPOLConsumerPG.class);
091: return (_tmp == PackagedPOLConsumerPG.nullPG) ? null : _tmp;
092: }
093:
094: /** Test for existence of a PackagedPOLConsumerPG
095: **/
096: public boolean hasPackagedPOLConsumerPG() {
097: return (getPackagedPOLConsumerPG() != null);
098: }
099:
100: /** Set the PackagedPOLConsumerPG property.
101: * The default implementation will create a new PackagedPOLConsumerPG
102: * property and add it to the otherPropertyGroup list.
103: * Many subclasses override with local slots.
104: **/
105: public void setPackagedPOLConsumerPG(
106: PropertyGroup aPackagedPOLConsumerPG) {
107: if (aPackagedPOLConsumerPG == null) {
108: removeOtherPropertyGroup(PackagedPOLConsumerPG.class);
109: } else {
110: addOtherPropertyGroup(aPackagedPOLConsumerPG);
111: }
112: }
113:
114: /** Search additional properties for a RepairPartConsumerPG instance.
115: * @return instance of RepairPartConsumerPG or null.
116: **/
117: public RepairPartConsumerPG getRepairPartConsumerPG() {
118: RepairPartConsumerPG _tmp = (RepairPartConsumerPG) resolvePG(RepairPartConsumerPG.class);
119: return (_tmp == RepairPartConsumerPG.nullPG) ? null : _tmp;
120: }
121:
122: /** Test for existence of a RepairPartConsumerPG
123: **/
124: public boolean hasRepairPartConsumerPG() {
125: return (getRepairPartConsumerPG() != null);
126: }
127:
128: /** Set the RepairPartConsumerPG property.
129: * The default implementation will create a new RepairPartConsumerPG
130: * property and add it to the otherPropertyGroup list.
131: * Many subclasses override with local slots.
132: **/
133: public void setRepairPartConsumerPG(
134: PropertyGroup aRepairPartConsumerPG) {
135: if (aRepairPartConsumerPG == null) {
136: removeOtherPropertyGroup(RepairPartConsumerPG.class);
137: } else {
138: addOtherPropertyGroup(aRepairPartConsumerPG);
139: }
140: }
141:
142: /** Search additional properties for a SubsistenceConsumerPG instance.
143: * @return instance of SubsistenceConsumerPG or null.
144: **/
145: public SubsistenceConsumerPG getSubsistenceConsumerPG() {
146: SubsistenceConsumerPG _tmp = (SubsistenceConsumerPG) resolvePG(SubsistenceConsumerPG.class);
147: return (_tmp == SubsistenceConsumerPG.nullPG) ? null : _tmp;
148: }
149:
150: /** Test for existence of a SubsistenceConsumerPG
151: **/
152: public boolean hasSubsistenceConsumerPG() {
153: return (getSubsistenceConsumerPG() != null);
154: }
155:
156: /** Set the SubsistenceConsumerPG property.
157: * The default implementation will create a new SubsistenceConsumerPG
158: * property and add it to the otherPropertyGroup list.
159: * Many subclasses override with local slots.
160: **/
161: public void setSubsistenceConsumerPG(
162: PropertyGroup aSubsistenceConsumerPG) {
163: if (aSubsistenceConsumerPG == null) {
164: removeOtherPropertyGroup(SubsistenceConsumerPG.class);
165: } else {
166: addOtherPropertyGroup(aSubsistenceConsumerPG);
167: }
168: }
169:
170: /** Search additional properties for a AmmoConsumerPG instance.
171: * @return instance of AmmoConsumerPG or null.
172: **/
173: public AmmoConsumerPG getAmmoConsumerPG() {
174: AmmoConsumerPG _tmp = (AmmoConsumerPG) resolvePG(AmmoConsumerPG.class);
175: return (_tmp == AmmoConsumerPG.nullPG) ? null : _tmp;
176: }
177:
178: /** Test for existence of a AmmoConsumerPG
179: **/
180: public boolean hasAmmoConsumerPG() {
181: return (getAmmoConsumerPG() != null);
182: }
183:
184: /** Set the AmmoConsumerPG property.
185: * The default implementation will create a new AmmoConsumerPG
186: * property and add it to the otherPropertyGroup list.
187: * Many subclasses override with local slots.
188: **/
189: public void setAmmoConsumerPG(PropertyGroup aAmmoConsumerPG) {
190: if (aAmmoConsumerPG == null) {
191: removeOtherPropertyGroup(AmmoConsumerPG.class);
192: } else {
193: addOtherPropertyGroup(aAmmoConsumerPG);
194: }
195: }
196:
197: /** Search additional properties for a FuelConsumerPG instance.
198: * @return instance of FuelConsumerPG or null.
199: **/
200: public FuelConsumerPG getFuelConsumerPG() {
201: FuelConsumerPG _tmp = (FuelConsumerPG) resolvePG(FuelConsumerPG.class);
202: return (_tmp == FuelConsumerPG.nullPG) ? null : _tmp;
203: }
204:
205: /** Test for existence of a FuelConsumerPG
206: **/
207: public boolean hasFuelConsumerPG() {
208: return (getFuelConsumerPG() != null);
209: }
210:
211: /** Set the FuelConsumerPG property.
212: * The default implementation will create a new FuelConsumerPG
213: * property and add it to the otherPropertyGroup list.
214: * Many subclasses override with local slots.
215: **/
216: public void setFuelConsumerPG(PropertyGroup aFuelConsumerPG) {
217: if (aFuelConsumerPG == null) {
218: removeOtherPropertyGroup(FuelConsumerPG.class);
219: } else {
220: addOtherPropertyGroup(aFuelConsumerPG);
221: }
222: }
223:
224: }
|