/**
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS HEADER.
*
* Copyright (c) 2006 Sun Microsystems Inc. All Rights Reserved
*
* The contents of this file are subject to the terms
* of the Common Development and Distribution License
* (the License). You may not use this file except in
* compliance with the License.
*
* You can obtain a copy of the License at
* See the License for the specific language governing
* permission and limitations under the License.
*
* When distributing Covered Code, include this CDDL
* Header Notice in each file and include the License file
* at opensso/legal/CDDLv1.0.txt.
* If applicable, add the following below the CDDL Header,
* with the fields enclosed by brackets [] replaced by
* your own identifying information:
* "Portions Copyrighted [year] [name of copyright owner]"
*
* $Id: DSTQuery.java,v 1.3 2008/06/25 05:47:13 qcheng Exp $
*
*/
/**
* The <code>DSTQuery</code> class represents a <code>DST</code> query request.
* <p>The following schema fragment specifies the expected content within the
* <code>DSTQuery</code> object.
* <p>
* <pre>
* <complexType name="QueryType">
* <complexContent>
* <restriction base="{http://www.w3.org/2001/XMLSchema}anyType">
* <sequence>
* <group ref="{urn:liberty:idpp:2003-08}ResourceIDGroup"/>
* <element name="QueryItem" maxOccurs="unbounded">
* <complexType>
* <complexContent>
* <restriction base="{http://www.w3.org/2001/XMLSchema}
* anyType">
* <sequence>
* <element name="Select"
* type="{urn:liberty:idpp:2003-08}SelectType"/>
* </sequence>
* <attribute name="id"
* type="{http://www.w3.org/2001/XMLSchema}ID" />
* <attribute name="changedSince"
* type="{http://www.w3.org/2001/XMLSchema}dateTime" />
* <attribute name="itemID"
* type="{urn:liberty:idpp:2003-08}IDType" />
* <attribute name="includeCommonAttributes"
* type="{http://www.w3.org/2001/XMLSchema}boolean" />
* </restriction>
* </complexContent>
* </complexType>
* </element>
* <element ref="{urn:liberty:idpp:2003-08}Extension"
* maxOccurs="unbounded" minOccurs="0"/>
* </sequence>
* <attribute name="itemID" type="{urn:liberty:idpp:2003-08}IDType" />
* <attribute name="id" type="{http://www.w3.org/2001/XMLSchema}ID" />
* </restriction>
* </complexContent>
* </complexType>
* </pre>
*
* @supported.all.api
*/
public class DSTQuery {
/**
* Constructor
*/
public DSTQuery() {}
/**
* Constructor
* @param resourceID id for the resource to be queried.
* @param items List of <code>DSTQueryItem</code> objects.
* @param serviceNS service name space.
*/
this.resourceID = resourceID;
} else {
}
}
}
/**
* Constructor
* @param encResourceID id for the encrypted resource to be queried.
* @param items list of <code>DSTQueryItem</code> objects.
* @param serviceNS service name space.
*/
this.encryptedResourceID = encResourceID;
} else {
}
}
}
/**
* Constructor
*
* @param element <code>DOM</code> Element.
* @throws DSTException
*/
}
}
if(nameSpaceURI == null) {
}
nameSpaceURI, "ResourceID");
" or more than one resource id is found.");
throw new DSTException(
}
if(resourceID == null) {
throw new DSTException(
}
nameSpaceURI, "QueryItem");
throw new DSTException(
}
for(int i=0; i < size; i++) {
}
}
/**
* Gets the value of the <code>QueryItem</code> property.
*
* @return List of <code>DSTQueryItem</code> objects
*/
return dstQueryItems;
}
/**
* Sets the value of the <code>QueryItem</code> property.
*
* @param items List of <code>DSTQueryItem</code> objects
*/
}
}
/**
* Gets id attribute.
*
* @return id attribute.
*/
return id;
}
/**
* Sets id attribute
* @param id value of id to be set
*/
}
/**
* Gets encrypted resource ID.
* @return Encrypted resource ID.
*/
return encryptedResourceID;
}
/**
* Sets encrypted resource ID for the <code>DST</code> query.
*
* @param encResourceID encrypted resource ID.
*/
public void setEncryptedResourceID(
this.encryptedResourceID = encResourceID;
}
/**
* Gets resource ID.
*
* @return resource ID.
*/
return resourceID;
}
/**
* Sets resource ID for the <code>DST</code> query.
* @param resourceID resource ID to be set
*/
this.resourceID = resourceID;
}
/**
* Gets item ID attribute
* @return String
*/
return itemID;
}
/**
* Sets item ID attribute
* @param value item ID to be set
*/
}
/**
* Gets the extension property.
*
* @return List of any Object
*
*/
return extensions;
}
/**
* Gets the name space.
* @return name space.
*/
return nameSpaceURI;
}
/**
* Sets the name space.
*
* @param nameSpace Name space URI.
*/
this.nameSpaceURI = nameSpace;
}
/**
* Sets the name space prefix.
* @param prefix Name space prefix.
*/
}
/**
* Gets the name space prefix.
* @return Name space prefix.
*/
return prefix;
}
/**
* Creates a String representation of this object.
* By default name space name is prepended to the element name
* @return String A string containing the valid XML for this element
*/
return toString(true, false);
}
/**
* Creates a String representation of this object.
* @param includeNS if true prepends all elements by their name space prefix
* @param declareNS if true includes the name space within the
* generated.
* @return String A string containing the valid XML for this element
*/
dstQueryItems.isEmpty()) {
" are null.");
return "";
}
if(includeNS) {
}
}
"not defined");
return "";
}
}
}
if(declareNS) {
}
if(encryptedResourceID == null) {
} else {
}
}
}
}
}