This week's giveaway is in the JDBC forum.
We're giving away four copies of Java Database Connections & Transactions (e-book only) and have Marco Behler on-line!
See this thread for details.
Win a copy of Java Database Connections & Transactions (e-book only) this week in the JDBC forum!

Angel Taveras

Ranch Hand
+ Follow
since Nov 13, 2008
Angel likes ...
Eclipse IDE Hibernate Spring
Santo Domingo, Dominican Republic
Cows and Likes
Cows
Total received
0
In last 30 days
0
Total given
0
Likes
Total received
0
Received in last 30 days
0
Total given
0
Given in last 30 days
0
Forums and Threads
Scavenger Hunt
expand Ranch Hand Scavenger Hunt
expand Greenhorn Scavenger Hunt

Recent posts by Angel Taveras

Hi Volodymir, i concur with what you saying. Today i've encountered the same issue with an ajax behavior, even when i've mark the initialState of the behavior it gets reset and end it in not rendering the state and after that it throws an ArrayOutOfBoundException in the postback of the ajax request. I'm hoping that someday this feature work as accorded in the spec.
7 years ago
JSF
To make it deterministic you have to change the code to the one below as Stephan suggested



Regards,

The default implementation of Thread.start() look for the given Runnable object on the Constructor if any. For more info check the Thread documentation,

Regards,
Antonio, Hi. I found this sample that have an example about wait, notify, notifyAll, i suggest that you get a book on the matter. Concurrency it's very complicated and
hard to make it right, but not imposible

Cheers,

Angel
Hello David, you're right the ReentrantLock it's the same as the synchronized keyword. With the reentrantlock you can do somethings that with the synchronized you cannot like the posibility to take the lock in a method and release the lock in other method with the synchonized it's automatically taken and released when the scope start/ends.

Regards,

Angel
Leo, i think that this could be mapped as follows:


In JPA 1.0 you cannot sort the resulting List with an aditional column just with the columns provided in the target entity; with Hibernate annotation @OrderColumn(name="order") you could. I didn't understand when you write

- Each subsection may belong to any set of sections



that means a bidirectional relationship?

Regards,

Angel

Hello, Leonardo, could you post please at least the basic mapping that you're trying to map.

Regards,

Angel
The only thing for certain about the main thread it's that it's the entry point of your program and it's the first thread of your program that will be executed. After that
the main thread could end before any other thread; that's, depending of the programming of the other threads.

Regards,
Yes but you can wait for a timeout and retry again. Most of the Async IO and stuff with threading have to do
something similar to yield the proc to other processes. This does not means that you have to do that but it's an approach
You can lock the specific records on the database so every other process that hits the same record for update it will wait
until the lock it's released. Those processes that don't update the record but read data from them will read the data consistently.
For this to work your database must support row locking.


Hi, Do you have too much static data in the application? because that memory it's only recovered when the class that owns the static data
it's unloaded from the classloader

Regards,
9 years ago
No. Java doesn't have that kind of functionality. But you can achieve that using AspectJ
and you have to code the functionality yourself

9 years ago
Hello shialaja, to explain a little about why to use design patterns i will use a metaphor or analogy, i will translate you to the building construction on an architecture point of view.

Why do everyone uses columns when building an structure?

- It's not only because it's been used since ages ago, but also because it solve, address and specific problem. There nothing better to hold and create and maintain and structure steady and it can support a lot of weigh.

Why do we use windows?

and so on,

You'll see that these things that we see on the buildings or the houses follows some patterns that solves an specific problem. When an architect sees some kind of behavior or wants to achieve something, the first thing that comes to it's mind it to look for something similar or someone that done the same before, because easier to understand and it's part of some kind of standard. If that prototype that he found solve perfectly the architect need then most of the work it's already done or if not solve the problem completely it's just only to change a few things but the main idea will be the same.

Since the beginning of software design and software development the architects have found several prototype or some desired behaviors and have seen some kind of pattern in then and they have documented the solutions that they use to solve a series of specific problems.

That why the design pattern exists and are useful for,

Regards,
10 years ago
As Raf said i prefer to store in the DB base the whole name it will make more sense in term of usability when making the querys. Or
you can use the ordinals just as Raf said but you have to take into consideration that when you wanna aggregate new members to
the ENUM must be on the bottom of the already defined members,

Regards
It seens ok, but i don't understand the use of the static fields on the ENUM, you just could use a Constructor with an String to make the representation that i believe you wanna to achieve with
those static fields,

Regards,