## com.saxonica.extra
Class AttributeCopier

    java.lang.Object
      com.saxonica.validate.Checker
          com.saxonica.extra.AttributeCopier

All Implemented Interfaces:
  javax.xml.transform.Result, Receiver

    public class AttributeCopier

extends Checker

A Checker is a Receiver used to check the content of elements and attributes, especially those that participate in uniqueness, key, and keyref constraints. The AttributeCopier is the Checker that checks the content of attributes: basically by passing any that match the selection criteria to the next stage in the pipeline

Field Summary

Fields inherited from interface javax.xml.transform.Result
`PI_DISABLE_OUTPUT_ESCAPING, PI_ENABLE_OUTPUT_ESCAPING`

Constructor Summary
`AttributeCopier(Selection selection, Receiver nextReceiver)` Create an AttributeCopier

Method Summary
`void` `attribute(int nameCode, int typeCode, java.lang.CharSequence value, int locationId, int properties)` Notify an attribute, passing it on to the receiver if it matches the selection
`void` `startContent()` Notify the start of the content, that is, the completion of all attributes and namespaces.

Methods inherited from class com.saxonica.validate.Checker
`characters, close, comment, endDocument, endElement, getConfiguration, getPipelineConfiguration, getSystemId, namespace, open, processingInstruction, setPipelineConfiguration, setSystemId, setUnparsedEntity, startDocument, startElement`

Methods inherited from class java.lang.Object
`clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait`

Constructor Detail

### AttributeCopier

    public AttributeCopier(Selection selection,
                           Receiver nextReceiver)

  Create an AttributeCopier

  Parameters:
    `selection` - the conditions that this checker is watching for
    `nextReceiver` - the next stage in the pipeline, to receive matching attribute nodes

Method Detail

### attribute

    public void attribute(int nameCode,
                          int typeCode,
                          java.lang.CharSequence value,
                          int locationId,
                          int properties)
                   throws XPathException

  Notify an attribute, passing it on to the receiver if it matches the selection

  Specified by:
    `attribute` in interface `Receiver`
  Overrides:
    `attribute` in class `Checker`
  Parameters:
    `nameCode` - The name of the attribute, as held in the name pool
    `typeCode` - The type of the attribute, as held in the name pool. The additional bit NodeInfo.IS_DTD_TYPE may be set to indicate a DTD-derived type.
    `value` - the string value of the attribute
    `locationId` - an integer which can be interpreted using a `LocationProvider` to return information such as line number and system ID. If no location information is available, the value zero is supplied.
    `properties` - Bit significant value. The following bits are defined:
  DISABLE_ESCAPING
    Disable escaping for this attribute
  NO_SPECIAL_CHARACTERS
    Attribute value contains no special characters
  Throws:
    `XPathException`

### startContent

    public void startContent()
                      throws XPathException

  Description copied from interface: `Receiver`
  Notify the start of the content, that is, the completion of all attributes and namespaces. Note that the initial receiver of output from XSLT instructions will not receive this event, it has to detect it itself. Note that this event is reported for every element even if it has no attributes, no namespaces, and no content.

  Specified by:
    `startContent` in interface `Receiver`
  Overrides:
    `startContent` in class `Checker`
  Throws:
    `XPathException`

Copyright (c) Saxonica Limited. All rights reserved.