Applying an annotation processor on its own source code

Hi,
I am developing a larger application and for a certain low level implementation problem, I came up with the idea of tagging some classes with own annotations and use an annotation processor to collect these classes and store the list of them somehow. I am a complete newbie in respect to this, and as my first attempts failed, I wonder whether it is really possible to include the implementation of Processor/AbstractProcessor (with the respective annotations on its own) in the same source code as the annotations it shall process and have the compiler to find and run the processor during the compilation or whether it is mandatory to create a separate jar file with the META-INF data in order to get it work.
Thanks for any response.
Klaus

KlausM wrote:
Hi,
I am developing a larger application and for a certain low level implementation problem, I came up with the idea of tagging some classes with own annotations and use an annotation processor to collect these classes and store the list of them somehow. I am a complete newbie in respect to this, and as my first attempts failed, I wonder whether it is really possible to include the implementation of Processor/AbstractProcessor (with the respective annotations on its own) in the same source code as the annotations it shall process and have the compiler to find and run the processor during the compilation or whether it is mandatory to create a separate jar file with the META-INF data in order to get it work.
Thanks for any response.
KlausYou can specify a particular processor to run using javac's "-processor" option without creating a jar file for the processor. However, in addition to source files, annotation processors can also run on class files so it would be possible for your annotation processor to be a post-pass after the build otherwise completes.
You may also want to follow the recommendation on annotation processor build hygiene:
http://blogs.sun.com/darcy/entry/annotation_processing_build_advice_set

Similar Messages

  • Contribute adding its own source code !!!

    Here is the problem
    <div id="header">
    <table width = "100%" padding = "0" cellpadding="0">
    <tr>
    <td width = "50" style="text-align: left; "><img src="images/whitelogo.gif" /></td>
    <td width = "300" style="text-align: left; float:left;"><h3><br />Fraserburgh Harbour Commissioners</h3></td>
    </tr>
    </table>
    <p style="margin-top: 0; margin-bottom: 0;"> </p>
    <div id="menu">
    <ul style="margin-bottom: 0">
    <li><a href="index.php">Home</a></li>
    <li><a href="fishing.php">Fishing</a></li>
    <li><a href="news.php">News</a></li>
    <li><a href="shiplift.php">Ship lift</a></li>
    <li><a href="drydock.php">Drydock</a></li>
    <li><a href="cargo.php">Commercial Cargo</a></li>
    <li><a href="hands.php">Health & Safety</a></li>
    <li><a href="history.php">History</a></li>
    <li><a href="key.php">Key Personnel</a></li>
    <li><a href="contact.php">Contact Us</a></li>
    </ul>
    </div>
    <!-- end #menu -->
    </div>
    Th 7th line down
    <p style="margin-top: 0; margin-bottom: 0;"> </p>
    is being added by contribute. It is then affecting content on the rest of the  page.by moving it down. The area of the page isn't even an editable area!
    Can anyone advise ?
    Here is the page in question.
    Here is what it should look like.
    Thanks John

    Please refer to, http://blogs.adobe.com/contribute/2010/06/paragraph_spacing_options_in_a.html for the answer.

  • Java.lang.NullPointerException , with no refrence to my own source code....

    what can cause this exception ?
    it does not point to any of my own source classes ,
    i works fine in OC4J 10.1.3.1 developer preview but not in 10.1.3.00 standalone
    06/10/16 16:44:55.109 web2: Servlet error
    java.lang.NullPointerException
         at com.sun.faces.context.ExternalContextImpl.dispatch(ExternalContextImpl.java:322)
         at com.sun.faces.application.ViewHandlerImpl.renderView(ViewHandlerImpl.java:130)
         at oracle.adfinternal.view.faces.application.ViewHandlerImpl.renderView(ViewHandlerImpl.java:157)
         at com.sun.faces.lifecycle.RenderResponsePhase.execute(RenderResponsePhase.java:87)
         at com.sun.faces.lifecycle.LifecycleImpl.phase(LifecycleImpl.java:200)
         at com.sun.faces.lifecycle.LifecycleImpl.render(LifecycleImpl.java:117)
         at javax.faces.webapp.FacesServlet.service(FacesServlet.java:198)
         at com.evermind[Oracle Containers for J2EE 10g (10.1.3.0.0) ].server.http.ResourceFilterChain.doFilter(ResourceFilterChain.java:64)
         at oracle.adfinternal.view.faces.webapp.AdfFacesFilterImpl._invokeDoFilter(AdfFacesFilterImpl.java:367)
         at oracle.adfinternal.view.faces.webapp.AdfFacesFilterImpl._doFilterImpl(AdfFacesFilterImpl.java:336)
         at oracle.adfinternal.view.faces.webapp.AdfFacesFilterImpl.doFilter(AdfFacesFilterImpl.java:196)
         at oracle.adf.view.faces.webapp.AdfFacesFilter.doFilter(AdfFacesFilter.java:87)
         at com.evermind[Oracle Containers for J2EE 10g (10.1.3.0.0) ].server.http.ServletRequestDispatcher.invoke(ServletRequestDispatcher.java:629)
         at com.evermind[Oracle Containers for J2EE 10g (10.1.3.0.0) ].server.http.ServletRequestDispatcher.forwardInternal(ServletRequestDispatcher.java:376)
         at com.evermind[Oracle Containers for J2EE 10g (10.1.3.0.0) ].server.http.HttpRequestHandler.doProcessRequest(HttpRequestHandler.java:870)
         at com.evermind[Oracle Containers for J2EE 10g (10.1.3.0.0) ].server.http.HttpRequestHandler.processRequest(HttpRequestHandler.java:451)
         at com.evermind[Oracle Containers for J2EE 10g (10.1.3.0.0) ].server.http.HttpRequestHandler.serveOneRequest(HttpRequestHandler.java:218)
         at com.evermind[Oracle Containers for J2EE 10g (10.1.3.0.0) ].server.http.HttpRequestHandler.run(HttpRequestHandler.java:119)
         at com.evermind[Oracle Containers for J2EE 10g (10.1.3.0.0) ].server.http.HttpRequestHandler.run(HttpRequestHandler.java:112)
         at oracle.oc4j.network.ServerSocketReadHandler$SafeRunnable.run(ServerSocketReadHandler.java:260)
         at com.evermind[Oracle Containers for J2EE 10g (10.1.3.0.0) ].util.ReleasableResourcePooledExecutor$MyWorker.run(ReleasableResourcePooledExecutor.java:303)
         at java.lang.Thread.run(Thread.java:595)

    Thank you for reply.
    I develop this application in 10.1.3.1.0 ,
    I could finally run it on OC4J 10.1.3.1 developer preview in the server , so i have no need to work on running the application on 10.1.3.00 .
    but now i have a deep problem with sending emails from my application deployed in production server , i found no solution for it .
    it is really ODD in my eyes.
    if you are intrested to look at the problem ,
    here is its post in OC4J forum , in case that you have experiences , please take a look and advice me for it.
    odd behaivior of javaMail in OC4J
    Thanks

  • New iPad mini has set up its own pass code

    I cannot get into my new iPad it has set itself a pass code any hint please?

    Don't know passcode
    http://support.apple.com/kb/HT1212

  • Is there a way to decorelate annotations from the source code?

    sorry : the title of the question may sound bizarre but , not being a native speaker, I do not know how to precisely state my problem.
    I'll try:
    an example: suppose you want to annotate your code with annotation such as @MightBeNull (a fictitious annotation) to mark a field as being potentially null.
    this annotation is going to be used by annotation processor X and is specified by (fictitious) library org.something.staticcheck ...
    Now if a new (and better) tool appears for the same purpose you'll have to change your code. At compile time your code is dependent on a precise library (and a set of precise tools for annotation processing).
    I my dreams I would like a way to write my own annotations and configure an adapter that redirects to the precise library that I choose at given moment.
    For sure that cannot be so easy since adaptations could not fit easily (but let's forget it for the moment).
    This seems impossible ... or it is?
    ( a better way could be to annotate not the source code itself but a separate description of its features that could be annotated independently)

    Sorry bruce I am a bit slow: I don't understand your suggestion.
    if I have a code like that:
    import org.staticcheck.annotations.MightBeNull ;
    public class Thing {
           @MighBeNull private Something relation;
    }my code is dependent on library "org.staticcheck.annotations".
    then afterwards if I change for another tool that uses annotation
        com.newprovider.annotations.CouldBeNullI am obliged to modify my source code!
    I daresay I am tempted by hacks such as :
    import com.mybusiness.annotations.MetaAnnotation ;
    public class Thing {
           @MetaAnnotation("null_possible") private Something relation;
    }and then perform some precompile wizardry (thru a preprocessor ;-( or tricky annotation processor
    that transforms the source code). But it could turn out ugly/clumsy ....
    that means that there will be a resource for describing a "translation" from the MetaAnnotation to the
    real thing needed at a precise moment.
    So my question is: has someone found a way to do that elegantly? (btw I can think of many more reasons for this decorrelation between
    the source code and its annotations).

  • Stored procedure serves up its own code

    I have a stored procedure in Oracle with no in, out or inout
    parameters and it works but . . ..
    it also serves up its own sql code as content!?!
    How can I prevent this?
    Thanks

    quote:
    it also serves up its own sql code as content
    What do you mean by that, exactly? Do you have
    an example of what it is doing or some code from the SP?
    Phil

  • Converting class files into java source codes

    Dear Friends,
    It is true that conversion of class files to its java source codes is possible through some software. I want to know, is there any way to protect my java source codes from viewing or copying illegally by other persons ?
    If I create JAR file from java files, can it be also convertible back to source codes ?
    Avi

    You can use code obfuscators in order to protect your code. And yes a jar file can also be decompiled.
    http://www.retrologic.com/
    http://www.2lkit.com/products/2LKitObf/
    http://www.codingart.com/codeshield.html
    http://www.drjava.de/obfuscator/

  • Warning: Supported source version 'RELEASE_6' from annotation processor 'org.eclipse.persistence.internal.jpa.modelgen.CanonicalModelProcessor' less than -source '1.7'

    warning: Supported source version 'RELEASE_6' from annotation processor 'org.eclipse.persistence.internal.jpa.modelgen.CanonicalModelProcessor' less than -source '1.7'
    Note: Creating static metadata factory ...
    An annotation processor threw an uncaught exception.
    Consult the following stack trace for details.
    java.lang.ClassFormatError: Absent Code attribute in method that is not native or abstract in class file javax/persistence/PersistenceException
        at java.lang.ClassLoader.defineClass1(Native Method)
        at java.lang.ClassLoader.defineClass(ClassLoader.java:760)
        at java.security.SecureClassLoader.defineClass(SecureClassLoader.java:142)
        at java.net.URLClassLoader.defineClass(URLClassLoader.java:455)
        at java.net.URLClassLoader.access$100(URLClassLoader.java:73)
        at java.net.URLClassLoader$1.run(URLClassLoader.java:367)
        at java.net.URLClassLoader$1.run(URLClassLoader.java:361)
        at java.security.AccessController.doPrivileged(Native Method)
        at java.net.URLClassLoader.findClass(URLClassLoader.java:360)
        at java.lang.ClassLoader.loadClass(ClassLoader.java:424)
        at java.lang.ClassLoader.loadClass(ClassLoader.java:357)
        at java.lang.Class.getDeclaredFields0(Native Method)
        at java.lang.Class.privateGetDeclaredFields(Class.java:2570)
        at java.lang.Class.getDeclaredField(Class.java:2055)
        at org.eclipse.persistence.internal.security.PrivilegedAccessHelper.findDeclaredField(PrivilegedAccessHelper.java:67)
        at org.eclipse.persistence.internal.security.PrivilegedAccessHelper.getField(PrivilegedAccessHelper.java:223)
        at org.eclipse.persistence.internal.helper.Helper.getField(Helper.java:980)
        at org.eclipse.persistence.internal.descriptors.InstanceVariableAttributeAccessor.initializeAttributes(InstanceVariableAttributeAccessor.java:100)
        at org.eclipse.persistence.mappings.DatabaseMapping.preInitialize(DatabaseMapping.java:1455)
        at org.eclipse.persistence.mappings.foundation.AbstractDirectMapping.preInitialize(AbstractDirectMapping.java:913)
        at org.eclipse.persistence.oxm.mappings.XMLDirectMapping.preInitialize(XMLDirectMapping.java:439)
        at org.eclipse.persistence.oxm.XMLDescriptor.preInitialize(XMLDescriptor.java:559)
        at org.eclipse.persistence.internal.sessions.DatabaseSessionImpl.initializeDescriptors(DatabaseSessionImpl.java:649)
        at org.eclipse.persistence.internal.sessions.DatabaseSessionImpl.initializeDescriptors(DatabaseSessionImpl.java:632)
        at org.eclipse.persistence.internal.sessions.DatabaseSessionImpl.initializeDescriptors(DatabaseSessionImpl.java:568)
        at org.eclipse.persistence.internal.sessions.DatabaseSessionImpl.postConnectDatasource(DatabaseSessionImpl.java:799)
        at org.eclipse.persistence.internal.sessions.DatabaseSessionImpl.login(DatabaseSessionImpl.java:756)
        at org.eclipse.persistence.oxm.XMLContext$XMLContextState.setupSession(XMLContext.java:738)
        at org.eclipse.persistence.oxm.XMLContext$XMLContextState.setupSession(XMLContext.java:1)
        at org.eclipse.persistence.internal.oxm.Context$ContextState.<init>(Context.java:86)
        at org.eclipse.persistence.oxm.XMLContext$XMLContextState.<init>(XMLContext.java:702)
        at org.eclipse.persistence.oxm.XMLContext.<init>(XMLContext.java:192)
        at org.eclipse.persistence.oxm.XMLContext.<init>(XMLContext.java:164)
        at org.eclipse.persistence.oxm.XMLContext.<init>(XMLContext.java:154)
        at org.eclipse.persistence.internal.jpa.modelgen.objects.PersistenceXMLMappings.createXMLContext(PersistenceXMLMappings.java:139)
        at org.eclipse.persistence.internal.jpa.modelgen.objects.PersistenceXMLMappings.createXML2_1Context(PersistenceXMLMappings.java:123)
        at org.eclipse.persistence.internal.jpa.modelgen.objects.PersistenceUnitReader.initPersistenceUnits(PersistenceUnitReader.java:178)
        at org.eclipse.persistence.internal.jpa.modelgen.objects.PersistenceUnitReader.<init>(PersistenceUnitReader.java:72)
        at org.eclipse.persistence.internal.jpa.modelgen.CanonicalModelProcessor.process(CanonicalModelProcessor.java:376)
        at com.sun.tools.javac.processing.JavacProcessingEnvironment.callProcessor(JavacProcessingEnvironment.java:794)
        at com.sun.tools.javac.processing.JavacProcessingEnvironment.discoverAndRunProcs(JavacProcessingEnvironment.java:705)
        at com.sun.tools.javac.processing.JavacProcessingEnvironment.access$1800(JavacProcessingEnvironment.java:91)
        at com.sun.tools.javac.processing.JavacProcessingEnvironment$Round.run(JavacProcessingEnvironment.java:1035)
        at com.sun.tools.javac.processing.JavacProcessingEnvironment.doProcessing(JavacProcessingEnvironment.java:1176)
        at com.sun.tools.javac.main.JavaCompiler.processAnnotations(JavaCompiler.java:1173)
        at com.sun.tools.javac.main.JavaCompiler.compile(JavaCompiler.java:859)
        at com.sun.tools.javac.main.Main.compile(Main.java:523)
        at com.sun.tools.javac.main.Main.compile(Main.java:381)..................
    I'm an undergraduate student in software engineering. I worked with EE and tried to built a EJB Application. It worked. But when i connected it to database using persistence it getting error as mentioned.
    When i change my source Binary Format to jdk6 it runs without errors. What can i do for this without downgrading jdk version?

    I resolved my problem. The issue was the version of EclipseLink that I had specified in my pom.xml. Version 2.0.1 has an issue with the meta-model generation and, in fact, I wanted to be using version 2.1.1. Once I changed to 2.1.1 everything compiled correctly.
    Just make certain that you include the correct EclipseLink repository.
    <repository>
    <id>EclipseLink Repo</id>
    <name>EclipseLink Repository for the JPA implementation</name>
    <url>http://www.eclipse.org/downloads/download.php?r=1&amp;nf=1&amp;file=/rt/eclipselink/maven.repo</url>
    </repository>

  • My macbook pro is moving on its own. Not sure if its being remotely controlled or if its a bug but its annoying!!

    I have a 15inch Macbook Pro that has recently been acting wacky. It feels like someone else is controlling my computer but all my sharing featured are turned off and i have my firewall on so i doubt its being remote controlled. Using my cursor is a constant battle. Sometimes its fine other times it won't cooperate. At random times the cursor will move and highlight a word and define it. YES Define the highlighted word. While on safari it'll  randomly zoom in on the webpage im on,  and contiue to highlight and  try to switch pages. It'll switch from desktop to  dashboard on its own as well as  make my launch pad disappear and reaapear. without me touching it at all. SOMEONE HELP !

    There are several possible causes for this issue. Please take each of the following steps that you haven't already tried until it's resolved. Some may not apply in your case.
    1. Follow the instructions in this support article, and also this one, if applicable. A damaged or defective AC adapter could be the cause, even if it's the right kind.
    2. Open the Bluetooth preference pane in System Preferences and delete all pointing devices other than the trackpad, if applicable. Disconnect any USB pointing devices. By a "pointing device," I mean a peripheral that moves the cursor, such as a trackpad, mouse, trackball, or graphics tablet. A plain keyboard is not a pointing device.
    3. Start up in safe mode and test, preferably without launching any third-party applications. If you don't have the problem in safe mode, but it comes back when you restart as usual, stop here and post your results. Do the same if you can't start in safe mode. If there was no difference in safe mode, go on to the next step.
    4. Reset the System Management Controller.
    5. If you're using a Bluetooth trackpad, investigate potential sources of interference, including USB 3 devices.
    6. A swollen battery in a portable computer can impinge on the trackpad from below and cause erratic behavior. If you have trouble clicking the trackpad, this is likely the reason. The battery must be replaced without delay.
    7. Press down all four corners of the trackpad at once and release. If there's any effect, it's likely to be temporary, and the unit needs to be serviced or replaced.
    8. There's a report that a (possibly defective) Thunderbolt Ethernet adapter can cause the built-in trackpad of a MacBook to  behave erratically. If you're using such an adapter, disconnect it and test.
    9. There's also a report of erratic cursor movements caused by an external display that was connected but not turned on.
    10. If none of the above applies, or if you have another reason to think that your computer is being remotely controlled, remove it from the network by turning off Wi-Fi (or your Wi-Fi access point), disconnecting from a Bluetooth network link, and unplugging the Ethernet cable or USB modem, whichever is applicable. If the cursor movements stop at once, you should suspect an intrusion.
    11. Make a "Genius" appointment at an Apple Store to have the machine and/or external trackpad tested.

  • Mouse moves on its own

    hey,
    does anyone have the same problem?
    my mouse on the screen moves on its own and presses random buttons:( so annoying
    I haven't had this computer even a year and its giving me a problem.
    I use logitec wireless mouse. is there anything i need to set up in the preferences?
    thank you

    There are several possible causes for this issue. Take each of the following steps until it's resolved.
    1. Follow the instructions in this support article.
    2. Open the Bluetooth preference pane in System Preferences and check for unknown or forgotten input devices. Disconnect any USB input devices that you aren't using.
    3. Boot in safe mode and test, preferably without launching any third-party applications. If you don't have the problem in safe mode, but it comes back when you reboot as usual, stop here and post your results. If you can't boot in safe mode, do the same. If you booted in safe mode and there was no change, go on to the next step.
    4. Reset the System Management Controller.
    5. If you're using a Bluetooth trackpad, investigate potential sources of interference, including USB 3 devices.
    6. A swollen battery in a MacBook Pro or Air can impinge on the trackpad from below and cause erratic behavior. If you have trouble clicking the trackpad, this is likely the reason. The battery must be replaced.
    7. There's a report that a (possibly defective) Thunderbolt Ethernet adapter can cause the built in trackpad of a MacBook to  behave erratically. If you're using such an adapter, disconnect it and test.
    8. There's also a report of erratic cursor movements caused by an external display that was connected but not turned on.
    9. If none of the above applies, or if you have another reason to think your computer is being remotely controlled, remove it from the network by turning off Wi-Fi (or your Wi-Fi access point), disconnecting from a Bluetooth network link, and unplugging the Ethernet cable or USB modem, whichever is applicable. If the cursor movements stop at once, you should suspect an intrusion.
    10. Make a "Genius" appointment at an Apple Store to have the machine tested.

  • HOW DO I MAKE A BLENDING OPTION ITS OWN LAYER?

    I have an inner shadow on a picture. What I would like to do is take that inner shadow and make it its own layer so i can use the same shadow to put over different pictures on a website.
    Thank you for your time.
    Chris

    If editability is a concern, then might as well leave it alone. There is no reason why the style can not be copied to another document or layer. Alt-dragging works wonders in these cases.
    Something else the OP can try is take the original layer, convert to a smart object then appy a layer style to it. You can then replace the image inside of the smart object with any other image (preferably the same width and height) then save to web.
    Because you can save a layer style, it is just as simple to create an action that will apply that style to the current layer, and run that action as part of a batch or image processor script, which would then apply that layerstyle to an entire folder of images.
    Do a test on the action as I did not test it other than to verify that an action can apply a style.
    There is always more than one way to skin a cat.

  • Move MySites to its own Web Application

    I've looked and looked online but i still haven't been able to find any good step by step on whats the best way to do this. When I setup the MySites, i set it up under the Web Application that runs the rest of the sites. Now i want to move those MySites
    over to its own Web Application. What's the best way to get this done. Thanks in advance.
    Ben

    Google on how to load sharepoint powershell snapin
    The Sharepoint Powershell snapin has been loaded but "export-spsite" does not exist as a command on a out of the box SharePoint. 
    "Export-SPsite" and "Import-SPsite" are 3rd party open source script. They are not official powershell cmdlet. But you can easily get them from Internet and applied to your environment.
    If you like to stick with official one, you can use Export-SPWeb instead. It should help you complete the backup part.
    There is Import-SPWeb cmdlet to restore the site as well. However it will not work if the site collection is not created beforehead.
    So I guess the approach would be:
    1. Backup all the mysite using Export-SPweb.
    2. Build a new "My Site Host" web application and change your mysite settings in User Profile Service Application.
    3. Re-create all mysite in new web application (here the site collections are created)
    4. Restore to new created site collections with the old backup.
    P.S. I have not performed MySite move before. Please consider whether it is a valid approach!

  • Parallel effect reversing on its own. FLEX BUG.

    Hi,
    The problem is that the parallel effect (that includes resize
    and move) plays well with my custom component, however when it
    reaches the EFFECT_END, it plays in reverse to its original
    position, on its own. I cannot figure it out why. This reverse
    effect is done in half of the duration set.
    This is the code:
    private function setLayoutAndPosition( pod:*, rect:Rectangle
    ):void
    // Transition the location
    var move:Move = new Move( pod );
    move.xFrom = pod.x;
    move.xTo = rect.x;
    move.yFrom = pod.y;
    move.yTo = rect.y;
    move.duration = 2000;
    // Transition the size
    var resize:Resize = new Resize( pod );
    resize.widthFrom = pod.width;
    resize.widthTo = rect.width;
    resize.heightFrom = pod.height;
    resize.heightTo = rect.height;
    resize.duration = 2000;
    var parallel:Parallel = new Parallel();
    parallel.addChild(move);
    parallel.addChild(resize);
    parallel.play();
    I am utilizing an effect taken from the source code of the
    Flex Developer Center called Community Widgets (
    bottom of the page)
    which is working correctly. Its pretty cool eh!.
    BTW: Took me some time to find out why I couldn't run the
    source code. You have to rename ListEvent to any other name.
    If anybody has any idea please le me know,
    Many thanks!
    Jose.

    "jose3" <[email protected]> wrote in message
    news:[email protected]...
    > Hi myIP,
    > After days of trying different things I figured out what
    was the problem,
    > I am
    > not sure if it is a bug or if it is a natural behabiour
    of Flex.
    >
    >
    > The thing is that if you position a component (Canvas
    FE) with
    > constraintColumns and constraintRows and then you apply
    an effect that
    > affects
    > its position or size, after the effect reaches the
    EFFECT_END the
    > components
    > goes back to the original position-size on its own.
    >
    > Here is an example:
    >
    > <?xml version="1.0" encoding="utf-8"?>
    > <mx:Application xmlns:mx="
    http://www.adobe.com/2006/mxml"
    > layout="absolute"
    > applicationComplete="init()">
    >
    > <mx:Script>
    > <![CDATA[
    >
    > import flash.geom.Rectangle;
    > import flash.utils.Dictionary;
    >
    > import mx.effects.Move;
    > import mx.effects.Parallel;
    > import mx.effects.Resize;
    > import mx.events.EffectEvent;
    >
    > private var minimizedLayout:Dictionary = new
    Dictionary();;
    >
    > private function init():void {
    > minimizedLayout[ can ] = new Rectangle( 5, 200, 300, 50
    > }
    >
    > private function onClick(e:Event):void {
    > setLayoutAndPosition( can, minimizedLayout[can] );
    > }
    >
    > private function setLayoutAndPosition( pod:*,
    rect:Rectangle ):void
    > {
    >
    > // Transition the location
    > var move:Move = new Move( pod );
    > move.xFrom = pod.x;
    > move.xTo = rect.x;
    > move.yFrom = pod.y;
    > move.yTo = rect.y;
    > move.duration = 1000;
    >
    > // Transition the size
    > var resize:Resize = new Resize( pod );
    > resize.widthFrom = pod.width;
    > resize.widthTo = rect.width;
    > resize.heightFrom = pod.height;
    > resize.heightTo = rect.height;
    > resize.duration = 1000;
    >
    > var parallel:Parallel = new Parallel();
    > parallel.addChild(move);
    > parallel.addChild(resize);
    > parallel.play();
    >
    > }
    >
    > ]]>
    > </mx:Script>
    >
    > <mx:constraintColumns>
    > <mx:ConstraintColumn id="col1" width="5%"/>
    > <mx:ConstraintColumn id="col2" width="20%"/>
    > </mx:constraintColumns>
    >
    > <mx:constraintRows>
    > <mx:ConstraintRow id="row1" height="5%"/>
    > <mx:ConstraintRow id="row2" height="20%"/>
    > </mx:constraintRows>
    >
    >
    > <mx:Button label="Move Canvas" x="333"
    click="onClick(event)" y="29"
    > height="107"/>
    >
    > <mx:Canvas id="can" backgroundColor="#D91414"
    > left="col1:10" right="col2:0"
    > top="row1:10" bottom="row2:0" />
    >
    > </mx:Application>
    >
    >
    > If this is a normal behabiour (if anybody knows about
    it) I can just try
    > to
    > end the effect after EFFECT_END, else I listen to any
    suggestion.
    >
    > How should I proceed it it is a bug?
    Listen for the effect end, and then explicitly set the width
    and height of
    the affected component to the new size.

  • New softwear and now ipod works on its own

    I have a ipod, 3rd generation, which i just loaded with most current softwear and now it runs on its own.  I mean I won't be touching it and it is moving and playing music, jumping from song to song....also can no longer use WiFi - what happened...its never done this before on an upgrade....

    Grey text when you look at the content and a lock symbol at the bottom of the screen just indicates that the iPod is set to update automatically (sync). An iPod that is set to update automatically will also disconnect automatically once it is finished syncronising with iTunes.
    If you want to access the iPod directly, delete songs from the iPod, drag songs from iTunes etc. you need to change the update setting to "manually manage songs and videos. If you want to manage it manually then connect your iPod and click on the iPod icon in the iTunes source list to bring up the preference tabs in the main pane. In the Summary tab check the box "manually manage music and videos" and click Apply:
    Managing content manually on iPod
    iPod 101: Fill 'er Up
    Something to remember about using an iPod in manual mode is that the "Do Not Disconnect" message will remain on the display until you physically eject the device. In that case use the Safely Remove Hardware icon in the Windows system tray on the desktop and check this link for alternative methods:: Safely Disconnect IPod

  • I'm having a real problem with my cursor which seems to have developed a mind of its own, zigzagging allover, highlighting things without my command, and basically making my MacBook unuseable (it's taken me half an hour just to compose this!).

    I'm having a real problem with my cursor which seems to have developed a mind of its own, zigzagging allover, highlighting things without my command, and basically making my MacBook unusable (it's taken me half an hour just to compose this!).

    There are several possible causes for this issue. Please take each of the following steps that you haven't already tried until it's resolved. Some may not apply in your case.
    1. Follow the instructions in this support article, and also this one, if applicable. A damaged or defective AC adapter could be the cause, even if it's the right kind.
    2. Press down all four corners of the trackpad at once and release. If there's any effect, it's likely to be temporary, and in that case the unit must be serviced or replaced.
    3. Open the Bluetooth preference pane in System Preferences and delete all pointing devices other than the trackpad, if applicable. Disconnect any USB pointing devices. By a "pointing device," I mean a peripheral that moves the cursor, such as a trackpad, mouse, trackball, or graphics tablet. A plain keyboard is not a pointing device.
    4. Start up in safe mode and test, preferably without launching any third-party applications. If you don't have the problem in safe mode, but it comes back when you restart as usual, stop here and post your results. Do the same if you can't start in safe mode. If there was no difference in safe mode, go on to the next step.
    5. Reset the System Management Controller.
    6. If you're using a Bluetooth trackpad or mouse, investigate potential sources of interference, including USB 3 devices.
    7. A swollen battery in a portable computer can impinge on the trackpad from below and cause erratic behavior. If you have trouble clicking the trackpad, this is likely the reason. The battery must be replaced without delay.
    8. There's a report that a (possibly defective) Thunderbolt Ethernet adapter can cause the built-in trackpad of a MacBook to behave erratically. If you're using such an adapter, disconnect it and test.
    9. There's also a report of erratic cursor movements caused by an external display that was connected but not turned on.
    10. If none of the above applies, or if you have another reason to think that your computer is being remotely controlled, remove it from the network by turning off Wi-Fi (or your Wi-Fi access point), disconnecting from a Bluetooth network link, and unplugging the Ethernet cable or USB modem, whichever is applicable. If the cursor movements stop at once, you should suspect an intrusion.
    11. Make a "Genius" appointment at an Apple Store to have the machine and/or external trackpad tested.

Maybe you are looking for