Same Multi comparator used in 2 different popups

Hi,
I am using a multi comparator to do a sorting for the search results in a pop screen for a customer details.Here is the code
class MultiComparator<T> implements Comparator<CustomerVO> {
public int compare(CustomerVO o1, CustomerVO o2) {
int i = o1.getCustId().compareTo(o2.getCustId()); // primary
int j = o1.getCustName().compareTo(o2.getCustName()); // secondary
if (i > 0) {
return 1;
} else if (i < 0) {
return -1;
} else {
if (j > 0) {
return 1;
} else if (j < 0) {
return -1;
} else {
return 0;
if (sortColumn == null) {
Collections.sort(searchList, new MultiComparator<CustomerVO>());
This is fine for the selected popup screen which is displaying the customer details.
Now i need to use the same comparator for another popup screen which is displaying customers contact details
but importantly it does have the custId and CustName fields displayed in that popup. In such case how i can use the
same Comparator for displaying the contacts details as they dont include the custId and custName which is a
part of the Comparator. I hope i am clear with my question.
Thanks.

Thanks Sabre for the templated class , that was a typo. How can i use the same comparator used for customer screen popup for another popup screen which displays contact details but doesnot have the custId & custName fields. Hence how can i retain the same ordering of customer screen popup (using multi comparator) for contact details?

Similar Messages

  • Same parameter-map used on 2 different classes

    Greetings,
    If the same parameter-map (type connection or http) is used on two different policy-map classes, will that create a conflict in how traffic for each of serverfarms uses persistence or inactivity timeout (script 1)?
    Should we create a different instance of parameter-maps for each policy-map class (script 2)?
    Script 1
    parameter-map type connection inactivity_2000
    set timeout inactivity 2000
    parameter-map type http persistence-rebalance
    persistence-rebalance
    policy-map multi-match L4_POLICY
    class L3-4_VIP_A
    connection advanced-options inactivity_2000
    appl-parameter http advanced-options persistence-rebalance
    loadbalance policy L7_Serverfarm_A_Policy
    loadbalance vip inservice
    loadbalance vip icmp-reply active
    class L3-4_VIP_B
    connection advanced-options inactivity_2000
    appl-parameter http advanced-options persistence-rebalance
    loadbalance policy L7_Serverfarm_B_Policy
    loadbalance vip inservice
    loadbalance vip icmp-reply active
    Script 2
    parameter-map type connection L3-4_VIP_A_connection
    set timeout inactivity 2000
    parameter-map type connection L3-4_VIP_B_connection
    set timeout inactivity 2000
    parameter-map type http L3-4_VIP_A_http
    persistence-rebalance
    parameter-map type http L3-4_VIP_B_http
    persistence-rebalance
    policy-map multi-match L4_POLICY
    class L3-4_VIP_A
    connection advanced-options L3-4_VIP_A_connection
    appl-parameter http advanced-options L3-4_VIP_A_http
    loadbalance policy L7_Serverfarm_A_Policy
    loadbalance vip inservice
    loadbalance vip icmp-reply active
    class L3-4_VIP_B
    connection advanced-options L3-4_VIP_B_connection
    appl-parameter http advanced-options L3-4_VIP_B_http
    loadbalance policy L7_Serverfarm_B_Policy
    loadbalance vip inservice
    loadbalance vip icmp-reply active
    Thanks

    you can reuse the same parameter map.
    Gilles.

  • How to create multi connections using JCO in different application servers

    Hi all,
    I want to connect to sap using jco from different servers at the same time.
    There are 3 Jave application servers now. But I can only connect the sap servers using ONE server ( random ) at same time. It means when one server connect to sap , the other 2 servers CANNOT connect to sap.
    Anyone konw what wrong?
    Thanks in advance.
    Ned

    ......

  • Clearing network cache worked; ONCE. This is ONLY on facebook. Two users on computer (win 7 Prof), same browswer, both use Facebook. Different results. Why would clearing cache work once??

    Windows 7 professional. Firefox 6.02
    Only on Facebook.
    Yet 2 users on computer and 2 different results. I have already uploaded a screen shot. I see more and more users are reporting this, but many more are probably not.

    In general theory, one now has the Edit button for their posts, until someone/anyone Replies to it. I've had Edit available for weeks, as opposed to the old forum's ~ 30 mins.
    That, however, is in theory. I've posted, and immediately seen something that needed editing, only to find NO Replies, yet the Edit button is no longer available, only seconds later. Still, in that same thread, I'd have the Edit button from older posts, to which there had also been no Replies even after several days/weeks. Found one that had to be over a month old, and Edit was still there.
    Do not know the why/how of this behavior. At first, I thought that maybe there WAS a Reply, that "ate" my Edit button, but had not Refreshed on my screen. Refresh still showed no Replies, just no Edit either. In those cases, I just Reply and mention the [Edit].
    Also, it seems that the buttons get very scrambled at times, and Refresh does not always clear that up. I end up clicking where I "think" the right button should be and hope for the best. Seems that when the buttons do bunch up they can appear at random around the page, often three atop one another, and maybe one way the heck out in left-field.
    While I'm on a role, it would be nice to be able to switch between Flattened and Threaded Views on the fly. Each has a use, and having to go to Options and then come back down to the thread is a very slow process. Jive is probably incapable of this, but I can dream.
    Hunt

  • Can same status be used for 2 diffrent screens

    can same status be used for 2 different screen of a SAME program ???

    Yes same status can be used for 2 different screens using the statement.
       set pf-status '0100'.
    Regards
    Gopi

  • Can two peeps use iChat with different accounts on the same computer?

    What do I do to REMOVE an old AIM account and replace it with a new account in IChat?
    Can two peeps use iChat with different accounts in the same computer?
    (Actually, two people share a laptop, but one of us cannot use her AIM account cuz mine is in iChat already... And, when traveling, I have the computer - and I would like to use iChat on the computer...)

    In iChat 4 you can have more than one AIM Valid name logged in at once.
    AIM valid = AIM, @mac.com or a MobileMe name.
    What you are then stuck with is that iChat is linked to one Buddy Picture and The one Mac User Account's Address Book which may or may not have Full Names, emails details, or a Nickname in iChat 4 linked to the Screen Names.
    Whilst it does let you both log in whilst using one Mac User Account there are drawbacks about who uses the keyboard and reading meesages from the other persons Buddies.
    8:50 PM Sunday; November 30, 2008

  • We have 3 devices used by 3 different people under the same Apple ID, how do I stop getting my daughters texts, both sent and received?

    We have 3 devices used by 3 different people under the same Apple ID, how do I stop receiving my daughters texts? Both sent and received.

    When you use the same Apple ID on 3 devices it means you are all using the same (email, imessaging, calendar etc).  Since iCloud (MobileMe) is designed to be shared across all devices included Macs, it means all devices setup with the same ID will have access to the information.
    Text messaging is relevant only to the number you are texting.  This is done through your telecom companys lines and not on Apples.
    If you do not want to have others be able to read any of your information then it is best you each have your own account.

  • HT1495 I have just purchased a second ipod and have 2 computers can i use one ipod on each computer with the same account. I have a different playlist on my second computer. Thanks,

    I have just purchased a second ipod and have two computers w7 and xp, can i use one on each computer with the same account. I have a different playlist on my second computer. Thanks.

    Sorry to ask, how do I do it please. I have my first ipod with the same account on both computers that have different libraries one of which I am building now. Do I have to de-authorise my original ipod on the computer that I want to use my new ipod on with the new library and then register my new ipod. I would rather do this than have 2 libraries on one itunes, but keep the same account details. 

  • How to set Different applications running on the same computer to use different Gateways?

    Dear All,
    I would like to have different applications running on the same computer to use different Gateways (both gateways are in the same subnet).
    Is it possible in Windows7 with / without a third-party utility?
    Current scenario & requirements:
    I have two internet connections. Both are in the same subnet (192.168.1.0/24) and connected to the same LAN switch
    Gateway for the first connection is 192.168.1.1
    Gateway for the second connection is 192.168.1.2
    I need to set my chrome browser & google talk to use the gateway 192.168.1.1
    I need to set my IE & skype to use the gateway 192.168.1.2
    Is it possible? Answers are appreciated!!
    Regards,
    Anees

    Hi,
    I agree with Bill. Gateway is essentially an IP address for one network to other networks. For example, you have two networks: network A and network B, to make the two networks communicate with each other, you must go through Gateway. That is, as long
    as you set Gateway, then you can make the two networks communicate with each other. The ip address for Gateway is the ip of device with routing enabled. One host machine can own multiple gateways. 
    Andy Altmann
    TechNet Community Support

  • I set up my new computer using the apple ID i always use, and then later migrated all my files from my old mac book to the same new one, but under a different user (same ID). how do i consolidate the two users on my new mac book?

    i set up my new computer using the apple ID i always use, and then later migrated all my files from my old mac book to the same new one, but under a different user (same apple ID). how do i consolidate the two users on my new mac book?

    Well if you use the Finder Go menu to Computer, a window opens up double click on your boot drive and then on Users folder, open the other user folder and open Public and drop your files into DropBox
    When you do this it will copy them and change the permissions and user assigned to it, so log into the other user and place them into your respective normal folders.
    Once you have all your files over and don't need the old user, use System Preferences > Accounts to delete it if you wish, however it's good two Admin accounts on the machine in case something bad happens in the other. Some people for security reasons on use a Standard account for most uses and a emergency Admin account.
    One can still do most Admin things in Standard user.

  • Can use the same thread safe variable in the different processes?

    Hello,
    Can  use the same thread safe variable in the different processes?  my application has a log file used to record some event, the log file will be accessed by the different process, is there any synchronous method to access the log file with CVI ?
    David

    Limiting concurrent access to shared resources can be better obtained by using locks: once created, the lock can be get by one requester at a time by calling CmtGetLock, the other being blocked in the same call until the lock is free. If you do not want to lock a process you can use CmtTryToGtLock instead.
    Don't forget to discard locks when you have finished using them or at program end.
    Alternatively you can PostDeferredCall a unique function (executed in the main thread) to write the log passing the apprpriate data to it.
    Proud to use LW/CVI from 3.1 on.
    My contributions to the Developer Zone Community
    If I have helped you, why not giving me a kudos?

  • Accessing the same database file using different handles/cursors

    Will there be any problems accessing the same database file using different DB handles in a transactional environment? We have implemented a process which have multiple transient threads coming up and initiating DB opens and read/write operations to the same database file using different handles and cursors?
    Can this potentially create any problems/bottlenecks? Can someone suggest the best way to deal with this scenario?
    Thanks in advance.
    SB

    Hi,
    Berkeley DB is well suited to the scenario you describe. You need to ensure that Berkeley DB is configured correctly for transactional access, the best information describing the requirements is in the Reference guide here:
    http://download.oracle.com/docs/cd/E17076_02/html/programmer_reference/transapp.html
    If there will be multiple threads operating concurrently, then you will need to design your application to detect and deal with deadlock situations.
    Regards,
    Alex Gorrod
    Oracle Berkeley DB

  • HT5824 Can use you use the same icloud & itunes account with 2 different cell phone numbers?

    Can I use the same icloud & itunes account with 2 different cell phones that have 2 different numbers?

    Yes. Two iDevices can share the same iTunes Library as long as both are configured to use the same Apple ID.

  • [svn:bz-trunk] 21394: bug fix for watson 2887837 Not getting duplicate session detected error when same flex client id is used from two different HTTP sessions in CRX .

    Revision: 21394
    Revision: 21394
    Author:   [email protected]
    Date:     2011-06-16 12:34:13 -0700 (Thu, 16 Jun 2011)
    Log Message:
    bug fix for watson 2887837 Not getting duplicate session detected error when same flex client id is used from two different HTTP sessions in CRX.
    get the sessions id before we invalidate the duplicate session.
    Checkintests pass
    Modified Paths:
        blazeds/trunk/modules/core/src/flex/messaging/endpoints/BaseHTTPEndpoint.java

    For our profect I think this issue was caused as follows:
    Believing that remoting was full asynchronous we fired a 2 or 3 remote calls to the server at the same time ( within the same function ) - usually when the users goes to a new section of the app.
    This seemed to trigger the duplicate http session error since according to http://blogs.adobe.com/lin/2011/05/duplication-session-error.html  two remote calls arriving before a session is created will cause 2 sessions to be created.
    Our current solution ( too early to say it works ) is to daisy chain the multiple calls together .
    Also there seemed to be an issue where mobile apps that never quit ( thanks Apple! )  caused the error when activated after a few hours.
    I guess the session expires on the server and the error above occurs on activation.
    So the mobile apps now ping the server with a remote call when activated after sleeping for more than one hour.
    All duplicate http errors are silently caught and reported.
    Fingers crossed we won't get any more!

  • Re: Running the same (Forte) application multiple times -for different

    Hi
    We had the same problem - how to deploy a number of identical applications, using each their own db.
    (for training).
    The solution we used is to wrap the entire application into different applications by using a very small
    module called KURSUS01, KURSUS02 etc, that did nothing but call the start procedure of the main app.
    Then in the dbsession connect, we made a call appname to get the application name, and appended the
    first 8 chars to the dbname. Thus our dbnames now points to logicals name: rdbdataKURSUS01, rdbdataKURSUS02 etc.
    All this allows us to deploy the identical apps in the same env, or change one version, and run both the old
    and new program on the same pc and server at the same time (eg. KURSUS01 and KURSUS02).
    I also think this is a kludge - but it works nicely!
    Jens Chr
    KAD/Denmark
    -----Original Message-----
    From: Haben, Dirk <[email protected]>
    To: 'Soapbox Forte Users' <[email protected]>
    Date: 15. januar 1999 09:41
    Subject: Running the same (Forte) application multiple times - for different business clients.
    Hi All
    We have a number of different business clients all willing to use our
    application.
    The (forte) application is to run on our machines etc for these (business)
    clients.
    All (business) clients will have their data kept in separate Oracle DBs
    (instance).
    The problem now is that the entire (forte) application is written using
    DBSessions.
    Now, depending on what business client needs to be serviced (so to speak) we
    need to attach to the right DB - or use the "right" SO.
    The two options we can think of are:
    Option1:
    Programatic change to somehow "know" what (business) client (DB) I'm talking
    about and then use the right DB.
    Pro:
    Only one forte environment to maintain
    Can run multiple (business) clients on same PC at the same time
    Con:
    Requires many program changes
    bending O-O rules(?)
    can't dynamically name SOs so can it be done at all? (ResourceMGRs maybe?)
    Option2:
    Use separate environments! One for each business client.
    Pro:
    More defined separation of app and data,
    SLA-easy
    Con:
    Maintain "n" number of environments
    Can only run the application for one environment (business client) at a time
    on one PC - Big Negative here!
    Not knowing any feasible solution to option 1 (without much code changes and
    developer moaning) I would go for option two; as I have already worked on
    multi-environment setups on VMS back at the Hydro (hi guys).
    I would appreciate any comments from anyone who has solved this problem.
    How, Why Pro Con etc.
    TIA,
    Dirk Haben
    Perth, WA
    To unsubscribe, email '[email protected]' with
    'unsubscribe forte-users' as the body of the message.
    Searchable thread archive <URL:http://pinehurst.sageit.com/listarchive/>
    To unsubscribe, email '[email protected]' with
    'unsubscribe forte-users' as the body of the message.
    Searchable thread archive <URL:http://pinehurst.sageit.com/listarchive/>

    Hi
    We had the same problem - how to deploy a number of identical applications, using each their own db.
    (for training).
    The solution we used is to wrap the entire application into different applications by using a very small
    module called KURSUS01, KURSUS02 etc, that did nothing but call the start procedure of the main app.
    Then in the dbsession connect, we made a call appname to get the application name, and appended the
    first 8 chars to the dbname. Thus our dbnames now points to logicals name: rdbdataKURSUS01, rdbdataKURSUS02 etc.
    All this allows us to deploy the identical apps in the same env, or change one version, and run both the old
    and new program on the same pc and server at the same time (eg. KURSUS01 and KURSUS02).
    I also think this is a kludge - but it works nicely!
    Jens Chr
    KAD/Denmark
    -----Original Message-----
    From: Haben, Dirk <[email protected]>
    To: 'Soapbox Forte Users' <[email protected]>
    Date: 15. januar 1999 09:41
    Subject: Running the same (Forte) application multiple times - for different business clients.
    Hi All
    We have a number of different business clients all willing to use our
    application.
    The (forte) application is to run on our machines etc for these (business)
    clients.
    All (business) clients will have their data kept in separate Oracle DBs
    (instance).
    The problem now is that the entire (forte) application is written using
    DBSessions.
    Now, depending on what business client needs to be serviced (so to speak) we
    need to attach to the right DB - or use the "right" SO.
    The two options we can think of are:
    Option1:
    Programatic change to somehow "know" what (business) client (DB) I'm talking
    about and then use the right DB.
    Pro:
    Only one forte environment to maintain
    Can run multiple (business) clients on same PC at the same time
    Con:
    Requires many program changes
    bending O-O rules(?)
    can't dynamically name SOs so can it be done at all? (ResourceMGRs maybe?)
    Option2:
    Use separate environments! One for each business client.
    Pro:
    More defined separation of app and data,
    SLA-easy
    Con:
    Maintain "n" number of environments
    Can only run the application for one environment (business client) at a time
    on one PC - Big Negative here!
    Not knowing any feasible solution to option 1 (without much code changes and
    developer moaning) I would go for option two; as I have already worked on
    multi-environment setups on VMS back at the Hydro (hi guys).
    I would appreciate any comments from anyone who has solved this problem.
    How, Why Pro Con etc.
    TIA,
    Dirk Haben
    Perth, WA
    To unsubscribe, email '[email protected]' with
    'unsubscribe forte-users' as the body of the message.
    Searchable thread archive <URL:http://pinehurst.sageit.com/listarchive/>
    To unsubscribe, email '[email protected]' with
    'unsubscribe forte-users' as the body of the message.
    Searchable thread archive <URL:http://pinehurst.sageit.com/listarchive/>

Maybe you are looking for