object persistence of flame-ds

Hey all,.

I need to have a persistence of objects in memory and available to all connected clients.
How should I go ahead and do it?

I thought about creating a class with a static variable and store/load this using a session, me hoping that the static variable is the same for all connected clients. But I don't know if this is the right approach, is it?

If it is not... what would be the appreach good?

Favorite that I have this available in a map using messeging, use the remote features.

ideas, samples, pointers?

RIES


I think you can set the object you need to put at the disposal of all clients connected as BlazeDS destination within the scope. Here is an example:



samples.explorer.EmployeeManager
application

Here is a link to the doc:
http://livedocs.Adobe.com/BlazeDS/1/blazeds_devguide/help.HTML?content=rpc_config_2.HTML#2 60036
The scope... "Indicates whether the object is available as part of the application, the scope, or to the scope of the session. Objects in the scope of the request are stateless. There are objects in the field of application to the web application that contains the object. Objects in the session scope are available to the entire client session. »

-Mykola

Valid values are application and session request. The default value is request.

Tags: Adobe LiveCycle

Similar Questions

  • ObserverPattern

    Hello

    I'm trying to implement some of common oo-design patterns with pl/sql objects but ran into a strange problem.

    I implement the ObserverPattern, but the observable does not take the correct ObserverObjects, after that I joined them.
    The observable only seems to hold local copies of observers and can therefore not updated real observers.
    declare     
         myDevice     DeviceClass; -- observer
         mySensor     SensorClass; -- observable
    begin
         myDevice:=DeviceClass();
         mySensor:=SensorClass();
              
         mySensor.registerObserver(myDevice); -- internal value of myDevice is zero
            mySensor.setValue(30); -- this invokes the update method that sends the update to the observer
                                             -- myDevice should have the internal value 30
            myDevice.getValue(); -- should output the internal value updated by the sensor, in this case 30 - but outputs 0
    end;
    While it is true that I can't pass the instance of an object to another object to work with her, which is the OO approach
    value of PL/SQL in the end? In this case, most of the important models cannot be implemented... And this is (IMHO) a very
    bad solution to store these items in the tables (even if it is just temporary) to use Ref and deref, since these objects are
    there to process the data and should not be stored.

    So, did I miss something? How I get this to work?

    Greetings

    A PL/SQL ' + table + "is not a term that I love.

    The term has a very specific meaning in a database - and the structure created in PL/SQL is not in any stretch of the imagination that something like a table. The correct terms are the paintings and collections or associative arrays (depending on how the structure is defined).

    The best place for data however, is inside real SQL tables. Not PL/SQL tables. Tables to provide much more flexibility and ease of use. It offers performance and scalability. It supports parallel processing and a multitude of features CRUD .

    Throw a large amount of data in a PL/SQL table structure and it can exhaust the server memory - and degrade the performance of the server as a system administrator won't even be able to correct the problem through the console.

    Unfortunately, in reason of the expression '+ table' +, there is this notion that the storage of the data in PL/SQL, instead of SQL tables, is an acceptable approach and did not need any review - when this is not the case.

    SQL tables can be static or temporary. A global temporary table SQL (TWG) looks like a definition of class o - o. Set you only once, at the front. When a session 'touch' this TWG via SQL, this session instantiates its own copy private of this TWG. Which is destroyed when the session ends.

    A TWG offers much more flexibility and scalability than PL/SQL tables. Not to say that these paintings are not useful - but they are more often abused than properly used IMO.

    A SQL/GTT table can also serve as a container/object persistence layer. It can be defined as an array of the parent/base abstract class. And any class instantiated child object can be inserted into it. And the SQL language supports filtering of objects of class of just specific children, calling their methods (as part of the projection of SQL), for example, and so on.

    So if your table of PL/SQL is more than a few KB in size (where there may be 100 sessions client creating such tables), or when you need to touch this table using the SQL engine by using the function TABLE() - a likely PL/SQL table is the wrong choice.

  • How to check if the persistence Unit objects are persistent or not?

    How to check if the persistence Unit objects are persistent or not?

    I have correctly set up and deploy the object used as a persistence in Oracle coherence unit according to the guide Chapter 6 of tutorial for Oracle coherence 3.5
    Using the RunEmployeeExample script, I had good results. I see that once the cache object is updated, the database table (employees) is also updated accordingly. Here is the result:
    2009-11-05 11:09:55.043/53.467 Oracle Coherence GE 3.5.2/463 <D5> (thread=Cluster, member=1): Member(Id=2, Timestamp=2009-11-05 11:09:54.867, Add
    ress=192.168.8.80:8089, MachineId=24656, Location=process:1684, Role=OracleRunEmployeeExample) joined Cluster with senior member 1
    2009-11-05 11:09:55.604/54.028 Oracle Coherence GE 3.5.2/463 <D5> (thread=Cluster, member=1): Member 2 joined Service Management with senior memb
    er 1
    2009-11-05 11:09:56.885/55.309 Oracle Coherence GE 3.5.2/463 <D5> (thread=Cluster, member=1): TcpRing: connecting to member 2 using TcpSocket{Sta
    te=STATE_OPEN, Socket=Socket[addr=/192.168.8.80,port=8089,localport=4084]}
    2009-11-05 11:09:57.847/56.281 Oracle Coherence GE 3.5.2/463 <D5> (thread=Cluster, member=1): Member 2 joined Service JpaDistributedCache with se
    nior member 1
    2009-11-05 11:09:57.917/56.341 Oracle Coherence GE 3.5.2/463 <D5> (thread=DistributedCache:JpaDistributedCache, member=1): Service JpaDistributed
    Cache: sending ServiceConfigSync containing 258 entries to Member 2
    2009-11-05 11:10:04.086/62.510 Oracle Coherence GE 3.5.2/463 <D5> (thread=DistributedCache:JpaDistributedCache, member=1): Deferring the distribu
    tion due to 1 pending configuration updates
    [EL Info]: 2009-11-05 11:10:14.36--ServerSession(2883071)--EclipseLink, version: Eclipse Persistence Services - 1.1.1.v20090430-r4097
    [EL Info]: 2009-11-05 11:10:22.312--ServerSession(2883071)--file:/C:/JDeveloper/mywork/AppJPA/JPA/classes/-JPA login successful
    2009-11-05 11:10:24.305/82.729 Oracle Coherence GE 3.5.2/463 <D5> (thread=DistributedCache:JpaDistributedCache, member=1): 3> Transferring 128 ou
    t of 257 primary partitions to member 2 requesting 128
    2009-11-05 11:10:25.697/84.121 Oracle Coherence GE 3.5.2/463 <D4> (thread=DistributedCache:JpaDistributedCache, member=1): 1> Transferring 129 ou
    t of 129 partitions to a node-safe backup 1 at member 2 (under 129)
    2009-11-05 11:10:25.857/84.281 Oracle Coherence GE 3.5.2/463 <D5> (thread=DistributedCache:JpaDistributedCache, member=1): Transferring 0KB of ba
    ckup[1] for PartitionSet{128, 129, 130, 131, 132, 133, 134, 135, 136, 137, 138, 139, 140, 141, 142, 143, 144, 145, 146, 147, 148, 149, 150, 151,
    152, 153, 154, 155, 156, 157, 158, 159, 160, 161, 162, 163, 164, 165, 166, 167, 168, 169, 170, 171, 172, 173, 174, 175, 176, 177, 178, 179, 180,
    181, 182, 183, 184, 185, 186, 187, 188, 189, 190, 191, 192, 193, 194, 195, 196, 197, 198, 199, 200, 201, 202, 203, 204, 205, 206, 207, 208, 209,
    210, 211, 212, 213, 214, 215, 216, 217, 218, 219, 220, 221, 222, 223, 224, 225, 226, 227, 228, 229, 230, 231, 232, 233, 234, 235, 236, 237, 238,
    239, 240, 241, 242, 243, 244, 245, 246, 247, 248, 249, 250, 251, 252, 253, 254, 255, 256} to member 2
    2009-11-05 11:10:40.678/99.102 Oracle Coherence GE 3.5.2/463 <D5> (thread=Cluster, member=1): TcpRing: disconnected from member 2 due to a kill r
    equest
    2009-11-05 11:10:40.678/99.102 Oracle Coherence GE 3.5.2/463 <D5> (thread=Cluster, member=1): Member 2 left service Management with senior member
     1
    2009-11-05 11:10:40.678/99.102 Oracle Coherence GE 3.5.2/463 <D5> (thread=Cluster, member=1): Member 2 left service JpaDistributedCache with seni
    or member 1
    2009-11-05 11:10:40.708/99.132 Oracle Coherence GE 3.5.2/463 <D5> (thread=Cluster, member=1): Member(Id=2, Timestamp=2009-11-05 11:10:40.708, Add
    ress=192.168.8.80:8089, MachineId=24656, Location=process:1684, Role=OracleRunEmployeeExample) left Cluster with senior member 1
    2009-11-05 11:10:40.879/99.303 Oracle Coherence GE 3.5.2/463 <Info> (thread=DistributedCache:JpaDistributedCache, member=1): Restored from backup
     128 partitions
    2009-11-05 11:10:40.879/99.303 Oracle Coherence GE 3.5.2/463 <D4> (thread=DistributedCache:JpaDistributedCache, member=1): 0, 1, 2, 3, 4, 5, 6, 7
    , 8, 9, 10, 11, 12, 13, 14, 15, 16, 17, 18, 19, 20, 21, 22, 23, 24, 25, 26, 27, 28, 29, 30, 31, 32, 33, 34, 35, 36, 37, 38, 39, 40, 41, 42, 43, 4
    4, 45, 46, 47, 48, 49, 50, 51, 52, 53, 54, 55, 56, 57, 58, 59, 60, 61, 62, 63, 64, 65, 66, 67, 68, 69, 70, 71, 72, 73, 74, 75, 76, 77, 78, 79, 80
    , 81, 82, 83, 84, 85, 86, 87, 88, 89, 90, 91, 92, 93, 94, 95, 96, 97, 98, 99, 100, 101, 102, 103, 104, 105, 106, 107, 108, 109, 110, 111, 112, 11
    3, 114, 115, 116, 117, 118, 119, 120, 121, 122, 123, 124, 125, 126, 127,
    2009-11-05 11:28:39.800/1178.224 Oracle Coherence GE 3.5.2/463 <D5> (thread=Cluster, member=1): Member(Id=2, Timestamp=2009-11-05 11:28:39.635, A
    ddress=192.168.8.80:8089, MachineId=24656, Location=site:metsys.metex.com,machine:mw12,process:1752, Role=CoherenceConsole) joined Cluster with s
    enior member 1
    2009-11-05 11:28:40.231/1178.655 Oracle Coherence GE 3.5.2/463 <D5> (thread=Cluster, member=1): Member 2 joined Service Management with senior me
    mber 1
    2009-11-05 11:28:41.633/1180.057 Oracle Coherence GE 3.5.2/463 <D5> (thread=Cluster, member=1): TcpRing: connecting to member 2 using TcpSocket{S
    tate=STATE_OPEN, Socket=Socket[addr=/192.168.8.80,port=8089,localport=4143]}
    2009-11-05 11:30:01.658/1260.082 Oracle Coherence GE 3.5.2/463 <D5> (thread=Cluster, member=1): Member 2 joined Service DistributedCache with sen
    ior member 2
    But I can't check whether the persistence unit is still persistent.

    Published by: jetq on November 5, 2009 11:49

    Re:

        Does the above result shows that the persistence work is finished successfully?
       
    

    Yes, it's nice. What is persistence. These are the characteristics of persistence.

    Junez

  • Persistence of objects called from C screws

    In my first case, I have a single VI compiled into a DLL. This VI carries three different operations, according to the function call:

    It is the first operation. It opens a connection to a UDP stream server. 'ID' and 'SA' are commands to tell the server to start to send UDP data. The function call is:

    Legend (int Func, char * address, float * DataOut, int Len);

    Func is the operation that I want to make address is the IP address on the server, DataOut is a container for data is returned and Len is the size of the container.

    To start to receive data, I write:

    Legend (1, addr, data, 5000);

    DataOut is ignored in this case. To retrieve the UDP packets, the following is used:

    The call is:

    Legend (2, addr, data, 5000);

    In this case, the address is not used. 5000 bytes of data is copied to the location where the data points.

    And finally, to close the stream of this operation:

    Legend (3, addr, data, 5000);

    'SC' is the command to close the stream.

    The above steps work very well. The State of the VI is persistent between function calls, and the connection in the connection ID can be used all the time.

    What I'm trying to do now is to streamline operations by dividing this VI in three separate screws the first operation now looks like this:

    In this case, I'm trying to save the pointers to relevant objects in my C code:

    TD1 * error;
    LVRefNum * connectionid;

    The new function call is:

    callout_connect (addr, login ID, error);

    The next VI becomes:

    With the function call:

    callout_receive (connection, error, data ID, 5000);

    And finally:

    With the function call:

    callout_close (addr, login ID, error);

    Needless to say, split the VI in three separate entities has not worked so far. It compiles, implements a connection, but somewhere the connection is lost.

    My suspicion is that I'm not understanding how the reference of the connection or the pointer to this reference is saved. Any suggestions?

    > Never make myself, I would say the problem is that you are passing a pointer that points to nothing and say LV to fill. This would probably cause your app to crash.

    It was something I knew well too, but it didn't crash. It's okay, I solved it by putting connection and error objects in global variables. It works fine now and seems to be the most elegant solution.

  • A-team Mobile persistence Accelerator - Insertion into the child records for a Parent-child data objects

    Hello team

    We use persistence Mobile Accelerator for our application of MAF. We must build couple of REST services for it (Fetch, Create, Update), problem is we are able to insert/update of the parent records but we are not able to create child records.

    It seems when we ask the operation of creation in the book of the child, is no new line for child is created.

    Here is the screenshot of the data control wizard:

    parent.pngchild.png

    Here is the task (update) and desktop (create) JSON format (TaskAssignment is the address of the child)

    PUT the task:

    {

    'Task': {}

    'ACTIVITY_ID': 100,.

    'PROJECTID': 100,.

    'ACTIVITY_NAME': "string",.

    'DESCRIPTION': 'string ',.

    'PARENT_ACTIVITY_ID': 100,.

    'STATUS': "string",.

    'PRIORITY': "string",.

    'PERCENTAGE_COMPLETE': 100,.

    "START_DATE": "2008-09 - 28 T 21: 49:45.

    "END_DATE": "2014-09 - 18 T 19: 18:33.

    'ETA': ' 2006-08 - 19 T 13: 27:14 - 04:00 ",".

    'ESTIMATED_HOURS': 100,.

    'ACTUAL_HOURS': 100,.

    'OWNER_USER_ID': 100,.

    'CREATED_BY': "string",.

    "CREATION_DATE': ' 2009-05 - 16 T 08: 42:28"

    'LAST_UPDATED_BY': 100,.

    'LAST_UPDATE_DATE': ' 2003-08 - 08T 20: 18:37 - 04:00 ",".

    "TaskAssignment": [{}

    'ASSIGNMENT_ID': 1000.00.

    'PROJECT_TEAM_MEMBER_ID': 1000.00.

    "START_DATE": "2012-09 - 13 T 09: 00:34 - 04:00", ".

    "END_DATE": "2009-10 - 14 T 03: 16:36."

    'CREATED_BY': "string",.

    'CREATION_DATE': ' 2010-03 - 18 T 12: 05:32.

    'LAST_UPDATED_BY': "string",.

    "LAST_UPDATE_DATE": "2018-12 - 28 T 14: 51:14 - 05:00", ".

    'FAVORITE_FLAG': "string".

    } ]

    }

    }

    Workstation:

    {

    "Task": [{}

    "ACTIVITY_ID": 1000.00.

    'PROJECTID': 1000.00.

    'ACTIVITY_NAME': "string",.

    'DESCRIPTION': 'string ',.

    'PARENT_ACTIVITY_ID': 1000.00.

    'STATUS': "string",.

    'PRIORITY': "string",.

    'PERCENTAGE_COMPLETE': 1000.00.

    "START_DATE": "2008-09 - 28 T 21: 49:45.

    "END_DATE": "2014-09 - 18 T 19: 18:33.

    'ETA': ' 2006-08 - 19 T 13: 27:14 - 04:00 ",".

    'ESTIMATED_HOURS': 1000.00.

    'ACTUAL_HOURS': 1000.00.

    'OWNER_USER_ID': 1000.00.

    'CREATED_BY': "string",.

    "CREATION_DATE': ' 2009-05 - 16 T 08: 42:28"

    'LAST_UPDATED_BY': "string",.

    'LAST_UPDATE_DATE': ' 2003-08 - 08T 20: 18:37 - 04:00 ",".

    "TaskAssignment": [{}

    'ASSIGNMENT_ID': 1000.00.

    'PROJECT_TEAM_MEMBER_ID': 1000.00.

    "START_DATE": "2012-09 - 13 T 09: 00:34 - 04:00", ".

    "END_DATE": "2009-10 - 14 T 03: 16:36."

    'CREATED_BY': "string",.

    'CREATION_DATE': ' 2010-03 - 18 T 12: 05:32.

    'LAST_UPDATED_BY': "string",.

    "LAST_UPDATE_DATE": "2018-12 - 28 T 14: 51:14 - 05:00", ".

    'FAVORITE_FLAG': "string".

    } ]

    } ]

    }

    Please let me know if I missed all the details.

    Waiting for answer!

    Thank you

    Diprish

    Massari,

    Task.Java seems good. The question is: how to create the new instance of task assignment in the UI?

    That's what you do: you must use the create operation standard of the palette of the title of the collection of nested task assignment data control. Thus, enrich the collection of task, the collection taskAssignment nested in the task, expand the node of the operations and drag and drop the operation of creation on your page. This should add the new instance to the collection of the current task task assignment. To make sure that this is the case, set a breakpoint in the addTaskAssignment method in Task.java. Then, when you save the parent task, load useful json must include a table nested with the new task assignment.

    Steven Davelaar,

    Oracle Mobile A-team.

  • Persistence of objects on multiple Pages

    After using the reflow for a little while for prototyping, I found myself really wanting the ability to create various objects (navigation elements, feet etc.) that persist over several pages. When a reflow is small and is from the outset, duplicate a page and updates on several pages to make navigation is consistent etc is not a big deal. But as the project progresses, keep the changes once an object (say, the main NAV, regardless of what page it is on) and have these changes repeated in all instances of this object on each page would be extremely useful.

    Is it possible to create objects that persist on several pages? OmniGraffle Pro does a great job with that.

    Hi Steffan-

    There is not currently a way to do this in the reflow. You will soon be able to copy items from one page to another, but we do not have a way to share items on several pages.

    Thanks for the suggestion, however, and with the help of reflow!

    VIC

  • Editing an object that I stored in the persistent store

    I store a custom object in the store persistent and would like to add a new Member.  Someone knows how can I do this?  I'd rather not delete it and store an object in its place because what happens if I need to add more members in the future.  This would encourage me to juggle all versions of my object.  Is there a kind of model for version control that I can apply to my objects stored persistently?

    I don't think it will work.  The link that you say talk us too much serialization, but the persistent object is not serialized as part of persistence.  If you want to serialize her, you should do it yourself.

    I'm guessing that you did not design your class being "expandable". And I'm guessing that you do not want your users to have to recreate these data.

    So I investigate an approach to migration.  In the code that gets the persistent store, got it get the object persistent, then check that it is indeed a picture of your old items.  If it is, convert it to an object type, store it in a collection (vector or Hashtable as suggested, for example) and keep the result, by replacing your old array of persistent storage object.  So your new application includes the old class of objects, exactly as it was, which means that you can install it on top of your existing application.  But once your request is used at the same time, the old persistent object is no longer used.

    Does make sense?

  • Best way to approach persistence

    Hello, all the

    I'm playing with the persistence of data on th BB (4.2 +) API and have a general question about the best/recommended way to use, performance among these two options for the scenario:

    SCENARIO: My application handles about 4 entities ("models", if you want to MVC-talk) information.

    Option 1: Create a class for each model (vector extension) with a PersistentObject and keyfor each.

    Option 2: Create a unique Hashtable or a vector, which will be a single instance of PersistenObject, and there are 4 references to the models/entities.

    Maybe that's not a big deal, but I would like to know which of these two approaches is preferable. Or is there a third?

    What happens if the scenario includes models more and more thousands of entries each?

    Thank you!

    A number of things.

    (1) I think that this comment of Plato is incorrect:

    "all calls to hash.put () will automatically continue the news data - there is no need for calls following to.commit ().

    It is my understanding, that because the object is shared, it seems that this happens, but in fact, except if you make a commit, you cannot be 100% sure that the data has been written to Flash.  However, when a commit is made, treatment will commit all the missing data, so data could be brought through the validation of another application (and vice versa).

    (2) to respond to this comment:

    "If she does go all references each time? Or it it keeps a list of objects 'uncommitted '? "

    My understanding and experience suggests that only the uncommitted objects are validated.  For example, I tested with a vector containing a large number of items.  If I update an element, and then validate the operation, validation is extremely fast.  If I update a lot, and then engages, the validation takes more time.

    One last point, I agree with Simon, I'd go with a hash table or a single vector.  Another consideration is synchronization, you can break it up to make sync easier, if you have multiple Threads that need to synchronize on different parts of this one object.

  • Persistence of application data

    Hi, guys

    Struggling for a while with the fallowing problem:

    I have a fairly complex data (a tree) structure that contains the data to a file structure and some additional info. I'm the persistence it. (Implementation Persistable and everything is fine).

    If I insert my the PersistenceStore structure, change (say adds or removes branches) and exit the application without saving it (the call to commit), I can still see the change I made.

    Is this a normal behavior?

    One solution, I can think of is to make a copy of the charge structure and use it in my code. The copy will not fall to persistence if I hit save, y at - it another way?

    See you soon!

    Alex

    «So in order to have a mechanism to backup/throw for my updates I should clone the object after loading from PS and make changes to the clone...» »

    Fix.

  • Persistence storage problem

    Suppose if the Blackberry app is open and it uses persistence storage to store objects in the process and in this case if the flash memory crosses. What wil happen to application or persistence will store the data in the SD card or an external to the process card remaining?

    Welcome to the forums.

    persistence always uses the internal storage. If it is complete there will be errors.

  • persistence store will erase

    Hi all

    I use the persistence store in my application.

    It works very well. My question here is when I uninstall my application from the device will be the clear data for the get operation?

    "If you remove the .cod file that defines a PersistentStore, all persistent objects that created the .cod file are then removed." Developer reference Doc JDE 4.7.

  • How to exclude the field of persistent object

    Hello

    Is it possible to substitute the PersistanceStore method to persist objects?

    I have a complex data structure I need to store. One of the internal classes contain no persistent field. When I'm storing the data I don't no need to store this field, but the compiler triggers error.

    ... Widget: error! : class... Persistable marked widget by interface:... Persistable is not persistent: _field field: class... Field does not implement net.rim.vm.Persistable

    Is the way to override the implementation of this class persitant and exclude the problematic areas?

    Thanks for the reply.

    I did something similar, I created a class of data for persistence and a class of execution with additional fields.

    It's not very practical, these classes are deep into a tree of complex data, but I guess that's how it should work with BlackBerry.

  • Poblem to persistence storage

    Hi all

    In my application, I use the persistence store object to store the array of objects of the class defined by the user. But whenever I run my application it showed me the error 'Error JVM 104 NonPersistableObjectException' 7 stucks execution.

    In the integer part of the persistence object & all what I have try-catch instructions & I also tried with execution clean.bat hundreds of times. But I didn't come to any solution.

    Is there be no problem by storing the array of objects of class user-defined?... Please help me...

    Any help would be appreciated...

    Concerning

    Please note that all the objects that you want to store in the persistent store must be an instance of the class that implements the Persistable.

    In addition, all areas inside these objects must be an instance of the class that implements the Persistable.

    If the container object implements the Peristable interface, but there is a field that is not persistent, you get problems.

    Another point is that if you have an instance of Vector field, check this vector elements.

    All objects in this vector (or another container as an instance of the Hashtable object) must be an instance of the class that implements the Persistable.

  • How to create a new object on the other list list

    Hello

    I'm trying to insert the result of a query in a list in order to put the new values based on the results of the first query: for example, I have this table which contains records:



    adfcal1.PNG


    My question is:OE to create a new list object on the other hand, if you see the picture shows my list, I want to create another list where I stock ordred values if we in line December we will put 1 in column 12 and if we April we put 1 in the 4th column and if we find in my current line November we put 1 in column 11 :

    I'm stuck in this function

    public List<VisiteCons> MyListResult() {

      
    Query query = em.createQuery("SELECT o FROM Visite o ");
      
    List<Visite> visites = query.getResultList();
      
    List<VisiteCons> result = new ArrayList<VisiteCons>();
      
    for(int row = 0 ; row < visites.size() ; row++) {

      
    int m1 = 0, m2 = 0, m3 = 0, m4 = 0, m5 = 0, m6 = 0, m7 = 0, m8 = 0, m9 = 0, m10 = 0, m11 = 0, m12 = 0;
      
    //Pour m1 january
      
    if(visites.get(row).getM1().equals("janvier")){
      m1
    = 1;
      
    }
      
    VisiteCons vc =  new VisiteCons( m1, m2, m3, m4, m5
      
    , m6, m7, m8, m9
      
    , m10, m11,m12);
      result
    .add(vc);
      
    }
      
    return  result;

    }

    VisiteCons is a constructor that I created.



    and this my entity:

    package model;

    import java.io.Serializable;

    Import javax.persistence.Column;

    Import javax.persistence.Entity;

    Import javax.persistence.Id;

    Import javax.persistence.NamedQueries;

    Import javax.persistence.NamedQuery;

    @Entity

    @NamedQueries ({@NamedQuery (name = "Visite.findAll", query = "select visit o o")})

    Visit/public class implements Serializable {}

    private public static final long serialVersionUID =-6069673717468618734 L;

    @Column (length = 4000)

    private String year;

    @Column (nullable = false, length = 100)

    customer private string;

    @Column (length = 4000)

    private String dep.

    @Column (length = 4000)

    private String State;

    @Id

    @Column (nullable = false, length = 100)

    private String idvisite;

    @Column (length = 4000)

    private String ingaff;

    @Column (length = 20)

    private String m1;

    @Column (length = 20)

    private String m10;

    @Column (length = 20)

    private String m11;

    @Column (length = 20)

    private String m12;

    @Column (length = 20)

    private String m2;

    @Column (length = 20)

    private String m3;

    @Column (length = 20)

    private String m4;

    @Column (length = 20)

    private String m5;

    @Column (length = 20)

    private String m6;

    @Column (length = 20)

    private String m7;

    @Column (length = 20)

    private String m8;

    @Column (length = 20)

    private String m9;

    @Column (length = 4000)

    private String moisvisite;

    @Column (length = 4000)

    private String nbvisites;

    @Column (length = 4000)

    private String prbvisite;

    public Visite() {}

    }

    Visit public (String year, String customer, String dep, State of, string idvisite, String ingaff, String m1,

    M10, m11 String, String m12, m2, m3, m4, m5 String String String String String, string m6, m7 of the chain,

    String m8, m9 String, String moisvisite, String nbvisites, String prbvisite) {}

    This.Annee = year;

    This.client = client;

    This.DEP = dep;

    This.Etat = State;

    This.idvisite = idvisite;

    This.ingaff = ingaff;

    This.M1 = m1;

    This.M10 = m10;

    This.M11 = m11;

    This.M12 = m12;

    This.M2 = m2;

    This.M3 = m3;

    This.M4 = m4;

    This.M5 = m5;

    This.M6 = m6;

    This.M7 = m7;

    This.M8 = m8;

    This.M9 = m9;

    This.moisvisite = moisvisite;

    This.nbvisites = nbvisites;

    This.prbvisite = prbvisite;

    }

    public String {} year

    return year;

    }

    {} public void Name\backup (String year)

    This.Annee = year;

    }

    public String getClient() {}

    customer feedback;

    }

    {} public void setClient (string customer)

    This.client = client;

    }

    public String getDep() {}

    return the dep;

    }

    {} public void setDep (String dep)

    This.DEP = dep;

    }

    public String getEtat() {}

    return status;

    }

    {} public void setEtat (String State)

    This.Etat = State;

    }

    public String getIdvisite() {}

    Return idvisite;

    }

    {} public void setIdvisite (String idvisite)

    This.idvisite = idvisite;

    }

    public String getIngaff() {}

    Return ingaff;

    }

    {} public void setIngaff (String ingaff)

    This.ingaff = ingaff;

    }

    public String getM1() {}

    return m1;

    }

    public void setM1 (String m1) {}

    This.M1 = m1;

    }

    public String getM10() {}

    return m10;

    }

    public void setM10 (String m10) {}

    This.M10 = m10;

    }

    public String getM11() {}

    return the m11;

    }

    public void setM11 (String m11) {}

    This.M11 = m11;

    }

    public String getM12() {}

    return m12;

    }

    public void setM12 (String m12) {}

    This.M12 = m12;

    }

    public String getM2() {}

    return m2;

    }

    public void setM2 (String m2) {}

    This.M2 = m2;

    }

    public String getM3() {}

    return m3;

    }

    public void setM3 (String m3) {}

    This.M3 = m3;

    }

    public String getM4() {}

    Return to m4;

    }

    public void setM4 (String m4) {}

    This.M4 = m4;

    }

    public String getM5() {}

    return m5;

    }

    public void setM5 (String m5) {}

    This.M5 = m5;

    }

    public String getM6() {}

    return of m6;

    }

    public void setM6 (String m6) {}

    This.M6 = m6;

    }

    public String getM7() {}

    return m7;

    }

    public void setM7 (String m7) {}

    This.M7 = m7;

    }

    public String getM8() {}

    back m8;

    }

    public void setM8 (String m8) {}

    This.M8 = m8;

    }

    public String getM9() {}

    return m9;

    }

    public void setM9 (String m9) {}

    This.M9 = m9;

    }

    public String getMoisvisite() {}

    Return moisvisite;

    }

    {} public void setMoisvisite (String moisvisite)

    This.moisvisite = moisvisite;

    }

    public String getNbvisites() {}

    Return nbvisites;

    }

    {} public void setNbvisites (String nbvisites)

    This.nbvisites = nbvisites;

    }

    public String getPrbvisite() {}

    Return prbvisite;

    }

    {} public void setPrbvisite (String prbvisite)

    This.prbvisite = prbvisite;

    }

    }

    You can create a view in the db which reads the data from the table and display it in a different way. Then you use the view to get the data in the format and display it in the user interface

    Sample:

    -create a test line

    Select 1 id, m1 'sep', 'mar' m2, m3 'Feb' from dual;

    -output:

    ID: M1 M2 M3

    ---------- --- --- ---

    1 sep mar Feb

    -which means that your table has a row with Id = 1 nd three visits (MS, mar and Feb).  Now give us a different look from these data using the select statement

    SELECT id,

    (case when ((m1||' +'|| m2 ||) instr)) » +'|| (m3), "jan") > 0 then 'X' other ' ' end) jan.

    (case when ((m1||' +'|| m2 ||) instr)) » +'|| ((m3), "February") > 0 then 'X' other ' ' end) Feb.

    (case when ((m1||' +'|| m2 ||) instr)) » +'|| (m3), "mar") > 0 then 'X' other ' ' end) mar.

    (case when ((m1||' +'|| m2 ||) instr)) » +'|| (m3), ("apr") > 0 then 'X' other ' ' end) Apr.

    (case when ((m1||' +'|| m2 ||) instr)) » +'|| ((m3), 'can') > 0 then 'X' other ' ' end) may,

    (case when ((m1||' +'|| m2 ||) instr)) » +'|| (m3), "jun") > 0 then 'X' other ' ' end) June,.

    (case when ((m1||' +'|| m2 ||) instr)) » +'|| (m3), "Jun") > 0 then 'X' other ' ' end) Jul.

    (case when ((m1||' +'|| m2 ||) instr)) » +'|| ((m3), "August") > 0 then 'X' other ' ' end) aug.

    (case when ((m1||' +'|| m2 ||) instr)) » +'|| (m3), "MS") > 0 then 'X' else ' ' end) Ms.

    (case when ((m1||' +'|| m2 ||) instr)) » +'|| (m3), 'OCTS') > 0 then 'X' other ' ' end) oct.

    (case when ((m1||' +'|| m2 ||) instr)) » +'|| (m3), "nov") > 0 then 'X' other ' ' end) nov.

    (case when ((m1||' +'|| m2 ||) instr)) » +'|| (m3), "dec") > 0 then 'X' other ' ' end) dec

    from (select 1 id, m1 'sep', 'mar' m2, m3 "feb" double);

    -output

    ID J F M A M J J A S O N D

    ---------- - - - - - - - - - - - -

    1 X X X

    or tabular

    You can create a similar sql statement (and there are better ways to do this, but I'm not the whiz sql) and use it to create a database from this view.

    I don't understand what you mean by

    .. and is there a solution of programmatly

    Timo

  • Could not find 'MAF Business objects of REST Web Service' in the Gallery

    Hello

    I installed Jdev studio 12.1.3.0.0 and installed updates for the extension of the MAF. It shows screen-Extensions on Jdev Mobile Application Framework.

    I have windows 32-bit and using the version compatible jdev.

    But there is no option for the creation of 'MAF Business objects of REST Web Service' in the gallery.

    Can someone please help.

    I am also attaching screenshot.

    Thank you

    Abbas Qureshi

    Abbas,

    This wizard is part of the A-team Mobile Accelerator persistence (AMPA), which is a separate JDeveloper extension that works on top of the MAF.

    See this article start for more information.

    Steven Davelaar,

    Oracle Mobile & Cloud A-team.

Maybe you are looking for