8 Replies Latest reply on Nov 12, 2010 7:10 AM by gwright10

    Incompatible override Validation and Navigation libs on flex 4

    hardeepnagi8

      Hi,

       

      I tried to use validation libs with flex 4 and I am getting following compile errors:

      [ERROR] /Users/hardeepnagi/Work/maven_repo/com/adobe/cairngorm/validation/1.9/validation-1.9.swc( en_US$core_properties):[-1,-1] Incompatible override.

      [ERROR] /Users/hardeepnagi/Work/maven_repo/com/adobe/cairngorm/validation/1.9/validation-1.9.swc( en_US$skins_properties):[-1,-1] Incompatible override.

      [ERROR] /Users/hardeepnagi/Work/maven_repo/com/adobe/cairngorm/validation/1.9/validation-1.9.swc( en_US$styles_properties):[-1,-1] Incompatible override.

      [ERROR] /Users/hardeepnagi/Work/maven_repo/com/adobe/cairngorm/validation/1.9/validation-1.9.swc( en_US$effects_properties):[-1,-1] Incompatible override.

      [ERROR] /Users/hardeepnagi/Work/maven_repo/com/adobe/flex/framework/framework/4.0.0.14159/framewo rk-4.0.0.14159-en_US.rb.swc$locale/en_US/styles.properties:[16,33] Incompatible override.    override protected function getContent():Object

      [ERROR] /Users/hardeepnagi/Work/maven_repo/com/adobe/flex/framework/framework/4.0.0.14159/framewo rk-4.0.0.14159-en_US.rb.swc$locale/en_US/core.properties:[16,33] Incompatible override.    override protected function getContent():Object

      [ERROR] /Users/hardeepnagi/Work/maven_repo/com/adobe/flex/framework/framework/4.0.0.14159/framewo rk-4.0.0.14159-en_US.rb.swc$locale/en_US/effects.properties:[16,33] Incompatible override.    override protected function getContent():Object

      [ERROR] /Users/hardeepnagi/Work/maven_repo/com/adobe/flex/framework/framework/4.0.0.14159/framewo rk-4.0.0.14159-en_US.rb.swc$locale/en_US/skins.properties:[16,33] Incompatible override.    override protected function getContent():Object

       

      Following in env info

       

      SDK : 4.0.0.14159

      Validation: 1.9

      Flex Mojos: 3.7.1

      Parsley:2.2.2

       

      Any ideas?

       

      thanks

        • 2. Re: Incompatible override Validation and Navigation libs on flex 4
          ledroff Adobe Employee

          we currently use condtional compilation to compile against the latest flex3 and flex4 sdk

          cf. http://opensource.adobe.com/svn/opensource/cairngorm3/trunk/build-parent/pom.xml

          the current flex4 sdk in our dependencies is 4.1.0.16076

           

          Cheers,

          François

          • 3. Re: Incompatible override Validation and Navigation libs on flex 4
            hardeepnagi8 Level 1

            Thanks, I had seen that and also tried to compile against that SDK as well but still the same error. I would try again however and post the results

            • 4. Re: Incompatible override Validation and Navigation libs on flex 4
              hardeepnagi8 Level 1

              Hi,

               

              When I try to compile with 4.1.0.16076 I get following errors:

               

              [ERROR] D:\Projects\Highbrow\smartRental\flex-app\src\main\flex\main.mxml:[-1,-1] Interface method get layoutDirection in namesp
              ace mx.core:ILayoutDirectionElement not implemented by class main.
              [ERROR] D:\Projects\Highbrow\smartRental\flex-app\src\main\flex\main.mxml:[-1,-1] Interface method set layoutDirection in namesp
              ace mx.core:ILayoutDirectionElement not implemented by class main.
              [ERROR] D:\Projects\Highbrow\smartRental\flex-app\src\main\flex\main.mxml:[-1,-1] Interface method invalidateLayoutDirection in
              namespace mx.core:ILayoutDirectionElement not implemented by class main.

               

              Please sugggest!

              • 5. Re: Incompatible override Validation and Navigation libs on flex 4
                ledroff Adobe Employee

                Hard for anybody to say without having the source of  D:\Projects\Highbrow\smartRental\flex-app\src\main\flex\main.mxml and the associated pom file.

                • 6. Re: Incompatible override Validation and Navigation libs on flex 4
                  hardeepnagi8 Level 1

                  Yeah you are right! Dumb me! Here are the source files:

                   

                  POM

                   

                  <?xml version="1.0" encoding="UTF-8"?>
                  <project xmlns="http://maven.apache.org/POM/4.0.0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
                      xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/maven-v4_0_0.xsd">

                   

                      <modelVersion>4.0.0</modelVersion>
                      <parent>
                          <groupId>com.highbrow.products</groupId>
                          <artifactId>smartRental</artifactId>
                          <version>1.0-SNAPSHOT</version>
                      </parent>
                      <artifactId>flex-app</artifactId>
                      <packaging>swf</packaging>
                      <name>${project.parent.artifactId} Flex
                          Application Module</name>

                   

                      <dependencies>

                   

                          <dependency>
                              <groupId>${project.groupId}</groupId>
                              <artifactId>java-spi</artifactId>
                              <version>${project.version}</version>
                              <type>jar</type>
                              <scope>provided</scope>
                          </dependency>

                   

                          <dependency>
                              <groupId>org.spicefactory</groupId>
                              <artifactId>parsley-flex4</artifactId>
                              <version>${parsley.version}</version>
                              <type>swc</type>
                              <scope>internal</scope>
                          </dependency>

                   

                          <dependency>
                              <groupId>org.spicefactory</groupId>
                              <artifactId>spicelib-flex</artifactId>
                              <version>${parsley.version}</version>
                              <type>swc</type>
                              <scope>internal</scope>
                          </dependency>

                   

                          <dependency>
                              <groupId>org.spicefactory</groupId>
                              <artifactId>cinnamon</artifactId>
                              <version>${cinnamon-core_swc.version}
                              </version>
                              <type>swc</type>
                              <scope>compile</scope>
                          </dependency>

                   

                          <dependency>
                              <groupId>org.spicefactory</groupId>
                              <artifactId>pimento</artifactId>
                              <version>${pimento-core_swc.version}
                              </version>
                              <type>swc</type>
                              <scope>compile</scope>
                          </dependency>

                   

                          <dependency>
                              <groupId>cssPlus</groupId>
                              <artifactId>cssPlus</artifactId>
                              <version>${cssPlus.version}</version>
                              <type>swc</type>
                              <scope>internal</scope>
                          </dependency>

                   

                          <dependency>
                              <groupId>degrafa</groupId>
                              <artifactId>degrafa</artifactId>
                              <version>${degrafa.version}</version>
                              <type>swc</type>
                              <scope>internal</scope>
                          </dependency>

                   

                          <dependency>
                              <groupId>nz.co.codec.flex</groupId>
                              <artifactId>multicolumnform</artifactId>
                              <version>${multicolumnform.version}</version>
                              <type>swc</type>
                              <scope>internal</scope>
                          </dependency>
                         
                          
                          <dependency> <groupId>com.adobe.cairngorm</groupId>
                              <artifactId>validation</artifactId>
                              <version>${validation.version}</version> <type>swc</type>
                              <scope>internal</scope>
                          </dependency>
                          
                           <!-- flex sdk dependencies -->
                          <dependency>
                              <groupId>com.adobe.flex.framework</groupId>
                              <artifactId>playerglobal</artifactId>
                              <version>${flex.sdk.version}</version>
                              <classifier>${playerglobal.classifier.version}
                              </classifier>
                              <type>swc</type>
                          </dependency>

                   

                          <dependency>
                              <groupId>com.adobe.flex.framework</groupId>
                              <artifactId>flex-framework</artifactId>
                              <version>${flex.sdk.version}</version>
                              <type>pom</type>
                              <exclusions>
                                  <!--
                                      make sure to exclude the default 'playerglobal' transitive
                                      dependency
                                  -->
                                  <exclusion>
                                      <groupId>com.adobe.flex.framework</groupId>
                                      <artifactId>playerglobal</artifactId>
                                  </exclusion>
                              </exclusions>
                          </dependency>
                      </dependencies>

                   

                      <build>
                          <!-- <finalName>${project.parent.artifactId}</finalName> -->
                          <sourceDirectory>src/main/flex</sourceDirectory>
                          <resources>
                              <resource>
                                  <directory>src/main/resources</directory>
                              </resource>
                              <resource>
                                  <directory>src/gen/resources</directory>
                                  <filtering>true</filtering>
                              </resource>
                          </resources>

                   

                          <plugins>
                              <plugin>
                                  <groupId>com.google.code.maven-replacer-plugin</groupId>
                                  <artifactId>maven-replacer-plugin</artifactId>
                                  <version>1.3.1</version>
                                  <executions>
                                      <execution>
                                          <phase>process-resources</phase>
                                          <goals>
                                              <goal>replace</goal>
                                          </goals>
                                      </execution>
                                  </executions>
                                  <configuration>
                                      <includes>
                                          <include>src/gen/**/*.as</include>
                                      </includes>
                                      <replacements>
                                          <replacement>
                                              <token>import mx.collections.ListCollectionView;</token>
                                              <value></value>
                                          </replacement>
                                          <replacement>
                                              <token>ListCollectionView</token>
                                              <value>Array</value>
                                          </replacement>
                                          <replacement>
                                              <token>:Role</token>
                                              <value>:Number</value>
                                          </replacement>
                                          <!--
                                              <replacement> <token>value:Role</token>
                                              <value>value:Number</value> </replacement> <replacement>
                                              <token>public function get role():Role</token> <value>public
                                              function get role():Number</value> </replacement>
                                          -->
                                      </replacements>
                                  </configuration>
                              </plugin>

                   

                              <plugin>
                                  <artifactId>maven-clean-plugin</artifactId>
                                  <configuration>
                                      <filesets>
                                          <fileset>
                                              <directory>${basedir}/src/gen</directory>
                                              <followSymlinks>false</followSymlinks>
                                          </fileset>
                                      </filesets>
                                  </configuration>
                              </plugin>

                   

                              <plugin>
                                  <groupId>org.sonatype.flexmojos</groupId>
                                  <artifactId>flexmojos-maven-plugin
                                  </artifactId>
                                  <version>${flex.mojo.version}</version>
                                  <extensions>true</extensions>
                                  <executions>
                                      <execution>
                                          <phase>generate-resources</phase>
                                          <goals>
                                              <goal>generate</goal>
                                          </goals>
                                          <configuration>
                                              <baseOutputDirectory>${basedir}/src/gen</baseOutputDirectory>
                                              <outputDirectory>${basedir}/src/gen</outputDirectory>
                                              <includeJavaClasses>
                                                  <includeClass>com.highbrow.smartrental.*</includeClass>
                                              </includeJavaClasses>
                                              <!--
                                              <excludeJavaClasses>
                                                  <excludeClass>com.highbrow.smartrental.user.model.Role</excludeClass>
                                              </excludeJavaClasses>
                                              -->
                                              <entityTemplate>
                                                  <param>${basedir}/src/templates/entityBase.gsp</param>
                                                  <param>${basedir}/src/templates/entity.gsp</param>
                                              </entityTemplate>

                   

                                          </configuration>
                                      </execution>
                                  </executions>

                   

                                  <configuration>
                                      <!--
                                          <linkReport>true</linkReport>
                                          <configurationReport>true</configurationReport>
                                      -->
                                      <targetPlayer>${targetPlayer.version}
                                      </targetPlayer>
                                      <locales>
                                          <param>en_US</param>
                                      </locales>
                                      <sourcePaths>
                                          <path>${project.build.sourceDirectory}
                                          </path>
                                          <path>${basedir}/src/gen</path>
                                      </sourcePaths>
                                      <contextRoot>
                                          ${project.parent.artifactId}
                                      </contextRoot>
                                      <showWarnings>false</showWarnings>
                                      <debug>true</debug>
                                      <optimize>true</optimize>
                                      <strict>true</strict>
                                      <useNetwork>true</useNetwork>
                                      <keepGeneratedActionscript>
                                          false
                                      </keepGeneratedActionscript>
                                      <incremental>true</incremental>
                                      <themes>
                                          <theme>${basedir}/src/main/flex/com/highbrow/smartrental/common/themes/zen.swc</theme>
                                      </themes>

                   

                                  </configuration>
                                  <dependencies>
                                      <!--
                                          <dependency> <groupId>com.adobe.flex.framework</groupId>
                                          <artifactId>license</artifactId>
                                          <version>${flex.sdk.version}</version> </dependency>
                                      -->
                                      <dependency>
                                          <groupId>com.adobe.flex</groupId>
                                          <artifactId>compiler</artifactId>
                                          <version>${flex.sdk.version}</version>
                                          <type>pom</type>
                                      </dependency>
                                  </dependencies>
                              </plugin>

                   

                              <plugin>
                                  <groupId>org.apache.maven.plugins</groupId>
                                  <artifactId>maven-dependency-plugin
                                  </artifactId>
                                  <executions>
                                      <execution>
                                          <id>copy</id>
                                          <phase>install</phase>
                                          <goals>
                                              <goal>copy</goal>
                                          </goals>
                                          <configuration>
                                              <artifactItems>
                                                  <artifactItem>
                                                      <groupId>${project.groupId}</groupId>
                                                      <artifactId>flex-app</artifactId>
                                                      <version>${project.version}</version>
                                                      <type>swf</type>
                                                      <overWrite>true</overWrite>
                                                      <outputDirectory>${tomcat.home}/webapps/smartRental
                                                      </outputDirectory>
                                                  </artifactItem>
                                              </artifactItems>
                                          </configuration>
                                      </execution>
                                  </executions>
                              </plugin>
                          </plugins>
                      </build>
                  </project>

                   

                   

                  main.mxml

                   

                   

                  <?xml version = "1.0" encoding = "utf-8"?>
                  <s:Application height = "100%"
                                 width = "100%"
                                 xmlns:fx = "http://ns.adobe.com/mxml/2009"
                                 xmlns:s = "library://ns.adobe.com/flex/spark"
                                 xmlns:mx = "library://ns.adobe.com/flex/mx"
                                 pageTitle = "Smart Rental"
                                 xmlns:views = "com.highbrow.smartrental.login.views.*"
                                 xmlns:parsley = "http://www.spicefactory.org/parsley"
                                 creationComplete = "initLogging()"
                                 xmlns:views1 = "com.highbrow.smartrental.main.views.*"
                                 xmlns:command = "org.spicefactory.parsley.rpc.cinnamon.command.*">

                   

                      <fx:Script>
                          <![CDATA[
                              import com.highbrow.smartrental.common.Constants;
                              import com.highbrow.smartrental.config.parsleyConfig;
                              import com.highbrow.smartrental.main.pms.MainPM;
                              import mx.core.Container;
                              import mx.logging.Log;
                              import mx.logging.LogEventLevel;
                              import mx.logging.targets.TraceTarget;
                              import org.spicefactory.lib.reflect.types.Void;
                              import org.spicefactory.parsley.core.messaging.ErrorPolicy;
                              import org.spicefactory.parsley.flex.FlexContextBuilder;
                             
                              private function initLogging() : void {
                                  // Create a target.
                                  var logTarget : TraceTarget = new TraceTarget();
                                  // Log only messages for the classes in the mx.rpc.* and
                                  // mx.messaging packages.
                                  logTarget.filters = ["*"];
                                  // Log all log levels.
                                  logTarget.level = LogEventLevel.DEBUG;
                                  // Add date, time, category, and log level to the output.
                                  logTarget.includeDate = true;
                                  logTarget.includeTime = true;
                                  logTarget.includeCategory = true;
                                  logTarget.includeLevel = true;
                                  // Begin logging.
                                  Log.addTarget(logTarget);
                              }
                          ]]>
                      </fx:Script>
                      <fx:Declarations>
                          <parsley:ContextBuilder config = "{parsleyConfig}">
                              <command:CinnamonCommandSupport />
                              <parsley:Settings unhandledMessageErrors = "{ErrorPolicy.RETHROW}" />
                          </parsley:ContextBuilder>
                      </fx:Declarations>
                      <views1:MainView />
                  </s:Application>

                  • 8. Re: Incompatible override Validation and Navigation libs on flex 4
                    gwright10

                    Run
                    mvn dependency:tree

                     

                    You probably have something that is still trying to use a Flex 3 swc instead of the Flex 4 version.