Package fr.imag.adele.apam.impl.ComponentImpl

Examples of fr.imag.adele.apam.impl.ComponentImpl.InvalidConfiguration


    /*
     * Verify that the implementation exists
     */
    if (implementation == null || !(implementation instanceof Implementation)) {
      throw new InvalidConfiguration("Invalid instance declaration, implementation can not be found " + declaration.getImplementation().getName());
    }

    /*
     * Parse the list of triggering conditions
     */
 
View Full Code Here


            exception = exception.getCause();
          }
         
          getLogger().log(Logger.ERROR,"error invoking lifecycle callback "+ callback.getMethod(), exception);
          if (! ignoreException)
            throw new InvalidConfiguration(exception);
        }
      }
     

    }
View Full Code Here

         * existing composites
         */
        for (ContentManager existingManager : managers) {
          Set<OwnedComponentDeclaration> conflicts = manager.getConflictingDeclarations(existingManager);
          if (!conflicts.isEmpty()) {
            throw new InvalidConfiguration("Invalid owned declaration, conflicts with "+
                      existingManager.getComposite().getName() + ":" + conflicts);
          }
        }

        /*
 
View Full Code Here

      /*
       * In case the implementation providing the state is not available
       * signal an error.
       */
      if (implementation == null  || !(implementation instanceof Implementation)) {
        throw new InvalidConfiguration("Invalid state declaration, implementation can not be found "+
                propertyReference.getDeclaringComponent().getName());
      }

      /*
       * Eagerly instantiate an instance to hold the state.
       *
       * In case the main instance can be used to hold state we avoid
       * creating additional objects.
       */
      if (composite.getMainInst() != null  && composite.getMainInst().getImpl().equals(implementation)) {
        this.stateHolder = composite.getMainInst();
      } else {
        this.stateHolder = ((Implementation) implementation).createInstance(composite, null);
      }

      /*
       * Get the property used to handle the state
       */
      PropertyDefinition propertyDefinition = implementation.getDeclaration().getPropertyDefinition(propertyReference);

      /*
       * In case the property providing the state is not defined signal an
       * error.
       */
      if (propertyDefinition == null) {
        throw new InvalidConfiguration("Invalid state declaration, property not defined "+ propertyReference.getIdentifier());
      }

      this.stateProperty = propertyDefinition.getName();

      /*
 
View Full Code Here

TOP

Related Classes of fr.imag.adele.apam.impl.ComponentImpl.InvalidConfiguration

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.