FileDocCategorySizeDatePackage
XMLNamedNativeQuery.javaAPI DocGlassfish v2 API4271Tue May 22 16:54:32 BST 2007oracle.toplink.essentials.internal.ejb.cmp3.xml.queries

XMLNamedNativeQuery

public class XMLNamedNativeQuery extends MetadataNamedNativeQuery
Object to hold onto an XML named native query metadata.
author
Guy Pelletier
since
TopLink EJB 3.0 Reference Implementation

Fields Summary
Constructors Summary
public XMLNamedNativeQuery(Node node, XMLHelper helper)
INTERNAL:

        // Set the location where we found this query.
        setLocation(helper.getDocumentName());
        
        // Process the name.
        setName(helper.getNodeValue(node, XMLConstants.ATT_NAME));
        
        // Process the query string.
        setEJBQLString(helper.getNodeTextValue(node, XMLConstants.QUERY));
        
        // Process the query hints.
        NodeList hints = helper.getNodes(node, XMLConstants.QUERY_HINT);
        if (hints != null) {
            for (int i = 0; i < hints.getLength(); i++) {
                Node hintNode = hints.item(i);
                String name = helper.getNodeValue(hintNode, XMLConstants.ATT_NAME);
                String value = helper.getNodeValue(hintNode, XMLConstants.ATT_VALUE);
                addHint(new MetadataQueryHint(name, value));
            }
        }
            
        // Process the result class.
        setResultClass(helper.getNodeValue(node, XMLConstants.ATT_RESULT_CLASS, void.class));
        
        // Process the result set mapping.
        setResultSetMapping(helper.getNodeValue(node, XMLConstants.ATT_RESULT_SET_MAPPING, ""));
    
Methods Summary
public java.lang.StringgetIgnoreLogMessageContext()
INTERNAL:

        return MetadataLogger.IGNORE_NAMED_NATIVE_QUERY_ELEMENT;
    
public booleanloadedFromAnnotations()
INTERNAL:

        return false;
    
public booleanloadedFromXML()
INTERNAL:

        return true;