Recent Notes
Displaying keyword search results 1 - 10
Created by Dr. Xi on March 21, 2013 19:47:46
Last update: March 22, 2013 12:30:27
It's normal practice to import types from an external xsd file in WSDL like this:
<wsdl:types> <xsd:schema xmlns:xsd="htt... When you use <dynamic-wsdl> and have Commons XMLSchema on the class path, Spring-WS inlines the xsd in the wsdl. But that doesn't happen when you use <static-wsdl> . You can define a SimpleXsdSchema bean to expose the xsd: <?xml version="1.0" encoding="UTF-8"?> <beans x... where the bean id "hello" should match the schemaLocation attribute in the WSDL (without the .xsd suffix). But note that the SimpleXsdSchema does not inline the xsd. It only makes the xsd available via an HTTP URL. Alternatively, you can simply put the xsd file under the content directory of the webapp (just link any CSS or JavaScript). Anyway, that's a lot of manual...
Created by Dr. Xi on September 06, 2007 03:11:40
Last update: January 31, 2013 12:13:45
The built-in function SYSDATE returns a DATE value containing the current date and time on your system. For example,
UPDATE ACCOUNT SET LAST_MODIFIED = SYSDATE;
updates the LAST_MODIFIED column to the current system time.
select to_char(sysdate, 'MM-DD-YYYY HH24:MI:SS') N...
prints the current date & time.
Created by Fang on January 04, 2013 09:02:44
Last update: January 04, 2013 09:02:44
This snippet sets system properties from Maven surefire test plugin. This is useful when you want to set logging (for example, log4j) properties based on Maven project properties.
Example that sets system property testlog.dir :
<plugins>
<plugin>
<groupId>org.apach...
Example log4j.xml that uses system property testlog.dir :
<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYP...
Created by magnum on November 10, 2012 18:42:19
Last update: November 10, 2012 18:42:19
IFS : The Internal Field Separator that is used for word splitting after expansion and to split lines into words with the read builtin command. The default value is "<space><tab><newline>".
$ echo "$IFS" | cat -vte
^I$
$
Created by magnum on October 22, 2012 15:46:44
Last update: October 22, 2012 15:46:44
Example code from the Linux Programmer's Manual:
#include <stdio.h>
#include <stdlib.h>
#incl...
Created by James on September 20, 2012 15:08:15
Last update: September 21, 2012 11:55:58
The idea is simple: duplicate the input field and position one on top of the other. The top one will take the input, while the bottom one will serve the placeholder. The top one will have a transparent background so the value of the placeholder field will show through. The placeholder field is disabled so that it's value is not submitted with the form. Here's the code:
(function($) { $.fn.placeholder = function(... But in practice, it's tricky. Notice that I used 'background-color': 'rgba(255, 255, 255, 0)' for the background transparency. This is because 'background-color': 'transparent' does not work for IE9. Even though the input is on top of the placeholder, the placeholder always gets the event when you click on the field. That might be...
Created by James on September 20, 2012 10:22:58
Last update: September 20, 2012 10:22:58
This is a simple jQuery placeholder plugin that can be used on both text and password fields. I've been using the Mathias Bynens plugin for a while and it has been quite useful. I decided to create my own plugin because of two problems: The interaction between the Mathias Bynens plugin and jQuery validation can be quite intricate. Placeholder text is lost once the input field gets focus. This can be a problem when I want to auto-focus on a field, say user id on a log in form. I must mention that although it worked for me, this plugin has not been thoroughly tested. Feel free to provide feedback if you see problems.
(function($) { $.fn.placeholder = function(... Since it uses absolute positioning, you...
Created by voodoo on September 17, 2012 15:02:15
Last update: September 17, 2012 15:02:15
Start gdb with the executable and coredump:
$ gdb <path to executable> core
While in the debugger, use the following commands:
(gdb) where ("shows a summary of the stack")
...
Example debug session from Debugging Under Unix: gdb Tutorial :
Use backtrace (or bt ) to see the callstack:
(gdb) backtrace
#0 Node<int>::next (this=0x0) ...
Inspect the value of item_to_remove at address 0xffbef014 (the value is 1):
(gdb) x 0xffbef014
0xffbef014: 0x00000001
(g...
Note: The program must be compiled with the debug switch -g in order to see the source code.
More resources:
Linux software debugging with GDB
Debugging with gdb
Created by Fang on July 25, 2012 12:52:40
Last update: September 14, 2012 13:37:57
Summarized from official JAX-WS documentation : Sending and Receiving SOAP Headers To send a SOAP header:
HelloService helloService = new HelloService(); ... To receive a SOAP header: List<Header> inboundHeaders = bp.getInboundHeaders... Message logging On the client side, set system property: com.sun.xml.ws.transport.http.client.HttpTransport... On the server side, set system property: com.sun.xml.ws.transport.http.HttpAdapter.dump=tru... Propagation of Server-side Stacktrace Propagation of Stack trace is on by default. The whole stacktrace (including nested exceptions) is propagated in the SOAP Fault and the complete exception stacktrace is visible to the client as cause of SOAPFaultException . To turn off stack trace propagation, set this system property on the server: com.sun.xml.ws.fault.SOAPFaultBuilder.disableCaptu... Update: At least on the client side, the property name has been changed to: com.sun.xml.internal.ws.transport.http.client.Http... The messages are dumped to stdout . For...
Created by magnum on September 11, 2012 11:55:43
Last update: September 11, 2012 11:55:43
Excerpt from bash documentation. Quoting is used to remove the special meaning of certain characters or words to the shell. Quoting can be used to disable special treatment for special characters, to prevent reserved words from being recognized as such, and to prevent parameter expansion. There are three quoting mechanisms: the escape character , single quotes , and double quotes . A non-quoted backslash (\) is the escape character. It preserves the literal value of the next character that follows, with the exception of <newline> . If a \<newline> pair appears, and the backslash is not itself quoted, the \<newline> is treated as a line continuation (that is, it is removed from the input stream and effectively ignored). Enclosing characters in single quotes preserves the...