ServerSession extends AbstractSession implements Wrapper { @Override public <T> T unwrap(Class<T> cls) { Objects.requireNonNull(cls); if (cls.isAssignableFrom(getClass())) { return cls.cast(this); } return storageAccessor.unwrap(cls); } ServerSession();  ServerSession(OntologyStorageProperties storageProperties, Configuration configuration,
                         MetamodelImpl metamodel); @Override UnitOfWork acquireUnitOfWork(); @Override CacheManager getLiveObjectCache(); void transactionStarted(EntityTransaction t, AbstractEntityManager em); void transactionFinished(EntityTransaction t); void close(); @Override void removeObjectFromCache(Object object, URI context); @Override MetamodelImpl getMetamodel(); @Override boolean isEntityType(Class<?> cls); @Override NamedQueryManager getNamedQueryManager(); @Override ResultSetMappingManager getResultSetMappingManager(); @Override T unwrap(Class<T> cls);  }
@Test public void unwrapServerSessionReturnsItself() { assertSame(session, session.unwrap(ServerSession.class)); }
@Test public void unwrapCallThroughToStorageAccessorIfClassDoesNotMatch() { final StorageAccessor sa = session.unwrap(StorageAccessor.class); assertNotNull(sa); }