## org.exist.xmldb
Class LocalResourceSet

    java.lang.Object
      org.exist.xmldb.LocalResourceSet

All Implemented Interfaces:
  ResourceSet

public class LocalResourceSet
extends java.lang.Object
implements ResourceSet

Constructor Summary
`LocalResourceSet(User user, BrokerPool pool, LocalCollection col, java.util.Properties properties, Sequence val, java.lang.String sortExpr)`

Method Summary
`void` `addResource(Resource resource)` Adds a `Resource` instance to the set.
`void` `clear()` Removes all `Resource` instances from the set.
`ResourceIterator` `getIterator()` Returns an iterator over all `Resource` instances stored in the set.
`ResourceIterator` `getIterator(long start)`
`Resource` `getMembersAsResource()` Returns a Resource containing an XML representation of all resources stored in the set.
`Resource` `getResource(long pos)`
`long` `getSize()` Gets the size attribute of the LocalResourceSet object
`void` `removeResource(long pos)` Description of the Method

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

Methods inherited from interface org.xmldb.api.base.ResourceSet
`addAll, getResource, removeResource`

Constructor Detail

### LocalResourceSet

    public LocalResourceSet(User user,
                            BrokerPool pool,
                            LocalCollection col,
                            java.util.Properties properties,
                            Sequence val,
                            java.lang.String sortExpr)
                     throws XMLDBException

Method Detail

### addResource

    public void addResource(Resource resource)
                     throws XMLDBException

  Description copied from interface: `ResourceSet`
  Adds a `Resource` instance to the set.

  Specified by:
    `addResource` in interface `ResourceSet`
  Parameters:
    `resource` - The `Resource` to add to the set.
  Throws:
    `XMLDBException` - with expected error codes.
    `ErrorCodes.VENDOR_ERROR` for any vendor specific errors that occur.

### clear

    public void clear()
               throws XMLDBException

  Description copied from interface: `ResourceSet`
  Removes all `Resource` instances from the set.

  Specified by:
    `clear` in interface `ResourceSet`
  Throws:
    `XMLDBException` - with expected error codes.
    `ErrorCodes.VENDOR_ERROR` for any vendor specific errors that occur.

### getIterator

    public ResourceIterator getIterator()
                                 throws XMLDBException

  Description copied from interface: `ResourceSet`
  Returns an iterator over all `Resource` instances stored in the set.

  Specified by:
    `getIterator` in interface `ResourceSet`
  Returns:
    a `ResourceIterator` over all `Resource` instances in the set.
  Throws:
    `XMLDBException` - with expected error codes.
    `ErrorCodes.VENDOR_ERROR` for any vendor specific errors that occur.

### getIterator

    public ResourceIterator getIterator(long start)
                                 throws XMLDBException

  Throws:
    `XMLDBException`

### getMembersAsResource

    public Resource getMembersAsResource()
                                  throws XMLDBException

  Description copied from interface: `ResourceSet`
  Returns a Resource containing an XML representation of all resources stored in the set.

  TODO: Specify the schema used for this

  Specified by:
    `getMembersAsResource` in interface `ResourceSet`
  Returns:
    A `Resource` instance containing an XML representation of all set members.
  Throws:
    `XMLDBException` - with expected error codes.
    `ErrorCodes.VENDOR_ERROR` for any vendor specific errors that occur.

### getResource

    public Resource getResource(long pos)
                         throws XMLDBException

  Throws:
    `XMLDBException`

### getSize

    public long getSize()
                 throws XMLDBException

  Gets the size attribute of the LocalResourceSet object

  Specified by:
    `getSize` in interface `ResourceSet`
  Returns:
    The size value
  Throws:
    `XMLDBException` - Description of the Exception

### removeResource

    public void removeResource(long pos)
                        throws XMLDBException

  Description of the Method

  Parameters:
    `pos` - Description of the Parameter
  Throws:
    `XMLDBException` - Description of the Exception

Copyright (C) Wolfgang Meier. All rights reserved.