JAXBContextCache.CachedContextAndSchemas (Apache CXF JavaDoc 4.2.1 API)
Description: declaration: package: org.apache.cxf.common.jaxb, class: JAXBContextCache, class: CachedContextAndSchemas

Package org.apache.cxf.common.jaxb

# Class JAXBContextCache.CachedContextAndSchemas

java.lang.Object
org.apache.cxf.common.jaxb.JAXBContextCache.CachedContextAndSchemas

Enclosing class:
  `JAXBContextCache`

public static final class JAXBContextCache.CachedContextAndSchemas extends Object
Return holder of the context, classes, etc... Do NOT hold onto these strongly as that can lock the JAXBContext and Set objects into memory. It preferred to grab the context and classes (if needed) from this object immediately after the call to getCachedContextAndSchemas and then discard it. The main purpose of this class is to hold onto the context/set strongly until the caller has a chance to copy those into a place where they can hold onto it strongly as needed.

- ## Method Summary

  Modifier and Type
  Method
  Description
  `Set<Class<?>>`
  `getClasses()`
  `jakarta.xml.bind.JAXBContext`
  `getContext()`
  `Collection<DOMSource>`
  `getSchemas()`
  `void`
  `setSchemas(Collection<DOMSource> schemas)`

  ### Methods inherited from class java.lang.Object

  `clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait`

- ## Method Details

  - ### getContext

    public jakarta.xml.bind.JAXBContext getContext()

  - ### getClasses

    public Set<Class<?>> getClasses()

  - ### getSchemas

    public Collection<DOMSource> getSchemas()

  - ### setSchemas

    public void setSchemas(Collection<DOMSource> schemas)