Best way to retreive an attributeValue from the bindings in a backing bean?

What is the best way to retreive a value from an interator in your data bindings inside a backing bean?
I can come up with a way were i resolve the value of an expression like #{bindings.myAttribute.value}
Is this the best way or is there an easier?
I can also place a hidden inputField were i bind the value to the attribute in my bindings and set the bindings of the input field to my backing so i can just call the .getValue in my backing bean...

Yannick
What is the best way to retreive a value from an interator in your data bindings inside a backing bean? Using JDeveloper 11.1.1.3.0 I created an example application
at http://www.consideringred.com/files/oracle/2010/Thread1665841AttributeValuesApp-v0.01.zip
It illustrates the behaviour for 3 different approaches to get an attribute value in a managed bean:
public class WithAttributeValues
  public int getMyIdFromEL()
    return (Integer)ELHelper.get("#{bindings.myId.inputValue}");
  public int getMyIdFromAttributeBinding()
    BindingContainer vBindingContainer =
       BindingContext.getCurrent().getCurrentBindingsEntry();
    ControlBinding vControlBinding = vBindingContainer.getControlBinding("myId");
    AttributeBinding vAttributeBinding = (AttributeBinding)vControlBinding;
    return (Integer)vAttributeBinding.getInputValue();
  public int getMyIdFromIterator()
    BindingContainer vBindingContainer =
       BindingContext.getCurrent().getCurrentBindingsEntry();
    DCBindingContainer vDCBindingContainer = (DCBindingContainer)vBindingContainer;
    DCIteratorBinding vDCIteratorBinding =
       vDCBindingContainer.findIteratorBinding("findSomeMyRowsIterator");
    Row vRow = vDCIteratorBinding.getCurrentRow();
    return (Integer)vRow.getAttribute("myId");
}For some reason the approach using getMyIdFromIterator() does not behave as intended when navigating the current row.
see screencast at http://www.screencast.com/t/nIJ3DpsNE9Y
Maybe John Stegeman can explain why that is because it is basically the same approach as he suggested in this forum thread.
But if you don't have an attribute binding because you only use the iterator... Is it an option to create an attributeValue and bind it to the iterator so you can use it in your backing bean that way? Based on my findings above, using attributeValues bindings seems to be preferable.
or is it only possible when you realy have an inputField bound to the attributeValue? The example application in Thread1665841AttributeValuesApp-v0.01.zip does not have any af:inputText components.
Your question about "the best way" made me wonder if that wouldn't require JSR 227 API, so I posted that question in another forum thread, "How to get an attribute value using JSR 227 API ?"
at How to get an attribute value using JSR 227 API ?
regards
Jan Vervecken

Similar Messages

  • HT5922 I have some devices that i no longer use with AirPlay. What's the best way to remove those devices from the AirPlay List?

    Bonjour,
    I have some devices that i no longer use with AirPlay. What's the best way to remove those devices from the AirPlay List?

    In article <e35sc3$ru1$[email protected]>,
    "-->dan mode" <[email protected]> wrote:
    > > All
    > > I have a website I would like to remove from the
    internet, However I am
    > > planning on keeping the IP for a development
    location and would like to
    > > put
    > > a page up that says this site is no longer
    available. Is this how you do
    > > it
    > > or are there other pages to display when a site is
    removed.
    > > Thanks
    > > Dave
    Depending on how long the site has been active, it may be
    already
    spidered by search engines and cached. However, for the most
    part, I
    usually use my FTP program OR even Dreamweaver itself (now
    that I can)
    to delete files on the server just as I do locally. Hit the
    delete and
    confirm

  • What is the best way to remove personal data from the hard drive in preparation for selling my old Mac?

    I am going to sell or perhaps donate my old Power Mac G5.  Is there an easier, yet comprehensive way to remove my data from the hard-drive?  My best approach is dumping anything I do not want found into the trash.
    I am running Mac OS 10.5.8 on the powermac G5

    For better security than the simple Erase (which does not actually over-write the data blocks, only clears the directory), choose Security Options, and Zero all data, one pass.
    After a Zero all data, the only way to recover the data is to dis-assemble the drive in a clean room and use expensive test gear to recover a little of the data. That is good for all but Military Secrets.
    If you really trust no one under any circumstances, remove the drive and beat it to death with a hammer.

  • Best way to deal with photos from the start? (Bridge CS5 and iPhoto)

    Hi all,
    I'm just learning the ropes of the whole CS5 suite, and was starting to add keywords etc. in Bridge when I realized I couldn't access the files in my iPhoto ('09) library. I've read a few threads about this issue, but haven't really found a consensus on how to deal with it.
    I figure I'm in a good position to get things right from the start since I have no tags or ratings etc. in my iPhoto setup (and have only added keywords to the few pics that weren't in my iPhoto Library), and am wondering what you think is the best way to sort photos given I plan on using them in web design etc., and all the parts of my CS5 suite.
    If getting the photos out of iPhoto is best what's the best way to do that? I've read suggestions to right click on the library and click on "Show Contents"- or something like that, but that does not come up as an option when I right click my iPhoto Library in Bridge. Thanks so much for your help!
    Please let me know if there is any info I could give you that would be helpful in order to figure this one out.
    Best,
    Mara

    I must be far too lazy to be sure.  In iPhoto if I want to move an image all I
    do is click and drag from iPhoto to the desktop.
    Here comes the trouble with using iPhoto and mixing applications. You have
    to be sure what you do in iPhoto because you easily grab the wrong version
    instead of the original.
    As Tai Lao pointed out the the difference between Bridge and iPhoto in short
    is open visible structure for Bridge and hidden invisible library for
    iPhoto.
    There may be perfect and valid reason to use iPhoto but mixing the two
    workflows without thinking or knowing what you do is bound to get you sooner
    or later in trouble with wrong versions of the file.
    And clicking and dragging from iPhoto is easy to mistake in those versions.
    1 - I used to create incredible folder/sub-folder arrangements depending upon
    operating system file management to find files.
    You can create whatever structure you want including a thought through
    naming convention that suites your needs, if you keep doing this in Bridge
    you can easily open and close folders using the folder panel, in iPhoto you
    have a lot of events and albums but none as clear as in Bridge. (at least
    that is my opinion...)
    Also I would prefer to use a good naming convention with less folders and
    subfolders instead of bad file naming and many well named folders. Also
    using the metadata options description and keywords let's you easily find
    the files you want but when having the need to retrieve the original from an
    external disk or DVD using less folders will be quicker to find.
    Since depending upon metadata keywords or star ratings I now prefer to have
    all images (originals and amended) in one single folder as Bridge (or iPhoto
    for that matter) can only see the images in the folder it is looking at.
    Wrong, using the find option (cmd+F) you can specify Bridge to look in main
    folders or entire disk, include the option to look in subfolders and you are
    in business (but the first time Bridge caches it also need to index all the
    metadata, that takes some time but only the first time.
    2 - potential feature request for Bridge?
    To have an option where Bridge can see and display images in subfolder
    arrangements from the folder it is looking at.
    That is already there since a view versions
    Select a folder with subfolders and then from the menu view select 'show
    items for subfolders'
    It is still not a perfect way of functioning but it gets better every new
    version, in CS5 the speed of gathering the files is very much improved.
    However here is iPhoto the winner because it keeps the files in cache (or
    something like that) Bridge is not the best in this behavior but it is
    possible to use.
    This is a bit like a restriction of OS X "All images" to all images in the
    selected folder and all subfolders of the selected folder (if that makes any
    sense at all)
    Many users have tons of files on there system, why would you use that option
    to view all if you are perfectly capable of finding the files or file types
    you want in most applications (but you can also find them in OSX, you want
    psd files do a search for ".psd" and you will see all the psd files on your
    system.
    3 - iPhoto can't really handle large files.  With one event consisting of
    4,500+ images weighing in at 884 MB it is zippy.  Were those to be originals
    at a high resolution iPhoto would probably be tediously slow and require a
    folder/sub-folder arrangement which, to me, seems to undermine the importance
    of managing stuff using keywords.
    IPhoto is not designed to be a professional application, therefore you can't
    expect behavior for this
    In Bridge you have no limit of files on your system only the limit for the
    cache is somewhere around 500.000 I believe. But even Bridge is not really
    designed for handling that amount of files in a pleasant way.
    I also don't know of an application that can do so for normal retail prices,
    most users of that amount of files have custom made or customized
    application that costs many thousands dollars. Bridge is in fact a free gift
    when buying a Suite application from Adobe.
    The file size for viewing in Bridge is by default set to a max of 1 GB but
    that is for building previews you can see thumbs and small previews of
    bigger files. In the Bridge preferences you can set the limit for this to
    whatever you want, it only grows the cache file for previews when using many
    large files.
    In summary: Bridge is great for CS5 partnering on metadata, original images or
    large filesizes. 
    I couldn't agree more!
    iPhoto is great on sharing images across devices and better
    still if those files are low res with small filesizes?
    I couldn't disagree more...
    You can do all of this using Bridge to start own created actions or with
    scripts like image processor.
    Do some research on Adobe TV or view other video tutorials on the web, there
    are many free and good tutorials. You will learn that you can do all you
    want in Bridge (and a lot more...)

  • Best way to access Time Capsule from the Internet?

    I wanted to see if anyone knew of a program or setting I can use in order to access Time Capsule from the internet? I know that probably I will not be able to at this point access it directly, even though it is connected to the internet through my modem, but I do have a Mac at home that is connected to Time Capsule. Isn't their a way that I could connect to the Mac, but not through Back to My Mac, that would show Time Capsule as connected to it, so that way I could access the files? Any ideas would be appreciated.

    It is possible to mount the TC as a network hard drive when outside your regular network.
    1) You will need to reconfigure your router to forward the ports used for AFP (by default 548) to the Time Capsule.
    2) Then when outside the network make sure Finder is active, press Apple+K to bring up the 'Connect To Server' dialog.
    3) Input the WAN IP address of the network to which the TC resides on.
    4) You will be asked for the password used to access TC.
    5) The TC should appear as a mounted drive.
    It is then possible to access files on the TC as well as do a TM backup. To make life easier you can drag the mounted TC into your dock for easier access in the future.
    However, it is obviously recommended to use a strong password to protect the TC (configurable using Airport Utility in the 'Disks/File Sharing' tab). You may also need to use a service like DynDNS if your network does not use a static IP address.
    But I am using my home networks' Time Capsule successfully from the office.

  • Best way to load components seperate from the main movie

    When my flash movie loads, it takes a while to diaplay the
    loading frame because it is too busy exporting the components on
    the first frame. What is the best way of avoiding this, while still
    being able to use the components through the .swf?
    Thanks for any help,
    ~Oni.

    OniLink wrote:
    > When my flash movie loads, it takes a while to diaplay
    the loading frame
    > because it is too busy exporting the components on the
    first frame. What is the
    > best way of avoiding this, while still being able to use
    the components through
    > the .swf?
    >
    > Thanks for any help,
    > ~Oni.
    >
    loadMovie("component.swf", _container);
    the best way is to load it externally but if you don't get
    it, check out
    www.gotoandlearn.com ...
    they have the best tutorials basic and advanced.

  • What is the best way to secure my iPad from ID theft

    What is the best way to secure iPad purchases from the app store?

    Technically, they will import off your flash drive....if it's one of the models that work (maybe 50% do) and if they meet the very rigid naming convention that the iPad insists on.
    It's far easier to use a computer then either sync them on via iTunes, e-mail them to yourself or upload them to something like dropox, then download them onto your device.

  • HT3847 How is the best way to separate copied MP3 from AIFF files in my library?

    How is the best way to separate duplicate MP3 from AIFF files in my library?

    Zice wrote:
    I want higher resolution then afforded in the original download.
    Then why are you converting iTunes purchases?
    You cannot get higher resolution by converting  the original. This goes for converting anything, not just iTunes purchases.
    Creating an AIFF will simply make the file 10 time as large with zero increase in quality.
    Don't really want to debate value of creating the new version.
    Agreed.
    You are simply wasting time and drive space converting iTunes purchases to AIFF.

  • Got new macbook pro. What is the best way to transfer my itunes from my old pc to my new mac? I want to be able to plug my iphones and ipad in to new mac and have redo anything

    Got new macbook pro. What is the best way to transfer my itunes from my old pc to my new mac? I want to be able to plug my iphones and ipad in to new mac and have redo anything

    See Here... This should transfer everything...
    Move iTunes Library from PC to MAC
    http://www.macworld.com/article/146958/2010/03/move_itunes_windows_mac.html

  • I bought CS6 extended yesterday (yes i did). I have CS4 and lots of photo's in bridge (tagged with keywords). What is the best way to get my photos from bridge cs4 to cs6? Is there a guideline how to go about so I don't loose any of my photos/keywords? Wh

    I bought CS6 extended yesterday (yes i did). I have CS4 and lots of photo's in bridge (tagged with keywords). What is the best way to get my photos from bridge cs4 to cs6? Is there a guideline how to go about: so I don't loose any of my photos/keywords? Who can help?

    The Bridge General Discussion can give you the specifics of transferring your information over to Bridge CS6.

  • What is the best way to make a DVD from iMovie

    What is the best way to make a DVD from iMovie?
    I am using iMovie 06 (Naturally) with iDVD 08. I have always used;
    iMovie 06, File > Share to iDVD 08. And got pretty good results.
    Some say the best way is to quit iMovie 06, open iDVD and import the movie from the Media button.
    I have tried both methods in the results look the same. I'm interested in getting the very best quality possible.

    You likely have one of the most expensive media converter boxes on the market today.
    But does it work well with most macs? (my guess is that it does). But more specifically can it "handshake" with an intel based mac? I personally haven't tried it.
    But you may want to read this for yourself if you haven't already:
    http://discussions.apple.com/thread.jspa?threadID=1179361&tstart=2362
    Assuming it works then the best format is .dv which this unit will support apparently.

  • What is the best way to completely uninstall Aperture from a MacBook Pro?

    What is the best way to completely uninstall Aperture from a MacBook Pro.
    I just ordered a new MacBook Pro and I want to remove it from my older MacBook Pro.

    Deleting the application from your /Applications folder is sufficient. There are sample projects in /Library/Application/Aperture you may want to get rid of as well, as they take up a fair bit of space.

  • What is the best way to filter an IP from being blocked?

    What is the best way to filter an IP from being blocked by a false positive? Event Action Filter?

    I'll assume you really mean "blocked" as opposed to "denied". You can either create an event action filter and subtract the blocked action, or you can add the address to the "never block" addresses.

  • What is the best way to call a report from within a report

    What is the best way to call a report from within a report(master / Detail concept)
    A type of drill down report
    Oracle Database 10g
    Forms 10.1.2.0.2
    Report Builder 10.1.2.0.2

    Hi
    Have a look in this link, certainly you will get fix, if not just post a comment on blog, will get reply soon
    http://windows7bugs.wordpress.com/?s=oracle+10g+bug

  • What is the best way to export a cutterline from photoshop?

    What is the best way to export a cutterline from photoshop?
    Wie exportiere ich am am besten einen Schnittlinie aus Photoshop? Ich bekomme von einem Wort immer nur den ersten Buchstaben exportiert, obwohl alles gerastert auf einer Ebene liegt.
    Thank you! Vielen Dank!

    What are you talking about exactly?
    If you need to export vector data Photoshop is not the first choice but if you have Type Layers (without faux styles), Vector Masks or Paths it is possible.
    alles gerastert auf einer Ebene
    does not seem to make sense in this context though.

Maybe you are looking for