Package org.jboss.dna.common.collection

Examples of org.jboss.dna.common.collection.SimpleProblems


     * @param connectionFactory the factory for {@link RepositoryConnection}s can be obtained; may not be null
     * @return a configuration reflecting the current state of this instance
     */
    protected synchronized FederatedRepositoryConfig getRepositoryConfiguration( ExecutionContext context,
                                                                                 RepositoryConnectionFactory connectionFactory ) {
        Problems problems = new SimpleProblems();
        ValueFactories valueFactories = context.getValueFactories();
        PathFactory pathFactory = valueFactories.getPathFactory();
        NameFactory nameFactory = valueFactories.getNameFactory();
        ValueFactory<Long> longFactory = valueFactories.getLongFactory();

View Full Code Here


        CheckArg.isNotNull(typeSystem, "typeSystem");
        CheckArg.isNotNull(schemata, "schemata");
        this.typeSystem = typeSystem;
        this.hints = hints != null ? hints : new PlanHints();
        this.schemata = schemata;
        this.problems = problems != null ? problems : new SimpleProblems();
        this.variables = variables != null ? Collections.<String, Object>unmodifiableMap(new HashMap<String, Object>(variables)) : Collections.<String, Object>emptyMap();
        assert this.typeSystem != null;
        assert this.hints != null;
        assert this.schemata != null;
        assert this.problems != null;
View Full Code Here

        addressNode.setProperty("City", "Flagstaff");
        addressNode.setProperty("State", "AZ");
        addressNode.setProperty("Country", "US");
        addressNode.setProperty("Zip Code", 77777);

        problems = new SimpleProblems();
    }
View Full Code Here

     * @param connectionFactory the factory for {@link RepositoryConnection}s can be obtained; may not be null
     * @return a configuration reflecting the current state of this instance
     */
    protected synchronized FederatedRepositoryConfig getRepositoryConfiguration( ExecutionContext context,
                                                                                 RepositoryConnectionFactory connectionFactory ) {
        Problems problems = new SimpleProblems();
        ValueFactories valueFactories = context.getValueFactories();
        NameFactory nameFactory = valueFactories.getNameFactory();
        ValueFactory<Long> longFactory = valueFactories.getLongFactory();
        ProjectionParser projectionParser = ProjectionParser.getInstance();

View Full Code Here

                                   PlanHints hints,
                                   Map<String, Object> variables ) {
            TypeSystem typeSystem = context.getValueFactories().getTypeSystem();
            SearchEngineProcessor processor = searchEngine.createProcessor(context, null, true);
            try {
                QueryContext context = new GraphQueryContext(schemata, typeSystem, hints, new SimpleProblems(), variables,
                                                             processor, workspaceName);
                return queryEngine.execute(context, query);
            } finally {
                processor.close();
            }
View Full Code Here

     * @param resourceNames the name of the resources to load; these resources must be on the classpath
     * @throws IOException if an error loading or reading the any of the resources occurs
     */
    public CndNodeTypeSource( String resourceNames[] ) throws IOException {

        Problems problems = new SimpleProblems();

        // Graph creation requires a context, but there are no security implications for this and namespace mappings are
        // specified in the CND file itself
        ExecutionContext context = new ExecutionContext();
        PathFactory pathFactory = context.getValueFactories().getPathFactory();
View Full Code Here

                                   Problems problems ) {
        super(context);
        this.inputPath = inputPath;
        this.inputProperties = inputProperties != null ? new HashSet<Property>(inputProperties) : new HashSet<Property>();
        this.mimeType = mimeType;
        this.problems = problems != null ? problems : new SimpleProblems();
        Map<Name, Property> inputPropertiesByName = new HashMap<Name, Property>();
        for (Property property : this.inputProperties) {
            inputPropertiesByName.put(property.getName(), property);
        }
        this.inputPropertiesByName = Collections.unmodifiableMap(inputPropertiesByName);
View Full Code Here

    private final RepositoryConnectionFactory connectionFactory;

    protected DnaEngine( ExecutionContext context,
                         DnaConfiguration.ConfigurationDefinition configuration ) {
        this.problems = new SimpleProblems();

        // Use the configuration's context ...
        this.detectors = new MimeTypeDetectors();
        this.context = context.with(detectors);
View Full Code Here

                String sourceName = changedPath.getLastSegment().getName().getLocalName();
                getRepositoryLibrary().removeSource(sourceName);
            } else {
                // The add/change/remove is either at or below a source, so try to create a new source for it ...
                Path sourcePath = changedNodeIsPotentiallySource ? changedPath : changedPath.subpath(0, configPath.size() + 1);
                Problems problems = new SimpleProblems();
                // Now read the node and create the source ...
                Graph graph = Graph.create(getConfigurationSourceName(), getRepositoryLibrary(), getExecutionEnvironment());
                try {
                    String workspaceName = getConfigurationWorkspaceName();
                    if (workspaceName != null) graph.useWorkspace(workspaceName);
View Full Code Here

                    // Get the paths to the nodes where the sequencer should write it's output ...
                    assert outputPaths != null && outputPaths.size() != 0;

                    // Create a new execution context for each sequencer
                    final SimpleProblems problems = new SimpleProblems();
                    SequencerContext sequencerContext = new SequencerContext(context, graph);
                    try {
                        sequencer.execute(node, propertyName, change, outputPaths, sequencerContext, problems);
                        sequencerContext.getDestination().submit();
                    } catch (SequencerException e) {
View Full Code Here

TOP

Related Classes of org.jboss.dna.common.collection.SimpleProblems

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.