Package org.apache.tuscany.sca.policy

Examples of org.apache.tuscany.sca.policy.Intent


        if (policyIntent != null) {
            //resolve all required intents
            List<Intent> requiredIntents = new ArrayList<Intent>();
            for (Intent requiredIntent : policyIntent.getRequiredIntents()) {
                if (requiredIntent.isUnresolved()) {
                    Intent resolvedRequiredIntent = definedIntents.get(requiredIntent.getName());
                    if (resolvedRequiredIntent != null) {
                        requiredIntents.add(resolvedRequiredIntent);
                    } else {
                        throw new DefinitionsBuilderException("Required Intent - " + requiredIntent
                            + " not found for ProfileIntent "
View Full Code Here


        if (extensionType != null) {
            // resolve all provided intents
            List<Intent> alwaysProvided = new ArrayList<Intent>();
            for (Intent providedIntent : extensionType.getAlwaysProvidedIntents()) {
                if (providedIntent.isUnresolved()) {
                    Intent resolvedProvidedIntent = definedIntents.get(providedIntent.getName());
                    if (resolvedProvidedIntent != null) {
                        alwaysProvided.add(resolvedProvidedIntent);
                    } else {
                        throw new DefinitionsBuilderException("Always Provided Intent - " + providedIntent
                            + " not found for ExtensionType "
View Full Code Here

        if (extensionType != null) {
            // resolve all provided intents
            List<Intent> mayProvide = new ArrayList<Intent>();
            for (Intent providedIntent : extensionType.getMayProvidedIntents()) {
                if (providedIntent.isUnresolved()) {
                    Intent resolvedProvidedIntent = definedIntents.get(providedIntent.getName());
                    if (resolvedProvidedIntent != null) {
                        mayProvide.add(resolvedProvidedIntent);
                    } else {
                        throw new DefinitionsBuilderException("May Provide Intent - " + providedIntent
                            + " not found for ExtensionType "
View Full Code Here

        if (policySet != null) {
            //resolve all provided intents
            List<Intent> providedIntents = new ArrayList<Intent>();
            for (Intent providedIntent : policySet.getProvidedIntents()) {
                if (providedIntent.isUnresolved()) {
                    Intent resolvedProvidedIntent = definedIntents.get(providedIntent.getName());
                    if (resolvedProvidedIntent != null) {
                        providedIntents.add(resolvedProvidedIntent);
                    } else {
                        throw new DefinitionsBuilderException("Provided Intent - " + providedIntent
                            + " not found for PolicySet "
View Full Code Here

    private void buildIntentsInMappedPolicies(PolicySet policySet, Map<QName, Intent> definedIntents)
        throws DefinitionsBuilderException {
        for (IntentMap intentMap : policySet.getIntentMaps()) {
            for (Qualifier qualifier : intentMap.getQualifiers()) {
                Intent mappedIntent = qualifier.getIntent();
                if (mappedIntent.isUnresolved()) {
                    Intent resolvedMappedIntent = definedIntents.get(mappedIntent.getName());

                    if (resolvedMappedIntent != null) {
                        qualifier.setIntent(resolvedMappedIntent);
                    } else {
                        throw new DefinitionsBuilderException("Mapped Intent - " + mappedIntent
View Full Code Here

        if (policyIntent != null) {
            //resolve all required intents
            List<Intent> requiredIntents = new ArrayList<Intent>();
            for (Intent requiredIntent : policyIntent.getRequiredIntents()) {
                if (requiredIntent.isUnresolved()) {
                    Intent resolvedRequiredIntent = definedIntents.get(requiredIntent.getName());
                    if (resolvedRequiredIntent != null) {
                        requiredIntents.add(resolvedRequiredIntent);
                    } else {
                        throw new DefinitionsBuilderException("Required Intent - " + requiredIntent
                            + " not found for ProfileIntent "
View Full Code Here

    private void buildQualifiedIntent(QualifiedIntent policyIntent, Map<QName, Intent> definedIntents)
        throws DefinitionsBuilderException {
        if (policyIntent != null) {
            //resolve the qualifiable intent
            Intent qualifiableIntent = policyIntent.getQualifiableIntent();
            if (qualifiableIntent.isUnresolved()) {
                Intent resolvedQualifiableIntent = definedIntents.get(qualifiableIntent.getName());

                if (resolvedQualifiableIntent != null) {
                    policyIntent.setQualifiableIntent(resolvedQualifiableIntent);
                } else {
                    throw new DefinitionsBuilderException("Qualifiable Intent - " + qualifiableIntent
View Full Code Here

        if (extensionType != null) {
            // resolve all provided intents
            List<Intent> alwaysProvided = new ArrayList<Intent>();
            for (Intent providedIntent : extensionType.getAlwaysProvidedIntents()) {
                if (providedIntent.isUnresolved()) {
                    Intent resolvedProvidedIntent = definedIntents.get(providedIntent.getName());
                    if (resolvedProvidedIntent != null) {
                        alwaysProvided.add(resolvedProvidedIntent);
                    } else {
                        throw new DefinitionsBuilderException(
                                                                 "Always Provided Intent - " + providedIntent
View Full Code Here

        if (extensionType != null) {
            // resolve all provided intents
            List<Intent> mayProvide = new ArrayList<Intent>();
            for (Intent providedIntent : extensionType.getMayProvideIntents()) {
                if (providedIntent.isUnresolved()) {
                    Intent resolvedProvidedIntent = definedIntents.get(providedIntent.getName());
                    if (resolvedProvidedIntent != null) {
                        mayProvide.add(resolvedProvidedIntent);
                    } else {
                        throw new DefinitionsBuilderException(
                                                                 "May Provide Intent - " + providedIntent
View Full Code Here

        if (policySet != null) {
            //resolve all provided intents
            List<Intent> providedIntents = new ArrayList<Intent>();
            for (Intent providedIntent : policySet.getProvidedIntents()) {
                if (providedIntent.isUnresolved()) {
                    Intent resolvedProvidedIntent = definedIntents.get(providedIntent.getName());
                    if (resolvedProvidedIntent != null) {
                        providedIntents.add(resolvedProvidedIntent);
                    } else {
                        throw new DefinitionsBuilderException("Provided Intent - " + providedIntent
                            + " not found for PolicySet "
View Full Code Here

TOP

Related Classes of org.apache.tuscany.sca.policy.Intent

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.