Package org.eclipse.osgi.storagemanager

Examples of org.eclipse.osgi.storagemanager.StorageManager.lookup()


    if (currentConfiguration != null && (parentConfiguration = currentConfiguration.getParentLocation()) != null) {
      try {
        File stateLocationDir = new File(parentConfiguration.getURL().getFile(), FrameworkAdaptor.FRAMEWORK_SYMBOLICNAME);
        StorageManager newFileManager = initFileManager(stateLocationDir, "none", true); //$NON-NLS-1$);
        for (int i = 0; i < storageFiles.length; i++)
          storageFiles[i] = newFileManager.lookup(fileNames[i], false);
        newFileManager.close();
      } catch (IOException ex) {
        if (Debug.DEBUG && Debug.DEBUG_GENERAL) {
          Debug.println("Error reading state file " + ex.getMessage()); //$NON-NLS-1$
          Debug.printStackTrace(ex);
View Full Code Here


      StorageManager storageManager = new StorageManager(stateDirectory, "none", true); //$NON-NLS-1$
      try {
        // if the directory is pointing at the configuration directory then the base files will not exist
        storageManager.open(true);
        // try using the storage manager to find the managed state files (bug 143255)
        File managedState = storageManager.lookup(StateReader.STATE_FILE, false);
        File managedLazy = storageManager.lookup(StateReader.LAZY_FILE, false);
        if (managedState != null && managedLazy != null) {
          stateFile = managedState;
          lazyFile = managedLazy;
        }
View Full Code Here

      try {
        // if the directory is pointing at the configuration directory then the base files will not exist
        storageManager.open(true);
        // try using the storage manager to find the managed state files (bug 143255)
        File managedState = storageManager.lookup(StateReader.STATE_FILE, false);
        File managedLazy = storageManager.lookup(StateReader.LAZY_FILE, false);
        if (managedState != null && managedLazy != null) {
          stateFile = managedState;
          lazyFile = managedLazy;
        }
      } finally {
View Full Code Here

      StorageManager storageManager = new StorageManager(stateDirectory, "none", true); //$NON-NLS-1$
      try {
        // if the directory is pointing at the configuration directory then the base files will not exist
        storageManager.open(true);
        // try using the storage manager to find the managed state files (bug 143255)
        File managedState = storageManager.lookup(StateReader.STATE_FILE, false);
        File managedLazy = storageManager.lookup(StateReader.LAZY_FILE, false);
        if (managedState != null && managedLazy != null) {
          stateFile = managedState;
          lazyFile = managedLazy;
        }
View Full Code Here

      try {
        // if the directory is pointing at the configuration directory then the base files will not exist
        storageManager.open(true);
        // try using the storage manager to find the managed state files (bug 143255)
        File managedState = storageManager.lookup(StateReader.STATE_FILE, false);
        File managedLazy = storageManager.lookup(StateReader.LAZY_FILE, false);
        if (managedState != null && managedLazy != null) {
          stateFile = managedState;
          lazyFile = managedLazy;
        }
      } finally {
View Full Code Here

    if (currentConfiguration != null && (parentConfiguration = currentConfiguration.getParentLocation()) != null) {
      try {
        File stateLocationDir = new File(parentConfiguration.getURL().getFile(), FrameworkAdaptor.FRAMEWORK_SYMBOLICNAME);
        StorageManager newFileManager = initFileManager(stateLocationDir, "none", true); //$NON-NLS-1$);
        for (int i = 0; i < storageFiles.length; i++)
          storageFiles[i] = newFileManager.lookup(fileNames[i], false);
        newFileManager.close();
      } catch (IOException ex) {
        if (Debug.DEBUG_GENERAL) {
          Debug.println("Error reading state file " + ex.getMessage()); //$NON-NLS-1$
          Debug.printStackTrace(ex);
View Full Code Here

      StorageManager storageManager = new StorageManager(stateDirectory, "none", true); //$NON-NLS-1$
      try {
        // if the directory is pointing at the configuration directory then the base files will not exist
        storageManager.open(true);
        // try using the storage manager to find the managed state files (bug 143255)
        File managedState = storageManager.lookup(StateReader.STATE_FILE, false);
        File managedLazy = storageManager.lookup(StateReader.LAZY_FILE, false);
        if (managedState != null && managedLazy != null) {
          stateFile = managedState;
          lazyFile = managedLazy;
        }
View Full Code Here

      try {
        // if the directory is pointing at the configuration directory then the base files will not exist
        storageManager.open(true);
        // try using the storage manager to find the managed state files (bug 143255)
        File managedState = storageManager.lookup(StateReader.STATE_FILE, false);
        File managedLazy = storageManager.lookup(StateReader.LAZY_FILE, false);
        if (managedState != null && managedLazy != null) {
          stateFile = managedState;
          lazyFile = managedLazy;
        }
      } finally {
View Full Code Here

    if (currentConfiguration != null && (parentConfiguration = currentConfiguration.getParentLocation()) != null) {
      try {
        File stateLocationDir = new File(parentConfiguration.getURL().getFile(), FrameworkAdaptor.FRAMEWORK_SYMBOLICNAME);
        StorageManager newFileManager = initFileManager(stateLocationDir, "none", true); //$NON-NLS-1$);
        for (int i = 0; i < storageFiles.length; i++)
          storageFiles[i] = newFileManager.lookup(fileNames[i], false);
        newFileManager.close();
      } catch (IOException ex) {
        if (Debug.DEBUG && Debug.DEBUG_GENERAL) {
          Debug.println("Error reading state file " + ex.getMessage()); //$NON-NLS-1$
          Debug.printStackTrace(ex);
View Full Code Here

        Location parent = location.getParentLocation();
        if (parent != null) {
          theStorageDir = new File(parent.getURL().getPath() + '/' + Activator.PI_APP);
          StorageManager tmp = new StorageManager(theStorageDir, "none", true); //$NON-NLS-1$
          tmp.open(false);
          dataFile = tmp.lookup(fileName, false);
          tmp.close();
        }
      }
      if (dataFile == null || !dataFile.isFile())
        return true;
View Full Code Here

TOP
Copyright © 2018 www.massapi.com. 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.