Search Results

Search found 4 results on 1 pages for 'cdso1'.

Page 1/1 | 1 

  • JSF2 ResourceBundleLoader override?

    - by CDSO1
    I need to have resource messages that contain EL expressions be resolved when loaded from a ResourceBundle. Basically I have a number of properties files containing the text. Some of the text will look like the following: welcomeText=Welcome #{userbean.name} The only possible way I can see this working currently is implementing a custom taglib so that instead of saying: <f:loadBundle var="messages" basename="application.messages"/> I would have to use <mytaglib:loadBundle var="messages" basename="application.messages"/> #{messages.welcomeText} Given a user with username "User1", this should output Welcome User1 My implementation would then use a custom ResourceBundle class that would override handleGetObject, use the ELResolver to resolve variables etc....Ideas? suggestings? Implementations that are already available? I appreciate your assistance.

    Read the article

  • Java RegEx Pattern not matching (works in .NET)

    - by CDSO1
    Below is an example that is producing an exception in Java (and not matching the input). Perhaps I misunderstood the JavaDoc, but it looks like it should work. Using the same pattern and input in C# will produce a match. import java.util.regex.Matcher; import java.util.regex.Pattern; public class Main { public static void main(String[] args) { String pattern = "aspx\\?uid=([^']*)"; Pattern p = Pattern.compile(pattern); Matcher m = p.matcher("id='page.aspx?uid=123'"); System.out.println(m.groupCount() > 0 ? m.group(1) : "No Matches"); } }

    Read the article

  • Java RegExp ViewState

    - by CDSO1
    I am porting some functionality from a C++ application to java. This involves reading non-modifiable data files that contain regular expressions. A lot of the data files contain regular expressions that look similar to the following: (?<=id="VIEWSTATE".*?value=").*?(?=") These regular expressions produce the following error: "Look-behind group does not have an obvious maximum length near index XX" In C++ the engine being used supported these expressions. Is there another form of regexp that can produce the same result that can be generated using expressions like my example as input?

    Read the article

  • JSF 2 Scriptmanager style functionality

    - by CDSO1
    I need to be able to add some javascript to all ajax postback responses (PartialViewContext.isAjaxRequest == true) but I am not succeeding with any implementation I try. I have tried implementing a PhaseListener and adding my script using PartialResponseWriter.insert* to add eval blocks, as well as trying to add the script by creating a script element. (Results in CDATA cannot nest, or just invalid XML) I have tried decorating PartialViewContextFactory to override the PartialViewContext.processPartial and add the script after the wrapped instance has processed it... How should I go about adding sripts to an Ajax response? Something similar to what .NET has with Scriptmanager.registerClientScriptBlock preferably. Thank you

    Read the article

1