Package net.sf.joafip.store.service

Examples of net.sf.joafip.store.service.StoreException


          classInfoFactory, helperBinaryConversion,
          store.getProxyManager2());
      objectIOManager
          .setGarbageManagement(false, null/* garbageManager */);
    } catch (ObjectIOException exception) {
      throw new StoreException(exception);
    }
  }
View Full Code Here


  public DataRecordIdentifier getNextFreeDataRecordIdentifier()
      throws StoreException {
    try {
      return dataManager.getNextFreeDataRecordIdentifier();
    } catch (HeapException exception) {
      throw new StoreException(exception);
    }
  }
View Full Code Here

  public void clearMemory() throws StoreException {
    try {
      dataManager.clearStandbyModification();
      objectIOManager.clearObjectState();
    } catch (ObjectIOException exception) {
      throw new StoreException(exception);
    } catch (HeapException exception) {
      throw new StoreException(exception);
    }
  }
View Full Code Here

  public ClassInfo getNoProxyClassInfo(final Class<?> objectClass)
      throws StoreException {
    try {
      return classInfoFactory.getNoProxyClassInfo(objectClass);
    } catch (ClassInfoException exception) {
      throw new StoreException(exception);
    }
  }
View Full Code Here

      StoreDataCorruptedException {
    try {
      return objectIOManager
          .getClassInfoInDataRecord(dataRecordIdentifier);
    } catch (ObjectIOException exception) {
      throw new StoreException(FOR_DATA_RECORD + dataRecordIdentifier,
          exception);
    } catch (ObjectIODataRecordNotFoundException exception) {
      throw new StoreException(FOR_DATA_RECORD + dataRecordIdentifier,
          exception);
    } catch (ObjectIOClassNotFoundException exception) {
      throw new StoreClassNotFoundException(FOR_DATA_RECORD
          + dataRecordIdentifier, exception);
    } catch (ObjectIODataCorruptedException exception) {
View Full Code Here

    ObjectAndItsClassInfo objectAndItsClassInfo;
    try {
      objectAndItsClassInfo = objectIOManager
          .createReadingInStoreGenericObjectNotLazy(dataRecordIdentifier);
    } catch (ObjectIOException exception) {
      throw new StoreException(FOR_DATA_RECORD + dataRecordIdentifier,
          exception);
    } catch (ObjectIODataRecordNotFoundException exception) {
      throw new StoreException(FOR_DATA_RECORD + dataRecordIdentifier,
          exception);
    } catch (ObjectIOClassNotFoundException exception) {
      throw new StoreClassNotFoundException(FOR_DATA_RECORD
          + dataRecordIdentifier, exception);
    } catch (ObjectIOInvalidClassException exception) {
View Full Code Here

      throws StoreException {
    try {
      return objectIOManager
          .getDataRecordIdentifierAssociatedToObject(object);
    } catch (ObjectIOException exception) {
      throw new StoreException(exception);
    }
  }
View Full Code Here

      StoreClassNotFoundException {
    this.exportPersistedClassByteCode = exportPersistedClassByteCode;
    final File directory = new File(directoryName);
    if (directory.exists()) {
      if (!directory.isDirectory()) {
        throw new StoreException(directory
            + " exists and is not a directory");
      }
    } else if (!directory.mkdirs()) {
      throw new StoreException("failed create directory " + directory);
    }

    if (exportPersistedClassByteCode) {
      classDirectory = new File(directory, "class");
      if (classDirectory.exists()) {
        if (classDirectory.isDirectory()) {
          final File[] files = classDirectory.listFiles();
          for (final File file : files) {
            if (file.getName().endsWith(".class") && !file.delete()) {// NOPMD
              throw new StoreException("failed delete " + file);
            }
          }
        } else if (!classDirectory.delete()) {
          throw new StoreException("failed delete " + classDirectory);
        }
      } else if (!classDirectory.mkdirs()) {
        throw new StoreException("failed create directory "
            + classDirectory);
      }
      classSet = new HashSet<Class<?>>();
    }

    final File temporaryDirectory = new File(temporaryDirectoryName);
    if (temporaryDirectory.exists()) {
      if (!temporaryDirectory.isDirectory()) {
        throw new StoreException(temporaryDirectory
            + " exists and is not a directory");
      }
    } else if (!temporaryDirectory.mkdirs()) {
      throw new StoreException("failed create directory "
          + temporaryDirectory);
    }

    try {
      exportStoreQue = new PersistantDataRecordIdentifierSetQue(temporaryDirectoryName);
    } catch (HeapException exception) {
      throw new StoreException(exception);
    }
    open(directory);
  }
View Full Code Here

      if (listener != null) {
        listener.numberOfExported(numberExported);
      }
      endExportVisit();
    } catch (final ClassInfoException exception) {
      throw new StoreException(exception);
    } catch (HeapException exception) {
      throw new StoreException(exception);
    }
  }
View Full Code Here

        FieldInfo[] fieldInfos;
        try {
          fieldInfos = objectClassInfo
              .allDeclaredFieldsWithTransientWithoutStatic();
        } catch (final ClassInfoException exception) {
          throw new StoreException(exception);
        }
        exportEnum(objectIdentifier, object, objectClassInfo,
            fieldInfos);
      } else {
        FieldInfo[] fieldInfos;
        try {
          fieldInfos = objectClassInfo
              .allDeclaredFieldsWithTransientWithoutStatic();
        } catch (final ClassInfoException exception) {
          throw new StoreException(exception);
        }
        exportGeneric(objectIdentifier, object, objectClassInfo,
            fieldInfos);
      }
      objectIdentifier = objectIdQue.pollFirst();
View Full Code Here

TOP

Related Classes of net.sf.joafip.store.service.StoreException

Copyright © 2018 www.massapicom. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.