Flash.utils.Proxy Question

hi list,
I am trying to extend flash.utils.Proxy so that I can
intercept calls
made on an innerObject and provide cross cutting
services/advices like
writing to a log or caching... (AOP...)
The big problem is that the user of the innerObject needs to
be aware
of the ProxyClass otherwise - calls will not be intercepted.
for example:
a proxy factory class looks like this-
public class ProxyFactory
private var _target:*;
public function ProxyFactory(target:*){
_target = target;
public function GetProxy():*{
var proxy:AOPProxy = new AOPProxy(_target);
return (proxy);
and the usage:
var person:Person = factory.GetProxy();
this will produce a runtime casting exception!!
the fix is to do something like this:
var person:AOPProxy = factory.GetProxy();
or even -
var person:* = factory.GetProxy();
BUT - this is bad because the user of the factory is aware of
the
proxy AND he loose code assist... he cannot see the
properties of the
Person Class.
Does anybody know of a better way (maybe creating runtime
code
generated proxies??- code emission...)
Thanks,
Chen Bekor
Software Architect.

quote:
it looks a bit strange for a developer to have to instantiate
objects via a factory to get some AOP functionality. Doesn't this
tie you down to the specific AOP framework you are using, or am I
missing something?
I agree - it was just an example - the question is does
flash.utils.Proxy is the proper direction to provide AOP in
ActionScript3?
quote:
Have you checked out the AOP framework of as2lib (
http://www.as2lib.org/)?
yes I did - its ActionScript2 - and it use deprecated API in
ActionScript3
- I'm trying to write my own AOP implementation to
Flex...
- do you have any idea?

Similar Messages

  • Player 10 and flash.utils.proxy

    Hi Guys,
    I'm wondering if there are plans (or an issue on which I can vote) to upgrade flash.utils.Proxy? There's 2 things I'd like to see changed in order of how difficult I imagine they are ;-)
    1) Replace name:* and name:String with a real key:* that can be anything (not just Strings or QNames).
    2) Modify the VM slightly so subclasses of Proxy can decide when and if a cast opcode throws an exception.
    Number 1 seems easy to me, but having never seen the source I can't really say :)
    Number 2 I guess depends on whether or not cast instances are using dynamic dispatch, so it's probably not as feasible...
    Anybody have any thoughts on these?
    Cheers,
    -Josh
    "Therefore, send not to know For whom the bell tolls. It tolls for thee."
    http://flex.joshmcdonald.info/
    :: Josh 'G-Funk' McDonald
    :: 0437 221 380 ::
    [email protected]

    Yeah, pretty much :) Well, not #1... That's just (mainly) an API upgrade.
    On Wed, Sep 10, 2008 at 10:01 PM, James L. Ward
    <
    [email protected]> wrote:
    A new message was posted by James L. Ward in
    Developers --
      Player 10 and flash.utils.proxy
    Does this relate at all to:
    https://bugs.adobe.com/jira/browse/ASC-3136
    -James
    View/reply at
    Player 10 and flash.utils.proxy
    Replies by email are OK.
    Use the
    unsubscribe form to cancel your email subscription.
    "Therefore, send not to know For whom the bell tolls. It tolls for thee."
    http://flex.joshmcdonald.info/
    :: Josh 'G-Funk' McDonald
    :: 0437 221 380 ::
    [email protected]

  • HT1366 How to fix Flashing Folder with Question Mark on Mac

    How to fix Flashing Folder with Question Mark on Mac

    RichardEL is probably correct.  I’ll go through your questions.
    > there is no Mac OS partition, I assume it would be directly underneath the HD on the left?
    I have not seen this particular condition where the hardware disk icon appears but the system volume that is supposed to be below it does not.  The System Disk partition would be below the HD icon indented to the right.  It is usually called “Macintosh HD” unless you renamed it.
    > when I go into disk utility my HD appears on the left, but I can repair or verify it
    Odd.  It appears but you cannot manipulate it with Disk Utility.
    > The S.M.A.R.T status reads verified
    If it did not say Verified then it would indicate a problem.  Saying Verified does not rule out problems but I think it indicates it is still breathing.
    > Is the HD deceased?
    If you booted the Recovery Partition (Boot, Command-R), which it sounds like you did, then at least part of the disk is still breathing.  If it took a long time to boot then that may have been a Network Recovery boot which would indicate the disk is very sick or dead.
    >  [If I] restore from time machine [will] everything will be back as it was before?
    Yes.  That is the beauty of Time Machine.  All your data, applications, and system preferences will be as they were as of the last backup.
    > I was thinking of erasing the HD, would this be of any help or do I just need a new one?
    Given what you reported from the Disk Utility steps you took it is unclear to me if there will be a way to repair the current volume, if you can erase and install from scratch or if you need a new disk.  Before proceeding it may be useful to have an expert at an Apple store look at it for you.  They may be able to revive it without a clean install or new disk.
    As was the case above, it could be a good disk with a bad cable in which case a new disk is not going to help.  To test this you can purchase an inexpensive external enclosure, remove the internal disk, place it in the enclosure, plug it in and then use Boot-Option to attempt to boot from the now external disk.  Here are links to the screwdrivers and enclosure you would need.
    $5 Toolkit: http://eshop.macsales.com/item/OWC/TOOLKITMHD/
    $22 USB 3.0 enclosure: http://eshop.macsales.com/item/OWC/ES2.5BU3W/
    If you attempt a clean install, use the Partition tab to repartition the disk, selecting one partition and with “Options…” electing a GUID partition.  Then use the Erase tab, select “Security Options…” and set it to write a single pass of zeros.  This will write to every sector to map out bad blocks.  (If you have an SSD do not write a pass of zeros.)
    If you do need to replace it I recommend an new inexpensive (~$100) and super-fast hybrid SSHD drive that has an 8 GB SSD cache that makes the data fly.  Google “Seagate 1 TB hybrid SSHD”.

  • Blue screen with flashing folder and question mark on startup

    Hello.
    I need help with my Macbook Pro.  I get a blue screen with a flashing folder and a question mark at start up.  To date I have tried the following:
    Apple Hardware (Extensive) Test (Results:  "No Trouble Found")
    Safe Boot
    Reset NVRAM
    Reinstall OS X via the internet (I received no discs when I purchased it).  I select the StartUp Disk to reinstall. When reinstalling via the internet I get to a point of reinstalling Mountain Lion but it asks me to choose a drive - yet there are no drive options to choose from. Then a window comes up asking me to "Select the system you want to use to start up your computer" but no options appear.  When I choose "Restart" a note pops up saying "You can't change the startup disk to the selected disk.  Startup Disk could not gather enough information on the selected disk."
    The only option is "Restart" from the Apple menu.  When I choose that it goes back to the original "Blue screen with flashing folder and question mark on startup."
    I have no Time Machine
    I can't access the disc utility.
    Are there any ideas as to what might be the problem?

    Your hard drive has likely failed and needs replaced. That would explain why the system does not display it when you attempt to reinstall the OS via Internet Recovery.

  • Flash.utils - Details Adobe ActionScript 3 (AS3) API Reference

    This question was posted in response to the following article: http://help.adobe.com/en_US/FlashPlatform/reference/actionscript/3/flash/utils/package.htm l

    The documentation for setTimeout() is incorrect. It claims that...
    If you do not call the clearTimeout() function to cancel the setTimeout() call, the object containing the set timeout closure function will not be garbage collected.
    However at least in the current version of Flash, this is not correct. Once the closure has been executed the reference will be removed and the object may be garbage collected.
    See discussion at: http://stackoverflow.com/questions/16489536/does-flash-utils-settimeout-leak-memory-if-cle artimeout-is-not-called

  • Flashing Folder and Question Mark, no installation disc

    Yesterday, Safari froze up while I was it which I have never had happen before. So, I manually shut my Macbook off and tried to restart. When I did so, I received a gray screen with a flashing folder and question mark. From my research, I have found that usually this means that my laptop can't find the operating system and this issue can usually be resolved by inserting the installation disc. Problem is, I bought my Macbook secondhand and never got an installation disc. Does anyone know of a way around this issue? Or if buying the Snow Leopard upgrade for $30 instead of buying a whole new package for about a hundred dollars more might resolve this issue?
    Thanks so much,
    Kristin

    Yes, quite a quandary. You have some options:
    1. Call AppleCare and ask for customer support. You can order replacement discs for the model you have.
    2. Purchase an OS X retail installer suitable for your model, like Snow Leopard, that you can use to determine if you can repair the hard drive or will nee to reinstall OS X. If the latter and you are using Snow Leopard, then you just install it. The installer will determine whether to upgrade or not automatically. As long as your drive is OK Snow Leopard will not erase the drive so all your files are safe. If you use an earlier version of OS X then you want to choose the Archive and Install option. See the following:
    How to Perform an Archive and Install
    An Archive and Install will NOT erase your hard drive, but you must have sufficient free space for a second OS X installation which could be from 3-9 GBs depending upon the version of OS X and selected installation options. The free space requirement is over and above normal free space requirements which should be at least 6-10 GBs. Read all the linked references carefully before proceeding.
    1. Be sure to use Disk Utility first to repair the disk before performing the Archive and Install.
    Repairing the Hard Drive and Permissions
    Boot from your OS X Installer disc. After the installer loads select your language and click on the Continue button. When the menu bar appears select Disk Utility from the Installer menu (Utilities menu for Tiger.) After DU loads select your hard drive entry (mfgr.'s ID and drive size) from the the left side list. In the DU status area you will see an entry for the S.M.A.R.T. status of the hard drive. If it does not say "Verified" then the hard drive is failing or failed. (SMART status is not reported on external Firewire or USB drives.) If the drive is "Verified" then select your OS X volume from the list on the left (sub-entry below the drive entry,) click on the First Aid tab, then click on the Repair Disk button. If DU reports any errors that have been fixed, then re-run Repair Disk until no errors are reported. If no errors are reported, then quit DU and return to the installer.
    2. Do not proceed with an Archive and Install if DU reports errors it cannot fix. In that case use Disk Warrior and/or TechTool Pro to repair the hard drive. If neither can repair the drive, then you will have to erase the drive and reinstall from scratch.
    3. Boot from your OS X Installer disc. After the installer loads select your language and click on the Continue button. When you reach the screen to select a destination drive click once on the destination drive then click on the Option button. Select the Archive and Install option. You have an option to preserve users and network preferences. Only select this option if you are sure you have no corrupted files in your user accounts. Otherwise leave this option unchecked. Click on the OK button and continue with the OS X Installation.
    4. Upon completion of the Archive and Install you will have a Previous System Folder in the root directory. You should retain the PSF until you are sure you do not need to manually transfer any items from the PSF to your newly installed system.
    5. After moving any items you want to keep from the PSF you should delete it. You can back it up if you prefer, but you must delete it from the hard drive.
    6. You can now download a Combo Updater directly from Apple's download site to update your new system to the desired version as well as install any security or other updates. You can also do this using Software Update.

  • Flashing folder with question mark on start up + many other issues

    About 6 months ago I first encountered the flashing folder with question mark on startup. I fixed the issue myself by unplugging the mouse and keyboard and rebooting. I also did the cmd S fsck -fy before that and all was well.
    The other day I had the flashing folder again...I got it going a couple of times but it happened again. Right now I seem to be in deep trouble. Please read the following:
    1. I booted up from the leopard dvd and no hard drive was there to run a disk utility on
    2. Booted up again from the dvd and hard drive was there. Ran the disk utility and everything was fine...for about 5 minutes. Then the computer froze and I had to hard power down. Rebooted to the flashing folder.
    3. Did command s and fsck but at the end I get the message failed to issue comm reset after 3 attempts.....failing....
    4. I powered down, vacuumed out the vents, sprayed compressed air to make sure it wasn't over heating from dust buildup as I read somewhere.
    5. Booted up...worked for about 5 minutes again.
    6. Now I can't get to the hard drive from the install dvd at all...I tried 100 times. Cmd s won't work at all!! So it looks like I am out of options. Does anyone have ny radical solutions that i can try to fix this. There are some very important things on my hard drive that I would be very upset about loosing.
    Please reply

    Sorry to bear bad news, but most likely the drive is already dead or dying. I hope you backed up everything when the first symptoms appeared.
    There are data recovery services, but might be very expensive.
    EDIT: Some (a few) people have had success putting the drive (sealed very well in a plastic baggy) in the freezer overnight and then quickly putting it in an external enclosure and getting the data off it that way.
    Message was edited by: WZZZ

  • Netboot will not working, getting globe, then flashing folder with question mark.

    I just created a netboot image which went off without any problems.  I copied the two .nbi folders to my NetBootSP0 folder, and enabled them within netboot.  My OS X server which is my netboot server and dhcp server.  When I boot using N or Option N, I get the flashing globe for several seconds, the request goes through to the server and gets ACK {SELECT} however a few more seconds after, I get the flashing folder and question mark before it does a normal boot.  I have read the other posts about DHCP and Subnets.  My server and and clients are all 255.255.0.0.  Any suggestions would be very helpful as I need this to work for several buildings. 

    This might work for some:
         I had the same problem of the netboot image not mounting/opening, spinning globe then booting back to the Mac HD on the client and it was only when I remembered that we had manually experimented with jumbo frame rates and the MTU settings for our 32TB RAID in the Hardware settings for Ethernet ports on our servers. I turned the settings back to "Automatic" and 1000baseT on, then the whole NetInstall and Neboot was working perfectly again.

  • Flash utility not working!!!! Please help.

    Hi guys,
    Yesterday I tried to flash the BIOS of my 865PE-Neo2LS motherboard with the latest 2.0 version. I downloaded the 6728v20.zip file and copy its contents to a temporary directory in my FAT32 hardrive. Then I made a DOS boot diskette, booted to DOS, and cd into the temporary directory. After that I issued:
    C:\TEMP>ADSFI711.EXE A6728IMS.200
    For my deep surprise the flash utility ignores the BIOS file passed as argument and instead displays its syntax. Is this a bug or what???? Anyone experiencing the same problem??

    Well, it lists the commands always, even when I pass the bios file name as an argument. Maybe the problem is with the DOS boot diskette. I used rawrite to write an image file to a floppy disk. The image file I got it from http://www.freedos.org. Later today I'll try the flash utility that came with the bios version 1.9.

  • Flashing folder with question mark at Startup

    Here is what I know so far.
    - The computer was powered off by pushing the power button without shutting down.
    - The computer was then restarted and it was coming into the white screen with the Apple logo in the middle, but i noticed that it was skewed slightly (like someone took a 4:3 ratio screen and stretched it to a 16:9) and then it would show a circle slash icon and then the flashing folder with a question mark on it.
    - It would not come up in single user mode (Command + S) and it said that there was an error loading kernel 'mach_kernel'
    - It would not come up in safe mode (Shift)(The flashing folder came up again)
    - I reset the PRAM (Command + Option + p + r) and it seemed to fix the problem with the stretched screen but did not help the boot situation (still got flashing folder)
    - I did the start up where you can select the hard drive to boot with, it owed the HD and i selected it, but then i got the flashing folder with question mark.
    - It would not come up in Verbose Mode (Command V) Error loading Kernel again.
    - I bought a FireWire cable and hooked it to another MacBook Pro, and booted the faulty Mac into Target Disk Mode, the FireWire logo came up on the screen and bounced around like all forums said that it would, but the drive would not show up on my host. I checked the System Profiler on the host and it did acknowledge the Target Disk Mode was there, but the drive of the target would not show up on the host. I restarted the host, nothing. I checked all of the connections, nothing. I replugged all of the connections, nothing. I even reversed the FireWire cable, nothing.
    - I have DiskWarrior 4 if i can get the drive to show up in TDM, but nothing so far.
    Does anyone have any suggestions?

    Thanks for your help guys. I managed to get the computer started by holding down C at the Start Up with the Install Disc 1 in the computer. The disc was really kindof unnecessary, as the newest version of Mac OS X (10.4.10) became available via the hard drive.
    I then found out that the battery was not installed, so I reset the management system by removing the A/C power, the battery and pushing the power button for 5 seconds, and then reconnecting everything. It did not help, the battery is bad i guess, so I am going to call AppleCare and get a new battery.
    Thanks for your help.

  • Missing flash.utils.* in code complete upgrade from 3.3 to 3.5 framework

    Hi All,
    I upgraded my 3.3 framework to 3.5 today, and for some strange and inexplicable reason, I've lost all code completion in Flex Builder 3 for flash.utils.* classes. I am thus missing Dictionary Timer and a few other important classes.
    I'm hoping that someone out there might have come across this before, or be able to give me a bit of a clue as to how to fix this issue. This is a tooling problem with Flex Builder rather than the code itself, so anyone with any insight, I would really greatly appreciate the help.
    Bayani

    Hi Sudheer,
    Its a Unicode problem.. Check this..
    unicode problem: the data object cannot be converted to character type
    cheers,
    Prashanth
    P.S Please mark helpful answers

  • The class or interface 'flash.utils.ByteArray' could not be loaded.

    Hi all, I am trying to use some of the new functionality that
    is available in AS3 and I keep getting an unfathomable error
    message. The code that I am using is at the bottom of this post.
    No matter what I do I keep getting the following error when I
    compile this code
    The class or interface 'flash.utils.ByteArray' could not be
    loaded.
    And the source line is
    var pixels:ByteArray = srcBmp.getPixels( new
    Rectangle(0,0,imageWidth,imageHeight) );
    Can anybody see what I am doing wrong here? This is driving
    me crazy!!

    I AM THE ULTIMATE CHUMP!!!!!
    I finally figured it out, you can tell I am new to Flash!
    Anyway, I assumed that by selecting ActionScript 3.0 in my
    Actions frame then this ias the version that would be used when the
    movie was exported. However I have found out that I should also
    have been setting the ActionScript version to 3.0 in the Publish
    settings page to. I feel like such an idiot!!!

  • Flash Backwards Compatibility Question

    Hi,
    About a year ago I created a project using the Adobe Flash 5.5 Demo.
    I need to edit the Flash 5.5 file but my employer only has Adobe Flash 5 so I am not able to edit the 5.5 project using Flash 5.
    Question - Can the Flash 6 Demo open a Flash 5.5 file and re-save it as a Flash 5 document?
    If I download the latest Adobe Flash 6 Demo will I be able to open the Flash 5.5 file and then save it back as a Flash 5 file so I can edit it using my employers Flash 5 version?

    Yes, you can open the file with Flash CS6, and then Save it in format Flash CS5
    FLASH Proffesional CS6 ( Flash Professional 11)

  • Definition Flash.util could not be found

    Refers to line: import flash.util.*;
    also get error: Access of possibly undefined property call
    through areference with static type mx.rpc.events:ResultEvent
    in reference to: model.loginVO = LoginVO( event.call.loginVO
    Thanks for any help

    Ok thanks got passed those. How about this one..
    get error
    quote:
    Implicit coercion of a value with static type
    mx.core:UIComponent to a possibly unrelated type mx.core:Container
    refers to line:
    quote:
    selectedChild="{ getView( model.workflowState )}">
    from the block:
    quote:
    <mx:ViewStack
    id="appView"
    selectedChild="{ getView( model.workflowState )}">
    <view:Login id="login" />
    <mx:VBox id="loggedIn" >
    <mx:Label text="{ 'Logged in as ' + LoginVO(
    model.loginVO ).username + ' at ' + model.loginDate }" />
    </mx:VBox>
    </mx:ViewStack>
    TIA

  • Definition flash.utils:Trace could not be found

    Hi,
    I've just tried creating a simple test actionscript 3
    project, but it doesn't seem to recognise the path to trace;
    package {
    import flash.utils.trace;
    import flash.display.MovieClip;
    public class Test extends MovieClip
    public function Test()
    trace("hello");
    Any ideas?

    In Beta3 "the trace method to the unnamed package so no
    import is required"
    see
    What's
    changed in Beta3?

Maybe you are looking for

  • The scroll in touch pad is not working. please help

    i owned hp pavilion dm1, windows 7-64 bit. this happened before. i have to open the mouse window just to make the scrolls work. i asked before about this and someone advised me to uninstall it and install the latest synaptics driver. can i have the l

  • How can I add my iTunes library to a 2nd Mac?

    Hi.  I want to download all my iTunes music and videos onto a Macbook Pro, they already exist on an old MacBook.  When I attempted this the iTunes tells me that my library will removed from my phone.  Why is this and is there a work round? Thanks.

  • Converting digits from display to tactile vibrations

    I would like to get a pulse or pulses for the some output.. i.e. i need to convert digital output (i.e. clock display to tactile display (vibrations)) if the clock or any display, displays 345, then i would have three switches on my module, i switch

  • WL 10.2 to 10.3

    I have a 10.2 WL portal environment and when I run the SmartUpdate it does not see the SP3 or upgrade to 10.3. I have the full install downloaded and installed in another environment but need to know if there is an update available to take my 10.2 to

  • Javascript and hide and show.

    Is there any way to hide single item on the form (not region)? I have tried to hide an item based on the condition. I have radiobutton with value 1 and 0 so I have created on click event that check its value and hides item but: the item that I want t