Examples of Scope


Examples of org.apache.isis.viewer.scimpi.dispatcher.context.RequestContext.Scope

        final String sourceObjectId = objectOrResult(request);
        final Class<?> cls = forClass(request);
        final String variableName = request.getRequiredProperty(NAME);
        final String defaultObjectId = request.getOptionalProperty(DEFAULT);
        final String scopeName = request.getOptionalProperty(SCOPE);
        final Scope scope = RequestContext.scope(scopeName, Scope.REQUEST);

        final RequestContext context = request.getContext();
        final ObjectAdapter sourceObject = context.getMappedObject(sourceObjectId);
        final boolean isSourceSet = sourceObject != null;
        final boolean isSourceAssignable = isSourceSet && (cls == null || cls.isAssignableFrom(sourceObject.getObject().getClass()));
View Full Code Here

Examples of org.apache.jackrabbit.webdav.lock.Scope

            checkSessionInfo(sessionInfo);
            long davTimeout = (timeoutHint == Long.MAX_VALUE) ? INFINITE_TIMEOUT : timeoutHint*1000;
            String ownerInfo = (ownerHint == null) ? sessionInfo.getUserID() : ownerHint;

            String uri = getItemUri(nodeId, sessionInfo);
            Scope scope = (sessionScoped) ? ItemResourceConstants.EXCLUSIVE_SESSION : Scope.EXCLUSIVE;
            LockMethod method = new LockMethod(uri, scope, Type.WRITE, ownerInfo, davTimeout , deep);
            execute(method, sessionInfo);

            String lockToken = method.getLockToken();
            ((SessionInfoImpl) sessionInfo).addLockToken(lockToken, sessionScoped);
View Full Code Here

Examples of org.apache.jackrabbit.webdav.lock.Scope

    private LockInfo retrieveLockInfo(LockDiscovery lockDiscovery, SessionInfo sessionInfo,
                                      NodeId nodeId, NodeId parentId) throws RepositoryException {
        List<ActiveLock> activeLocks = lockDiscovery.getValue();
        ActiveLock activeLock = null;
        for (ActiveLock l : activeLocks) {
            Scope sc = l.getScope();
            if (l.getType() == Type.WRITE && (Scope.EXCLUSIVE.equals(sc) || sc == ItemResourceConstants.EXCLUSIVE_SESSION)) {
                if (activeLock != null) {
                    throw new RepositoryException("Node " + saveGetIdString(nodeId, sessionInfo) + " contains multiple exclusive write locks.");
                } else {
                    activeLock = l;
View Full Code Here

Examples of org.apache.myfaces.el.unified.resolver.FacesCompositeELResolver.Scope

            throw new NullPointerException("name must not be null");
        }

        try
        {
            final Scope scope = getScope(context);
            final ELContext elcontext = context.getELContext();
            final Application application = context.getApplication();
            if (Scope.Faces.equals(scope))
            {
                return application.getELResolver().getValue(elcontext, null, name);
View Full Code Here

Examples of org.apache.ode.bpel.compiler.bom.Scope

            oforEach.completionCondition.branchCount = _context.compileExpr(forEach.getCompletionCondition());
        }

        // ForEach 'adds' a counter variable in inner scope
        if (__log.isDebugEnabled()) __log.debug("Adding the forEach counter variable to inner scope.");
        Scope s = forEach.getChild().getScope();
        // Checking if a variable using the same name as our counter is already defined.
        // The spec requires a static analysis error to be thrown in that case.
        if (s.getVariableDecl(forEach.getCounterName()) != null)
            throw new CompilationException(__cmsgs.errForEachAndScopeVariableRedundant(forEach.getCounterName()).setSource(src));

        OXsdTypeVarType counterVarType = new OXsdTypeVarType(_context.getOProcess());
        counterVarType.xsdType = new QName(XMLConstants.W3C_XML_SCHEMA_NS_URI, "unsignedInt");
        OScope.Variable countervar = new OScope.Variable(_context.getOProcess(),counterVarType);
View Full Code Here

Examples of org.apache.pivot.wtk.ScrollBar.Scope

        return boxPane;
    }

    private Component addScopeControl(final Dictionary<String, Object> dictionary,
        final String key, Form.Section section) {
        Scope scope = (Scope)dictionary.get(key);

        BoxPane boxPane = new BoxPane(Orientation.VERTICAL);
        section.add(boxPane);
        Form.setLabel(boxPane, key);

        FlowPane flowPane = new FlowPane();
        flowPane.getStyles().put("alignToBaseline", true);
        flowPane.getStyles().put("horizontalSpacing", 5);
        boxPane.add(flowPane);

        TextInput textInput = new TextInput();
        textInput.setTextSize(10);
        textInput.setMaximumLength(10);
        textInput.setValidator(new IntValidator());
        textInput.setText(scope == null ? "" : String.valueOf(scope.start));
        flowPane.add(textInput);

        textInput.getComponentStateListeners().add(new ComponentStateListener.Adapter() {
            @Override
            public void focusedChanged(Component component, Component obverseComponent) {
                if (!component.isFocused()) {
                    TextInput textInput = (TextInput)component;
                    Scope scope = (Scope)dictionary.get(key);

                    try {
                        int start = Integer.parseInt(textInput.getText());
                        dictionary.put(key, new Scope(start, scope == null ? start : scope.end,
                            scope == null ? start : scope.extent));
                    } catch (Exception exception) {
                        displayErrorMessage(exception, component.getWindow());
                        textInput.setText(scope == null ? "" : String.valueOf(scope.start));
                    }
                }
            }
        });

        Label label = new Label("start");
        label.getStyles().put("font", "{italic:true}");
        flowPane.add(label);

        flowPane = new FlowPane();
        flowPane.getStyles().put("alignToBaseline", true);
        flowPane.getStyles().put("horizontalSpacing", 5);
        boxPane.add(flowPane);

        textInput = new TextInput();
        textInput.setTextSize(10);
        textInput.setMaximumLength(10);
        textInput.setValidator(new IntValidator());
        textInput.setText(scope == null ? "" : String.valueOf(scope.end));
        flowPane.add(textInput);

        textInput.getComponentStateListeners().add(new ComponentStateListener.Adapter() {
            @Override
            public void focusedChanged(Component component, Component obverseComponent) {
                if (!component.isFocused()) {
                    TextInput textInput = (TextInput)component;
                    Scope scope = (Scope)dictionary.get(key);

                    try {
                        int end = Integer.parseInt(textInput.getText());
                        dictionary.put(key, new Scope(scope == null ? end : scope.start, end,
                            scope == null ? end : scope.extent));
                    } catch (Exception exception) {
                        displayErrorMessage(exception, component.getWindow());
                        textInput.setText(scope == null ? "" : String.valueOf(scope.end));
                    }
                }
            }
        });

        label = new Label("end");
        label.getStyles().put("font", "{italic:true}");
        flowPane.add(label);

        flowPane = new FlowPane();
        flowPane.getStyles().put("alignToBaseline", true);
        flowPane.getStyles().put("horizontalSpacing", 5);
        boxPane.add(flowPane);

        textInput = new TextInput();
        textInput.setTextSize(10);
        textInput.setMaximumLength(10);
        textInput.setValidator(new IntValidator());
        textInput.setText(scope == null ? "" : String.valueOf(scope.extent));
        flowPane.add(textInput);

        textInput.getComponentStateListeners().add(new ComponentStateListener.Adapter() {
            @Override
            public void focusedChanged(Component component, Component obverseComponent) {
                if (!component.isFocused()) {
                    TextInput textInput = (TextInput)component;
                    Scope scope = (Scope)dictionary.get(key);

                    try {
                        int extent = Integer.parseInt(textInput.getText());
                        dictionary.put(key, new Scope(scope == null ? extent : scope.start,
                            scope == null ? extent : scope.end, extent));
                    } catch (Exception exception) {
                        displayErrorMessage(exception, component.getWindow());
                        textInput.setText(scope == null ? "" : String.valueOf(scope.extent));
                    }
View Full Code Here

Examples of org.apache.slide.common.Scope

    {
        // System.out.println (scope);
        topNode = new TokenizedScope (scope);
       
        while (stores.hasMoreElements()) {
            Scope configuredStore = (Scope)stores.nextElement();
            TokenizedScope tConfStore = new TokenizedScope (configuredStore);
            if (tConfStore.isChildOf (topNode) && tConfStore.isNotExcluded (excluded) ) {
                allQueryTreeNodes.add (configuredStore);
            }
        }
View Full Code Here

Examples of org.apache.stanbol.ontologymanager.servicesapi.scope.Scope

                }
            }
            if (!(rScope instanceof UriRef)) throw new InvalidMetaGraphStateException(
                    rScope + " is not a legal scope identifier.");
            String scopeId = ((UriRef) rScope).getUnicodeString().substring(prefix_scope.length());
            Scope scope = scopeManager.getScope(scopeId);
            switch (spaceType) {
                case CORE:
                    handles.add(scope.getCoreSpace());
                    break;
                case CUSTOM:
                    handles.add(scope.getCustomSpace());
                    break;
            }
        } else if (meta.contains(new TripleImpl(candidate, RDF.type, SESSION_URIREF))) {
            String sessionId = ((UriRef) candidate).getUnicodeString().substring(prefix_session.length());
            handles.add(sessionManager.getSession(sessionId));
View Full Code Here

Examples of org.apache.tapestry.ioc.annotations.Scope

    public void get_annotation_with_annotation_on_write_method()
    {
        PropertyAdapter pa = _access.getAdapter(AnnotatedBean.class).getPropertyAdapter(
                "annotationOnWrite");

        Scope annotation = pa.getAnnotation(Scope.class);
        assertNotNull(annotation);

        assertEquals(annotation.value(), "onwrite");
    }
View Full Code Here

Examples of org.apache.tapestry5.ioc.annotations.Scope

    @Test
    public void get_annotation_with_annotation_on_write_method()
    {
        PropertyAdapter pa = access.getAdapter(AnnotatedBean.class).getPropertyAdapter("annotationOnWrite");

        Scope annotation = pa.getAnnotation(Scope.class);
        assertNotNull(annotation);

        assertEquals(annotation.value(), "onwrite");
    }
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.