private void register() { wsRootDirToWs.put( this.dir, this ); nameToWs.put( name, this ); this.workspace = new DefaultWorkspace( dir ); }
public static void main( String[] args ) { Workspace ws = new DefaultWorkspace(new File("/home/stranger/.deegree/deegree-workspace-utah-3.2-pre9-20120717.234406-9")); ws.initAll(); ws.destroy(); }
/** * Creates the commandline parser and adds the options. * * @param args */ public static void main( String[] args ) { CommandLineParser parser = new PosixParser(); Options options = initOptions(); boolean verbose = false; // for the moment, using the CLI API there is no way to respond to a help argument; see // https://issues.apache.org/jira/browse/CLI-179 if ( args.length == 0 || ( args.length > 0 && ( args[0].contains( "help" ) || args[0].contains( "?" ) ) ) ) { printHelp( options ); } workspace = new DefaultWorkspace( new File( "nix" ) ); try { CommandLine line = parser.parse( options, args ); verbose = line.hasOption( OPT_VERBOSE ); startManager( line ); } catch ( ParseException exp ) { System.err.println( "ERROR: Invalid command line: " + exp.getMessage() ); } catch ( Exception e ) { System.err.println( "ERROR: " + e.getMessage() ); if ( verbose ) { e.printStackTrace(); } System.exit( 1 ); } // System.exit( 0 ); }
workspace = new DefaultWorkspace( new File( "nix" ) );
/** * Creates the commandline parser and adds the options. * * @param args */ public static void main( String[] args ) { CommandLineParser parser = new PosixParser(); Options options = initOptions(); boolean verbose = false; // for the moment, using the CLI API there is no way to respond to a help argument; see // https://issues.apache.org/jira/browse/CLI-179 if ( args.length == 0 || ( args.length > 0 && ( args[0].contains( "help" ) || args[0].contains( "?" ) ) ) ) { printHelp( options ); } workspace = new DefaultWorkspace( new File( "test" ) ); try { CommandLine line = parser.parse( options, args ); verbose = line.hasOption( OPT_VERBOSE ); startModelGeneralizor( line ); } catch ( ParseException exp ) { System.err.println( "ERROR: Invalid command line: " + exp.getMessage() ); } catch ( Exception e ) { System.err.println( "ERROR: " + e.getMessage() ); if ( verbose ) { e.printStackTrace(); } System.exit( 1 ); } // System.exit( 0 ); }
workspace = new DefaultWorkspace( fallbackDir ); } catch ( MalformedURLException e ) { String msg = "Secure Proxy was NOT started, since the configuration could not be loaded.";
public static void main( String[] args ) { if ( args.length == 0 ) { System.out.println( "You must specify the workspace location." ); return; } File wsloc = new File( args[0] ); if ( !wsloc.isDirectory() ) { System.out.println( "Workspace location does not exist or is not a directory." ); return; } Workspace ws = null; try { ws = new DefaultWorkspace( wsloc ); ws.initAll(); new FeatureLayerExtractor( ws ).extract(); new ThemeExtractor( ws ).transform(); } catch ( Throwable e ) { System.out.println( "There was a problem transforming the configuration." ); e.printStackTrace(); } finally { if ( ws != null ) { ws.destroy(); } } }
Workspace workspace = new DefaultWorkspace( dir ); String user = null; if ( properties != null ) {
out.setDefaultNamespace( ns ); Workspace ws = new DefaultWorkspace( new File( "nix" ) ); ws.initAll(); DefaultResourceIdentifier<FeatureStore> identifier = new DefaultResourceIdentifier<FeatureStore>(
Workspace ws = new DefaultWorkspace( new File( workspace ) ); ws.initAll();
workspace = new DefaultWorkspace( baseDir );
"deegree_postgis" ); loc = new DefaultResourceLocation<FeatureStore>( new File( inputFileName ), id ); Workspace ws = new DefaultWorkspace( new File( "nix" ) ); ws.initAll(); ws.add( loc );
file.delete(); file.mkdir(); Workspace workspace = new DefaultWorkspace( file ); workspace.getLocationHandler().addExtraResource( ConnectionProviderUtils.getSyntheticProvider( "style", url, user,
/** * Simple importer for SE files, with hardcoded 'configtool' on localhost. * * @param args * @throws XMLStreamException * @throws FactoryConfigurationError * @throws IOException */ public static void main( String[] args ) throws XMLStreamException, FactoryConfigurationError, IOException { Style style = new SymbologyParser( true ).parse( XMLInputFactory.newInstance().createXMLStreamReader( new FileInputStream( args[0] ) ) ); Workspace workspace = new DefaultWorkspace( new File( "nonexistant" ) ); ResourceLocation<ConnectionProvider> loc = ConnectionProviderUtils.getSyntheticProvider( "configtool", "jdbc:postgresql://localhost/configtool", "postgres", "postgres" ); workspace.getLocationHandler().addExtraResource( loc ); workspace.initAll(); if ( style.isSimple() ) { new PostgreSQLWriter( "configtool", "schematest", workspace ).write( style, null ); } else { new PostgreSQLWriter( "configtool", "schematest", workspace ).write( new FileInputStream( args[0] ), style.getName() ); } workspace.destroy(); }
Style style = new SymbologyParser( true ).parse( fac.createXMLStreamReader( new FileInputStream( inputFile ) ) ); Workspace workspace = new DefaultWorkspace( new File( "nonexistant" ) ); ResourceLocation<ConnectionProvider> loc = ConnectionProviderUtils.getSyntheticProvider( "style", url, user, pass );