Two EO questions (dynamic attrs and validation)

Hello all (I really hope Steve M gets to see this),
I am re-visiting an old project (fantasy) of mine to implement spell checking of certain fields in an Entity Object, The concept is that I will implement the spell checking in an overriden validateEntity method. The way I would like this to work is for spelling errors to be reported to the user when they try to commit; if the user commits again without making any changes, I will assume they want to ignore the spelling errors and will allow the Entity to commit. In order to implement this in a really cooI and generic way, Ineed to be able to do a couple of things that have really stumped me.
The first is in relation to entity validation. The doc states that any EO is assumed to be valid after it is read from the database. Is there any way that I can alter this behaviour so that the EO needs to be re-validated even if it has just been read from the database? Extra credit if this can be done in such a fashion as to not cause the EO's data to be re-posted to the database if the user doesn't make any changes. I have tried over-riding lots of things in the EntityImpl and EntityDefImpl, but I cannot find the right place to do this.
The second thing I would like to do is to add dynamic attributes to an EO instance. The reason I want to do this is so that I can add the spell check code in a generic framework extension class and not have to modify each EO for this behaviour. The attribute I want to add is used to track whether spell checking has already been done on the EO row. I cannot use a java class member variable, as the same instance of the java class is not necessarily used across different web requests - in fact, I have found that the same instance is rarely-to-never re-used in my testing. I can make this work by adding a transient attribute to the EO itself, but this defeats my goal of a generic implementation. I have found some methods in EntityImpl (setDynamicAttributeValue and getDynamicAttributeValue), but they don't appear to do what I want. I've also played around a bit with the EntityDefImpl, but no luck there either.
I do promise to post a blog entry detailing how to do this if this pans out. We have looked at some nice JavaScript-based spell checkers that work well (give suggestions in a pop-up window), but we would like multiple fields on a web page to be spell-checked, and this is difficult to do with those spell-checkers (particularly when you have an af:table with varying number rows).
Any assistance is appreciated,
John

Your mechanism to manage css style classes is a good approach; I have used that many times. I do wonder why the style classes were implemented as a list, instead of a set, but there may be good use cases for using a list.
In some cases you can also consider using CSS PsuedoClasses, which were introduced in JavaFX 8. These are a bit easier to use, especially if you have only two options. But a use case might look like:
public class Message {
    public enum Status { NORMAL, WARNING, CRITICAL }
    private final ObjectProperty<Status> status = new SimpleObjectProperty<>(Status.NORMAL);
    private final StringProperty message = new SimpleStringProperty();
    // constructor, getters, setters, and property accessors....
public Label createLabel(Message message) {
    PseudoClass warning = PseudoClass.getPseudoClass("warning");
    PseudoClass critical = PseudoClass.getPseudoClass("critical");
    Label label = new Label();
    label.textProperty().bind(message.messageProperty());
    message.statusProperty().addListener((obs, oldStatus, newStatus) -> {
        label.pseudoClassStateChanged(warning, newStatus == Message.Status.WARNING);
        label.pseudoClassStateChanged(critical, newStatus == Message.Status.CRITICAL);
    return label ;
And then your css looks like
.label:warning {
    -fx-text-fill: orange ;
.label:critical {
    -fx-text-fill: red ;

Similar Messages

  • Two workflow questions, (1) importing and (2) saving/exporting

    Apologies if the below questions are too elementary. I've just started using Lightroom. I've been trying out various editing/organizing programs and I haven't yet found the perfect one. Can someone tell me if Lightroom is capable of the following:
    1. I shoot in Raw+Jpeg format. When I copy images from my camera to my computer, I always create a new folder that represents my event and put the jpegs in \Pictures\[Event]\ and the raw images in \Pictures\[Event]\Raw\. Is there a way to instruct Lightroom to perform this function through the import module, i.e. have a single import event that copies jpegs in an \...\[Event]\ folder while copying dng to \...\[Event]\Raw\ and importing only the dng files into my Lightroom catalog. Is this possible?
    2. Also, can someone explain how Lightroom handles edits? Say I've edited a dng in my library. Is the dng file changed on my computer itself? How about the jpeg (remember, I copy jpeg+dng to my computer)? Is there a way to instruct Lightroom to automatically (i.e. default behavior) overwrite the jpg file when any changes are made to the dng file, but prevent the dng file from being overwritten? What about instances where I also want to overwrite the dng - how do I accomplish this?
    Thanks.
    =|

    theNE0one wrote:
    I completely understand and appreciate how Lightroom treats raw images. However, if I shoot Raw+jpg, what difference does it make whether or not the jpg file changes? If my raw file is untouched, I don't also need to make sure that the jpg remains in its virgin state...even if the majority of users prefer to keep both untouched, at least allow the option for people that want a different method of handling their files!
    Lightroom has no feature to overwrite your JPGs automatically.
    Might I suggest a workflow change ... shoot raw only, when you need a .jpg, have Lightroom export one for you.
    If Lightroom handled Face/Places/Sharing well, I wouldn't need to mess with a second program (i.e. Picasa), but right now it doesn't look like it can handle what I want. I understand that I can use Metadata/Keyword tags to identify People and Places, and that there are plug-ins to upload to Picasa web albums, but these options aren't executed well enough in LR3 for me to give up Picasa. The plug-in doesn't work nearly as cleanly as the native Google program, and "Faces" is a chore in Lightroom. Picasa can automatically detect faces and makes tagging/organizing/working with images much easier. While I'm on the topic, can anyone explain why such a useful feature (that's available on free and basic image software) is not included in Lightroom? Is there any possibility that it'll be included in the final version of LR3? What about the upcoming Aperture 3? Is it that "Faces" is perceived as a basic consumer feature that isn't used in higher-end software? Will this always be excluded from this "class" of software?
    Using LR3 Beta to decide whether the software works the way you want isn't a good idea. I'm guessing, but I don't know for sure, that the uploading to Picasa will work a lot better in the finished product. Hard for me to imagine a program being easier to tag/organize than Lightroom, and while I don't use Picasa, I can't see how it could be easier in tagging and organizing. It is my opinion (and you might think differently) that using two different organizing software programs on your photos is more trouble than it is worth, especially since you have to constantly "synchronize" the two different organizers.
    No one here works for Adobe, and even if there was someone here from Adobe, they can't tell you what will be in future releases. We can only guess, and we don't know.
    Finally, can you explain xmp? I've done some keyword tagging on my images within Lightroom. If I were to later use another program, would the keywords be picked up? From your explanation it sounds like there are two aspects to a file, the image section and the xmp section. Is the xmp section the part that includes information about the photo? I.e. settings, metadata, etc.??
    Keywords that Lightroom writes to xmp should be readable by almost every other photographic application. But please be aware that Lightroom, by default, does not write keywords to the photo files. You have to specifically tell Lightroom to do so, by either turning on an option, or by using Ctrl-S on selected photos. Xmp includes all the metadata, which includes captions, keywords, Lightroom edits, and basically any information supplied by the user rather than by the camera.

  • Build dataguard two more questions. password prompt and certificate error

    The fiirt two data guard instances are built. One is running fine the second I'm getting this error in the primarys alert log. it looks like it is a certificate error but I'm having a hard time nailing it down.
    BTW: Instance is 11.2.0.1
    Thread 1 advanced to log sequence 318 (LGWR switch)
    Current log# 6 seq# 318 mem# 0: +DATA/sfs01/onlinelog/group_6.4762.769266689
    SSL Client: Server DN doesn't contain expected SID name
    Archived Log entry 706 added for thread 1 sequence 317 ID 0x799622d4 dest 1:
    Thu Mar 22 12:46:48 2012
    SSL Client: Server DN doesn't contain expected SID name
    The third and final data guard instance I'm building is 3T and taking forever to restore. Two questions:
    1) Can I suspend rman and restart it.
    2) when I restart rman how do I keep it from prompting me for the password. I would prefer to put a nohup on a shell script.
    Here is the script. Right now I'm running it manually but would relly to run with nohup so I can go get lunch.
    rman target SYS@sor01_primary auxiliary / << EOF
    run {
    allocate channel C1 device type disk;
    allocate auxiliary channel C2 device type disk;
    allocate auxiliary channel C3 device type disk;
    allocate auxiliary channel C4 device type disk;
    allocate auxiliary channel C5 device type disk;
    duplicate target database for standby nofilenamecheck;
    release channel C1;
    release channel C2;
    release channel C3;
    release channel C4;
    release channel C5;
    EOF

    Hello (certificate error is vague. By that I mean whoever wrote that error message)
    Can I suspend rman and restart it? I believe no, stop and restart should work.
    Something like this, I use an env file can post if it helps :
    #!/bin/bash
    . /u01/app/oracle/dba_tool/env/DATABASE.env
    echo "Starting RMAN..."
    $ORACLE_HOME/bin/rman target SYS@sor01_primary auxiliary << EOF
    run {
    allocate channel C1 device type disk;
    allocate auxiliary channel C2 device type disk;
    allocate auxiliary channel C3 device type disk;
    allocate auxiliary channel C4 device type disk;
    allocate auxiliary channel C5 device type disk;
    duplicate target database for standby nofilenamecheck;
    release channel C1;
    release channel C2;
    release channel C3;
    release channel C4;
    release channel C5;
    }My env file ( yours will be different ) use env to check you compare to your profile
    export ORACLE_BASE=/u01/app/oracle
    export ORACLE_HOME=/u01/app/oracle/product/11.2.0.2
    export ORACLE_SID=STANDBY
    export ULIMIT=unlimited
    export ORA_NLS33=$ORACLE_HOME/ocommon/nls/admin/data
    export LD_LIBRARY_PATH=$ORACLE_HOME/lib:$ORACLE_HOME/network/lib
    export LIBPATH=$LD_LIBRARY_PATH:/usr/lib
    export TNS_ADMIN=$ORACLE_HOME/network/admin
    PATH=$ORACLE_HOME/bin:$ORACLE_BASE/dba_tool/bin:/bin:/usr/bin:/etc:/etc/X11/xserver/C:.
    export PATHI run from the cron which is similar to nohup as far as env goes.
    Best Regards
    mseberg
    Edited by: mseberg on Mar 22, 2012 2:32 PM
    Edited by: mseberg on Mar 22, 2012 2:41 PM

  • Two iPhone questions (existing customer and data plan)

    Hello, I have two questions about the iPhone. I am on a family plan with At&t. I don't pay my bill. I want to keep it that way. Will I just be able to take my sim card out of my phone and put it in the iPhone since it's AT&T? Or do I use a new sim card and when activating it choose existing customer?
    My second question is I am wondering if it is possible to use an iPhone without the data plan. I know I will be missing visual voicemail and edge but I don't care. Also, will this make me get a thousand dollar bill if I accidentally press safari and don't have a data plan? Thanks.

    friend18 wrote:
    Hello, I have two questions about the iPhone. I am on a family plan with At&t. I don't pay my bill. I want to keep it that way. Will I just be able to take my sim card out of my phone and put it in the iPhone since it's AT&T? Or do I use a new sim card and when activating it choose existing customer?
    You can't use the SIM from your existing phone. You would use the new SIM and activate as an existing customer.
    My second question is I am wondering if it is possible to use an iPhone without the data plan. I know I will be missing visual voicemail and edge but I don't care. Also, will this make me get a thousand dollar bill if I accidentally press safari and don't have a data plan? Thanks.
    You have to get the data plan and for $20 it's worth it, not only is it unlimited data but includes 200 text messages. Without the data plan, you'll pay for every voicemail you access, every text message, any time you check weather/email/youtube/etc. In a nutshell, the data plan covers a lot more than just using Safari to browse the web.

  • Two noob question about unstable and abs

    Hi for everyone, I'm a brand new Arch user, coming from 2 years of Gentoo (because of that long compile times - I don't have a cluster), and earlier some Suse.
    Got two little(?) problem:
    1. I would like to give 'abs' a try, but I'm behind our corporate firewall, so I can only access the web via https?@:80 and pop/smtp. How does one can sync abs like this?
    2. I uncommented the unstable branch in pacman.conf, like this:
    [extra]
    # Add your preferred servers here, they will be used first
    Include = /etc/pacman.d/extra
    Include = /etc/pacman.d/unstable
    And havinf the unstable mirrors like this:
    # The Unstable tree. Contains unstable or development versions of packages.
    [unstable]
    Server = http://archlinux.antesis.org/unstable/os/i686
    Server = ftp://archlinux.creativa.cl/unstable/os/i686
    Server = http://darkstar.ist.utl.pt/archlinux/unstable/os/i686
    Server = ftp://ftp.archlinux.de/pub/archlinux/unstable/os/i686
    Server = ftp://ftp.ibiblio.org/pub/linux/distributions/archlinux/unstable/os/i68
    6
    Server = ftp://ftp.mpi-sb.mpg.de/pub/linux/mirror/ftp.ibiblio.org/pub/Linux/dist
    ributions/archlinux/unstable/os/i686
    Server = ftp://ftp.oit.unc.edu/pub/Linux/distributions/archlinux/unstable/os/i68
    6
    Server = ftp://ftp.parrswood.net/Mirrors/ftp.archlinux.org/unstable/os/i686
    Server = ftp://ftp.rez-gif.supelec.fr/pub/Linux/distrib/archlinux/unstable/os/i6
    86
    Server = ftp://ftp.tu-chemnitz.de/pub/linux/sunsite.unc-mirror/distributions/arc
    hlinux/unstable/os/i686
    Server = ftp://gd.tuwien.ac.at/opsys/linux/archlinux/unstable/os/i686
    Server = ftp://saule.mintis.lt/pub/linux/unstable/os/i686
    But when I
    pacman -Syu
    It shows like the unstable 'db' is only 3k 'big'. So I can not find openoffice2 which disturbes me a lot ...
    Thanks for any help.

    1. abs is just a bash script using cvsup IIRC. Take a look at it  (as well as /etc/abs/abs.conf). 
    2. modify pacman.conf like this :
    [extra]
    Include = /etc/pacman.d/extra
    [unstable]
    Include = /etc/pacman.d/unstable

  • Need help. I am running a 27 in imac with 16 gigs of ram. Photoshop runs really fast, except when opening files. It takes 5-10 minutes to open even a small file of 1 meg. I cleaned and validated all the fonts and removed all questionable fonts. Reset pref

    Need help. I am running a 27 in imac with 16 gigs of ram. Photoshop runs really fast, except when opening files. It takes 5-10 minutes to open even a small file of 1 meg. I cleaned and validated all the fonts and removed all questionable fonts. Reset preferences and still have problem. Slow to open and in force quit "Photoshop not responding" At this point should I uninstall and start over.

    What are the performance Preferences?

  • I can't remember my two security questions on my account. I made too many attempts and got kicked out for 8 hours. I do have a back up email addy that's verified on my account as well. Any resolutions?

    Looking for some help please!  I just got an iPad 4 and tried to purchase some apps on it and was prompted to answer my Two Security Questions that are on my apple account, and I can't remember them. I do have another verified email account attached to my account besides my @me.com one.
    I created an apple account a couple years ago when I purchased my iPhone and now I can't remember what my answers were. If anyone has any suggestions or resolutions, it would be greatly appreciated as I cannot purchase anything on my new iPad and cannot make another attempt for 8 hours to my failed attempts :( Thank you

    Tomorrow call AppleCare and ask to be transferred to the account security team.

  • Hello ! When i will Buy a Movie in iTunes, they ask me two Security Questions and i have forget the 2 correct answers. Can you help me please ??

    Hello ! When i will Buy a Movie in iTunes, they ask me two Security Questions and i have forget the 2 correct answers. Can you help me please ??

    Blue, and Mr. Frisky...

  • Two previous questions may not have been as clear as I would have liked. I recently upgraded my MacBook 2008 (10.5.8) to Snow Leopard (10.6.8). With the updates came iTunes 11.1.1 and Quicktime 7.6.6. I am still using Garageband 2008 and iPhoto 2008. When

    Two previous questions may not have been as clear as I would have liked. I recently upgraded my MacBook 2008 (10.5.8) to Snow Leopard (10.6.8). With the updates came iTunes 11.1.1 and Quicktime 7.6.6. I am still using Garageband 2008 and iPhoto 2008. When I create music in Garageband I usually adjust the volume and save it. Even now when I share the Garageband created files with iTunes 11.1.1, the volime I previously set in Garageband is retained. However, when I use the music to create a slide show in iPhoto 2008 and export to Quicktime 7.6.6, the volume level I previously set is lost and seems to default to a low level. The problem seems to be either in the slide show export from iPhoto 2008 to Quicktime 7.6.6 or in Quicktime itself. Is there a work around, so that I can retain the volume level I had previously set in Garageband, a volume level that seems to transfer without problem to the new iTunes. But then iPhoto 2008 (slide show) possibly or Quicktime 7.6.6 do not cooperate. Before I did the upgrade to Snow Leopard, the new iTunes and Quicktime I had no problems with the set volume being retained in the old Quicktime. The reason I need control over the volume is that all these music files are uploaded to YouTube.

    Two previous questions may not have been as clear as I would have liked. I recently upgraded my MacBook 2008 (10.5.8) to Snow Leopard (10.6.8). With the updates came iTunes 11.1.1 and Quicktime 7.6.6. I am still using Garageband 2008 and iPhoto 2008. When I create music in Garageband I usually adjust the volume and save it. Even now when I share the Garageband created files with iTunes 11.1.1, the volime I previously set in Garageband is retained. However, when I use the music to create a slide show in iPhoto 2008 and export to Quicktime 7.6.6, the volume level I previously set is lost and seems to default to a low level. The problem seems to be either in the slide show export from iPhoto 2008 to Quicktime 7.6.6 or in Quicktime itself. Is there a work around, so that I can retain the volume level I had previously set in Garageband, a volume level that seems to transfer without problem to the new iTunes. But then iPhoto 2008 (slide show) possibly or Quicktime 7.6.6 do not cooperate. Before I did the upgrade to Snow Leopard, the new iTunes and Quicktime I had no problems with the set volume being retained in the old Quicktime. The reason I need control over the volume is that all these music files are uploaded to YouTube.

  • Name of the table where can get the two fields Valid-From and Valid-to for

    Hi gurus
    I want name of the table where I can get the two fields Valid-From and Valid-To and their relation ship with the header table in BOM
    Regards
    Kaisar

    You can only get the Valid from date from the table STKO.
    To get the valid to date, you have to take one day less than the valid-from date of the next record for the same BOM.
    Alternatively use the Function module:
    CSAP_MAT_BOM_READ
    It will give both valid from and valid to dates in the tables parameter: T_STKO
    Regards,
    Ravi
    Edited by: Ravi Kanth Talagana on Jul 2, 2008 4:37 PM

  • Two related questions:  ColdFusion 10/Java applications and J2EE supported servers

    I have two related questions:
    1.  CF10 and integration with Java Web applications
    We have a couple of Java applications running on JRun and interfacing with CF9 applications.  The JRun clusters were created through the JRun Admin and, apart from lack of Axis 2.0 support, have served us well for years now.  And, as would be the case, the ColdFusion9/Java/Flash application is a critical public-facing application that the business uses for bidding on projects.
    It appears that with ColdFusion 10 on Tomcat, we will not be able to run those Java applications on a Tomcat-CF10 JVM cluster.  Is this correct?  IF so, what are our options? 
    2.  J2EE Application Servers supported by Adobe for CF10
    Which of these is correct?
    A.  This URL (http://www.adobe.com/products/coldfusion-enterprise/faq.html) states "ColdFusion 10 supports IBM® WebSphere, Oracle® WebLogic, Adobe JRun, Apache Tomcat, and JBoss."
    B.  This URL (http://wwwimages.adobe.com/www.adobe.com/content/dam/Adobe/en/products/coldfusion/pdfs/cf1 0/coldfusion10-support-matrix.pdf) states:
    "J2EE application servers: WebLogic Server 10.3, 11.1, WebSphere Application Server 7, ND 7 JBoss 5.1, 6.0, 7.1.0"
    I *think* "A" above is wrong re. support for Adobe JRun.  It does not specify a version of Apache Tomcat unless it is simply referring to the custom version the comes with CF10.
    Option "B" above shows no support of Adobe JRun or 'standard' Apache Tomcat.
    Thanks,
    Scott

    Question 1 above was answered:  "No support for Java web applications under CF10's custom version of Tomcat"
    Question 2:  No answer yet:  Is Apache Tomcat (NOT Adobe's customized version) supported for CF10 J2EE deployment?  I do not see any installation instructions on how to install CF10 on Apache Tomcat 6 or 7.
    Is anybody using Apache Tomcat as their J2EE app servers and, again, NOT Adobe's customized/limited version? 
    Thanks,
    Scott

  • Two unrelated questions, syncing and mail

    I have two unrelated questions.
    1. I can't seem to for the life of me copy playlists between devices. Both my IPod Nano and my IPhone 4s are connected to my computer right now. Using autofill, I was able to put all the music in my ITunes library on my phone, but when I sellect the playlists, copy and paste them, they won't move and remain only on the IPod and the computer. Can someone please tell me how to get them onto my phone? There are currently no playlists on the phone.
    2. My other question is about mail, whenever I send a mail, the phone says that it was rejected by the server and a copy has been placed in my outbox. What's going on here?

    1) Is the "Manually Manage Music and Videos" box checked under the Summary tab in iTunes on each of your devices?
    2) Try deleting the account under Settings > Mail, Contacts, Calendars, and then re-add it.

  • HT201363 I don't remember my two security questions and I saw where you could send it to your email but the email it shows I could send it to is not the email I set up with it is there a way I can change the email on there to send to the email I have

    I don't remember my two security questions and I saw where you could send it to your email but the email it shows I could send it to is not the email I set up with it is there a way I can change the email on there to send to the email I have?

    The Best Alternatives for Security Questions and Rescue Mail
         1.  Send Apple an email request at: Apple - Support - iTunes Store - Contact Us.
         2.  Call Apple Support in your country: Customer Service: Contact Apple support.
         3.  Rescue email address and how to reset Apple ID security questions.
    An alternative to using the security questions is to use 2-step verification:
    Two-step verification FAQ Get answers to frequently asked questions about two-step verification for Apple ID.

  • I forgot to answer two security questions, and I can not make purchases in app store

    I forgot to answer two security questions, and I can not make purchases in app store

    If you have a rescue email address (which is not the same thing as an alternate email address) set up on your account then the steps half-way down this page should let you reset them : http://support.apple.com/kb/HT5312
    If you don't have a rescue email address (you won't be able to add one until you can answer 2 of your questions) then you will need to contact iTunes Support / Apple to get the questions reset.
    Contacting Apple about account security : http://support.apple.com/kb/HT5699
    When they've been reset (and if you don't already have a rescue email address) you can then use the steps half-way down the HT5312 link above to add a rescue email address for potential future use

  • HT5699 I can't remember the answers to my Apple ID security questions. 1 Reply Latest reply : by alexbird I have I money in my apple I'd and when tried to purchase Apps asking me two security question but I am not remember the answer so I need your help

    I can't remember the answers to my Apple ID security questions.
    1 Reply Latest reply : by alexbird I have I money in my apple I'd and when tried to purchase Apps asking me two security question but I am not remember the answer so I need your help

    Hello there, Subhi.sa.
    Just wanted to second Niel's recommendation. Additionally this Knowledge Base article also provides some steps you can take yourself if you don't remember your security questions:
    Apple ID: All about Apple ID security questions
    http://support.apple.com/kb/HT5665
    What should I do if I don't remember the answers to my Apple ID security questions?
    Try answering them at least once to see if you can get them right, even if you are not sure you remember the answers to your security questions.
    If you are confident you can't remember them, try one of the following:
    If you have three security questions and a rescue email addresssign in to My Apple ID and select the Password and Security tab to send an email to your rescue email address to reset your security questions and answers. 
    If you have one security question and you know your Apple ID passwordsign in to My Apple ID and select the Password and Security tab to reset your security question.
    If you have one security question, but don't remember your Apple ID passwordcontact Apple Support for assistance. Learn more about creating a temporary support PIN to help Apple confirm your identity when you contact Apple Support.
    Note: If you have forgotten your password and answer your security questions incorrectly too many times in a row, you will be unable to try to answer your security questions for a period of time. During that time you will not be able to reset your password and will not have access to your account.
    Thanks for reaching out to us on the Apple Support Communities.
    Cheers,
    Pedro D.

Maybe you are looking for