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

Rodrigo Alvarez

Ranch Hand
+ Follow
since Apr 10, 2006
Cows and Likes
Total received
In last 30 days
Total given
Total received
Received in last 30 days
Total given
Given in last 30 days
Forums and Threads
Scavenger Hunt
expand Ranch Hand Scavenger Hunt
expand Greenhorn Scavenger Hunt

Recent posts by Rodrigo Alvarez

Hi all,

I am working on SOA projects for a bit more than a year now and, given my current huuuuuuuuuuuuuuuuge experience in Jax-WX, JAXB, WSDL,... I was thinking about upgrading my CV and getting the SCDJWS certification.

Now, I had a look at the exam objectives and noted it mentions quite old stuff like Jax-RPC and the like (and I not sure UDDI is actually widely used in the real world...).

=> my question: do any of you have an idea when Sun migh update the exam to fit J2EE 5 spec?

(Sorry if this questions has already been asked, the only trace I could find was this unanswered topic:

Thank you all in advance,



Just curious: what's so bad about selecting text?

Well, it just looks ugly on my applicaton !

Here's the long story:

This JLabel is part of a ZoneButton, which is a kind of complex button made of a JPanel containing an Icon on the right, the JLabel on the left and another Icon as background. This ZoneButton acts as a toggle button (the background image changes upon selection/deselection), and the ImageIcon changes depending on the "state" of the zone represented by the ZoneButton (there are 4 possible states at the moment).

The text in the JPanel is configured by the end-user, so using a rendered image is not an option.

The whole stuff runs on a touchscreen mini-pc with no mouse or keyboard. What happens is that when the user drags its finger, the text on the ZoneButton gets selected and, well, it does not look nice.
14 years ago
Hi all,

I'm looking for a way to prevent the end user to select text displayed in a JLabel with the mouse (my app is actually running on a touchscreen with no mouse). I could not find any method like "setSelectable(boolean b)" in the JLabel javadoc. Anybody has an idea?

Actually, the component needs not to be a JLabel, I just need to display some text.

Thanks in advance
14 years ago
Hi Joko,

in case that we need to render image for jsp just need to set

You meant "servlet", not JSP, right?

This is incorrect :

I guess you meant

But it would have no effect because ServletResponse.setContentType(...) does not set the response's character encoding if it is called after getWriter().

"response.getOutputStream();" would generate a IllegalStateException for the same reason, see Charles' post above.

JSP is meant to generate text pages, most of the time HTML, they are not meant to send binary data. You'd rather user a servlet to serve binary data.
Hi all,

I agree that experience is far more valuable than a certification, but this makes me come to the opposite conclusion than most of you : I think certifications, at least basic ones like SCJP or SCWCD, have more value when you are *not* experienced.

I passed the SCJP before applying for my first java developper job, this way I could tell a potential employer "I may have no real experience, but at least I've got this paper prooving you that I know at least the basics". Now that I have a little more than one year successful experience, I think that this experience will be much more helpful that the SCJP itself when I'll look for my next job.

Same reasonning for SCWCD. I'm currently a "simple POJO" developer and I'd like to enter the J2EE world. Passing the SCWCD will enable me to tell a potential employer "I may have no experience in J2EE, but at least I have some in Java and I've got this paper prooving you that I know at least the basics of Java web tier".

Studying for a certif is also very helpful to beginners like me for fixing learning objectives when one does not know the context (although I find the exams' objectives too strict on some points: what's the use of remembering the exact signatures of methods? All modern IDE tells me that in real time).

Moreover, I find that most certification study books are especially targeted at beginners, not experienced developers. HFSJ is a good example: it was very useful when I knew nothing in that field, but now that I know a little more I find it much easier to find exact information in the specs than in the HFSJ (I know, the HFSJ clearly states it's not a reference book, this is just a comment, not a complain).

Finally, I agree with Niranjan: certifications are also a good way to prove motivation, whathever your current level is. Passing a certif shows that you are ready to invest time, and generally money, to stay up to date.
[ June 05, 2006: Message edited by: Rodrigo Alvarez ]
Hi all,

The JSP and jslt specs says that <jsp:attribute> can only be used to set tag attributes that are rtexprvalue.

Does anybody has an idea why? How come the following attribute value cannot be considered static :


[ May 31, 2006: Message edited by: Rodrigo Alvarez ]
[ May 31, 2006: Message edited by: Rodrigo Alvarez ]
Options A and D are mutually exclusive:

D. There are some situations where the . (dot) operator must be used

This means that there are situations where the "." cannot be replaced with a "[]"

A. anywhere the . (dot) operator is used, the [] could be used instead.

This means that there are no situation where the "." cannot be replaced with a "[]"

Both cannot be rigth at the same time.

I tried using the isELIgnored=false attribute of the page directive

I know this will sound silly but, did you try isELIgnored="false" (with the quotes) ?

My application is receiving an InputStream containing audio in PCM 8bits mono 8Khz which, utltimately, comes from a telephone call.

Could somedy tell me how to detect DTMF tones inside this audio stream?

I had a look at JTAPI, but it looks like it's a spec made of interfaces only and that implementations are vendor-dependant, so it does not seem to help as I am already receiving the stream from a telephone independant lib.

Thanks a lot in advance
14 years ago

Option C says that doAfterBody is only called when doStartTag() returns EVAL_BODY_INCLUDE or EVAL_BODY_BUFFERED, but there are other possibilities (like the one described in option E). => C is not correct

If doAfterBody returns EVAL_BODY_AGAIN, then doAfterBody is called once again => E is correct
[ May 22, 2006: Message edited by: Rodrigo Alvarez ]

I'm not sure, but I think that when you declare a servlet variable, it's automatically available in the pageScope. So you can try this:

then fill it as you do (whithout re-declaring it) and see if it is available throught {movieLst}.

I agree with them: HFSJ says that <body-content> is mandatory.

Default value is "JSP" in the spec, but this value is invalid for Simple Tag => mandatory <body-content> makes sense to me.

j2eecertiface might be outdated (before the Simple Tag days)

But we also have a request parameter named *mystring*

Oups, yes, you're right, I hadn't seen that part of the question.

m sorry, I don;t uderstand, what doesn't matter? Because later you wrote I'm right.

Hi Aleksander, sorry , didn't mean to offend you. I just meant that it does not matter that the bean doesn't have a "mystring" attribute, because that was not what the setProperty action was trying to access.

but our object doesn't have a property called "mystring"

Doesn't matter. What this setProperty standard action does is trying to set all the properties of the bean whose id == "name" from the request parameters. And yes, you're right, as String doesn't have any bean property setters, this line won't have any effect.

But when we come to this :

I think we are no longer talking about the same "mystring". As Alexander said, the standard action above declares an attribute in the PageScope, which is a JSP Map of <String, Object>, but this scriptlet is plain old servlet, it refers to a servlet instance object called "mystring". I'm not sure whether the output should be "" or a compilation error as this instance does not seem to have been declared (e.g. with a <%! String mystring = "" %> .

Could anybody confirm that servlet variables have nothing to do with PageScope attributes ?