Win a copy of Svelte and Sapper in Action this week in the JavaScript forum!

Zee Ho

Ranch Hand
+ Follow
since Jul 20, 2004
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 Zee Ho

thanks dude for your kindly reply, it helps.
11 years ago
why it printed the $MYVAR rather than abc.???



11 years ago
Hi all,
I am using Mac OSX and JDK 1.6, I failed to launch a new process from java because of the environment variable PATH.

If I run new ProcessBuilder().environment(), it only contains the


but if I run



why the PATH is different between my java app and console? I am using the same user to run command and launch my java application.

I did google it, but failed to find anything useful.

waiting for your reply. cheers.
11 years ago
I assume the case is some tables are in one database, some are in other. you may inject different sessionFactory to different DAO, different sessionFactory holds the different database connection information.
But the new class introduced is only for the composite key, I think the hibernate is designed for resolving the inconsistence of Data Model and Object Model. Now, I changed my class just to conform the data model. that does not look nice from my point of view. What you said is good suggestion, but not for my case, acutally MASK is the number in certain arrange, becasue it identify the permission acutally.
All ranchers:
I have got the problem in mapping 2 properties to a composite unique key in hibernate. The target sql script should be like this:

acl_object_identity, recipient are the composite unique key. what I have done is introduce a new class which contains acl_object_identity, recipient,and put the new class as composite-element in my mapping file.


that works. but make my domain object very ugly.

Anyone can give me a hint about how to do it in a nice way. I am quite new to hibernate.
All ranchers:
From OGNL reference book, it supports the syntax like @class@method to do visit the method on class rather than object, is there any way to do the same things in velocity?

For the time being I wrap some static method invocation in to a non-utility class, and visit corresponding method on the object, but it works but looks very stupid, any one can light me in this aspect.
I configure the jetty server to listen to the port 443 and visit it base on https protocal(by explicitly specify the port number), but seeme the jetty server does not response, however, if I change the protocal to http(the port is still 443), it works perfectly, What confuse me is why the server does not give me response in https protocal, it listen on the port!

should I also configure the jetty.xml?
14 years ago


assume I only know the value of price and I want to access the according year how can I do it.

I expect to use //price[text()='29.99']/../../year but It seems do not work, however //price[text()='29.99'] return the price correctly.

So is it means I can not access the parent node on the text()?
java.lang.Error will not be catched if you use catch Exception
14 years ago
try this one
14 years ago
I resolved the problem with this regular expression

[^<]* : [^>]*

any better idea?
14 years ago


still only the bbb : ccc

how to get both?
14 years ago