Examples of ConfigurationScope


Examples of org.eclipse.core.runtime.preferences.ConfigurationScope

     *         installation
     */
    public synchronized Preferences getConfigPrefs() {
        // TODO Singleton-Pattern code smell: ConfigPrefs should be a @component
        if (configPrefs == null) {
            configPrefs = new ConfigurationScope().getNode(SAROS);
        }
        return configPrefs;
    }
View Full Code Here

Examples of org.eclipse.core.runtime.preferences.ConfigurationScope

                    Log.log(e);
                }
            }

            // saves the id in configuration scope so it's shared by all workspaces
            IEclipsePreferences prefs = (new ConfigurationScope()).getNode(qualifier);
            prefs.put(key, id);
            try {
                prefs.flush();
            } catch (BackingStoreException e) {
                Log.log(e);
View Full Code Here

Examples of org.eclipse.core.runtime.preferences.ConfigurationScope


    public GeneralPreferencePage()
    {
        super( GRID );
        preferences = new ScopedPreferenceStore( new ConfigurationScope(), Application.PLUGIN_ID );
        setPreferenceStore( preferences );
    }
View Full Code Here

Examples of org.eclipse.core.runtime.preferences.ConfigurationScope


    public SchemaPreferencePage()
    {
        super( GRID );
        preferences = new ScopedPreferenceStore( new ConfigurationScope(), Application.PLUGIN_ID );
        setPreferenceStore( preferences );
    }
View Full Code Here

Examples of org.eclipse.core.runtime.preferences.ConfigurationScope

    public void run()
    {
        FileDialog fd = new FileDialog( PlatformUI.getWorkbench().getActiveWorkbenchWindow().getShell(), SWT.OPEN );
        fd.setText( Messages.getString( "OpenLocalFileAction.Open_a_schema_file" ) ); //$NON-NLS-1$

        IEclipsePreferences prefs = new ConfigurationScope().getNode( Application.PLUGIN_ID );
        String defaultPath = prefs.get( SchemaPreferencePage.DEFAULT_DIRECTORY, System.getProperty( "user.home" ) ); //$NON-NLS-1$
        fd.setFilterPath( defaultPath );
        String[] filterExt =
            { "*.schema", "*.*" }; //$NON-NLS-1$ //$NON-NLS-2$
        fd.setFilterExtensions( filterExt );
View Full Code Here

Examples of org.eclipse.core.runtime.preferences.ConfigurationScope

        if ( this.url == null )
        {
            FileDialog fd = new FileDialog( new Shell(), SWT.SAVE );
            fd.setText( Messages.getString( "Schema.Save_this_schema" ) + this.getName() ); //$NON-NLS-1$
            IEclipsePreferences prefs = new ConfigurationScope().getNode( Application.PLUGIN_ID );
            String defaultPath = prefs.get( SchemaPreferencePage.DEFAULT_DIRECTORY, System.getProperty( "user.home" ) ); //$NON-NLS-1$
            fd.setFilterPath( defaultPath );
            fd.setFileName( this.name + ".schema" ); //$NON-NLS-1$
            fd.setFilterExtensions( new String[]
                { "*.schema", "*.*" } ); //$NON-NLS-1$ //$NON-NLS-2$
View Full Code Here

Examples of org.eclipse.core.runtime.preferences.ConfigurationScope

            }
        }

        FileDialog fd = new FileDialog( PlatformUI.getWorkbench().getActiveWorkbenchWindow().getShell(), SWT.SAVE );
        fd.setText( Messages.getString( "Schema.Save_this_schema" ) + this.getName() ); //$NON-NLS-1$
        IEclipsePreferences prefs = new ConfigurationScope().getNode( Application.PLUGIN_ID );
        String defaultPath = prefs.get( SchemaPreferencePage.DEFAULT_DIRECTORY, System.getProperty( "user.home" ) ); //$NON-NLS-1$
        fd.setFilterPath( defaultPath );
        fd.setFileName( this.name + ".schema" ); //$NON-NLS-1$
        fd.setFilterExtensions( new String[]
            { "*.schema", "*.*" } ); //$NON-NLS-1$ //$NON-NLS-2$
View Full Code Here

Examples of org.eclipse.core.runtime.preferences.ConfigurationScope

     */
    public void savePool()
    {
        try
        {
            Preferences prefs = new ConfigurationScope().getNode( Application.PLUGIN_ID );
            Preferences saved_workspace = prefs.node( SAVED_WORKSPACE );

            //we only store the references to schemas that have ALREADY
            //been saved. -> url != null
            for ( Schema schema : schemaList )
View Full Code Here

Examples of org.eclipse.core.runtime.preferences.ConfigurationScope

     */
    public void loadPool()
    {
        try
        {
            Preferences prefs = new ConfigurationScope().getNode( Application.PLUGIN_ID );
            Preferences saved_workspace = prefs.node( SAVED_WORKSPACE );
            String[] schemaNames = saved_workspace.childrenNames();
            for ( String name : schemaNames )
            {
                Preferences node = saved_workspace.node( name );
View Full Code Here

Examples of org.eclipse.core.runtime.preferences.ConfigurationScope

    }


    private static void initializeWithSpecified( SchemaPool pool )
    {
        IEclipsePreferences prefs = new ConfigurationScope().getNode( Application.PLUGIN_ID );
        String specificPath = prefs
            .get( SchemaPreferencePage.SPECIFIC_CORE_DIRECTORY, System.getProperty( "user.home" ) ); //$NON-NLS-1$

        File dir = new File( specificPath );
        String sCurPath = dir.getAbsolutePath() + File.separator;
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.