[jboss-user] [JBoss Seam] - Seam Filter + Commons fileupload problem
Hello, i am using the commons file upload api in a servlet to upload files. I noticed when declaring the seam filter in web.xml | | Seam Filter | org.jboss.seam.web.SeamFilter | | | | Seam Filter | /* | | common file upload dont recognizes the multipart content anymore (statement returns false) | boolean isMultipart = ServletFileUpload.isMultipartContent(request); | Well i also tested this on other upload apis(oreilly, seam fileupload) and it seems only to be a problem with the commons fileupload api(commons-fileupload-1.2). I got 2 questions on this. 1) Does the Seam Web Filter do something "unusual" to the request object? 2) i noticed when i declare the filter this way: | | Seam Filter | *.seam | | it works ,will i have any drawbacks with that solution? Thx very much, Bye View the original post : http://www.jboss.com/index.html?module=bb&op=viewtopic&p=4108494#4108494 Reply to the post : http://www.jboss.com/index.html?module=bb&op=posting&mode=reply&p=4108494 ___ jboss-user mailing list jboss-user@lists.jboss.org https://lists.jboss.org/mailman/listinfo/jboss-user
[jboss-user] [JBoss Seam] - rich:calendar localisation problem / improvement suggesstion
Hello , i am using the rich:calendar tag. I noticed the day and week strings are localized (good) but the "today" String on the bottom is not. How can i archieve this? If i have to customize the calendar to do this, can you please tell me where to start (in what java class and/or resource file) Another idea: Well what would be really cool if i could choose also a time in the calendar(for the date object) or if there would be a graphical time input possebility, sth like rich:inputTime(looking like a watch) for example. Is something like this in planning ? If not i maybe do this and post the code here? Thx very much, Holger View the original post : http://www.jboss.com/index.html?module=bb&op=viewtopic&p=4094232#4094232 Reply to the post : http://www.jboss.com/index.html?module=bb&op=posting&mode=reply&p=4094232 ___ jboss-user mailing list jboss-user@lists.jboss.org https://lists.jboss.org/mailman/listinfo/jboss-user
[jboss-user] [JBoss Seam] - Re: h:message for / s:decorate question (cause of the proble
Well first of all sorry to all for the confusion. First of all 1 thing: 1) its working like expected (upgrade to jsf 1.2 and use label attribute ) I was so sure that my message template(generated from redhat developer studio) was the same like in the jsf implementation and that i am doing everything right, but that was wrong. //from generated messages_en.properties javax.faces.component.UIInput.REQUIRED=value is required //from jsf impl.jar javax.faces.component.UIInput.REQUIRED={0}: Validation Error: Value is required. so why i thought that label attribute is ignored was that missing {0}: in my properties file [EMAIL PROTECTED] wrote: anonymous wrote : | Man, just configure your messages.properties file - there are many examples and documentation - and override the message. Done. | When i read this i was so angry course i was so absolutly sure that it has nothing to with the properties file and that i was treated like a noob. Well what to say, chrisitan was absolutly right :-) I am such a damn noob(i admit it).To my excuse - that was a simple but mean little problem. Sorry again for spamming forum. But let me say this at least : i still dont like jsf. XD Thx very much its finally working all and me very happy now. With best regards / whishes (Dont give up - its mostly worth it) Holger View the original post : http://www.jboss.com/index.html?module=bb&op=viewtopic&p=4093679#4093679 Reply to the post : http://www.jboss.com/index.html?module=bb&op=posting&mode=reply&p=4093679 ___ jboss-user mailing list jboss-user@lists.jboss.org https://lists.jboss.org/mailman/listinfo/jboss-user
[jboss-user] [JBoss Seam] - Re: h:message for / s:decorate question
Well finally i found out how to(semi dirty workaround in my opinion) Dont override the required message in your messages.properties It will take effect for all your input fields where required is specified When u got an internet application with just 1 form field thats maybe an solution Instead specify the requiredMessage attribute on inputText tag | | | Do the same for validation and converter messages, if your validator or converter outputs different message u got a problem becourse the decision what error message to output have to be made in the facelet via the validatorMessage attribute. >From jsf 1.2 api anonymous wrote : | ...will be used as the text of the validator message, replacing any message that comes from the validator. | The problem on this approach is the you override the default messages coming from the pre defined validators. Maybe its all working in your enviroment better. Well anyway i like seam but i dont like jsf Bye and thx, Holger View the original post : http://www.jboss.com/index.html?module=bb&op=viewtopic&p=4093643#4093643 Reply to the post : http://www.jboss.com/index.html?module=bb&op=posting&mode=reply&p=4093643 ___ jboss-user mailing list jboss-user@lists.jboss.org https://lists.jboss.org/mailman/listinfo/jboss-user
[jboss-user] [JBoss Seam] - Re: h:message for / s:decorate question
I dont think u got it right, my message properties file is just as it should, the entry that should be used as label is there and configured. Its just the h:message tag in combination with the h:inputText tag that just dont work together. The code i posted (the 2 lines) are so simple, well what can i do/is wrong, its just like in the documentation, i spent a whole day on this. View the original post : http://www.jboss.com/index.html?module=bb&op=viewtopic&p=4093624#4093624 Reply to the post : http://www.jboss.com/index.html?module=bb&op=posting&mode=reply&p=4093624 ___ jboss-user mailing list jboss-user@lists.jboss.org https://lists.jboss.org/mailman/listinfo/jboss-user
[jboss-user] [JBoss Seam] - Re: h:message for / s:decorate question
Now i finally upgraded everything the behaviour is slightly better, but still not like expected: I am using latest jsf ri implementation and jboss-4.2.1.GA in my messages.properties | myInput=Label for my Inputfield | in my facelets page | | | The output should be: | "Label for my Inputfield": Value required | but in fact it is: | Value required | He seems to ignore the label attribute, and i am getting insane on this :-/ Pls help, well at least this behaviour is slightly better than before. Do i really have to rewrite message tag to get this to work? Thx very much , Holger View the original post : http://www.jboss.com/index.html?module=bb&op=viewtopic&p=4093609#4093609 Reply to the post : http://www.jboss.com/index.html?module=bb&op=posting&mode=reply&p=4093609 ___ jboss-user mailing list jboss-user@lists.jboss.org https://lists.jboss.org/mailman/listinfo/jboss-user
[jboss-user] [JBoss Seam] - Re: h:message for / s:decorate question
well i try also to get tomahawk working together with jsf ri. wish me luck - good night View the original post : http://www.jboss.com/index.html?module=bb&op=viewtopic&p=4093578#4093578 Reply to the post : http://www.jboss.com/index.html?module=bb&op=posting&mode=reply&p=4093578 ___ jboss-user mailing list jboss-user@lists.jboss.org https://lists.jboss.org/mailman/listinfo/jboss-user
[jboss-user] [JBoss Seam] - Re: h:message for / s:decorate question
If u want to upgrade to jsf 1.2 too, take a look here: http://www.jboss.com/index.html?module=bb&op=viewtopic&t=94738 I am switiching to last jboss server, i let u know if i get it (finally) to work. View the original post : http://www.jboss.com/index.html?module=bb&op=viewtopic&p=4093540#4093540 Reply to the post : http://www.jboss.com/index.html?module=bb&op=posting&mode=reply&p=4093540 ___ jboss-user mailing list jboss-user@lists.jboss.org https://lists.jboss.org/mailman/listinfo/jboss-user
[jboss-user] [JBoss Seam] - Re: h:message for / s:decorate question
Hello i update to the newest myfaces jar , same behaviour, i am currently trying to upgrade to jsf-1.2_04-b07 but i get the error message java.lang.IllegalStateException: Application was not properly initialized at startup, could not find Factory: javax.faces.context.FacesContextFactory I guess i have to update the jboss server too. I just want to upgrade the jars , damn its all so complicated oo. Il post here if i get it to work View the original post : http://www.jboss.com/index.html?module=bb&op=viewtopic&p=4093517#4093517 Reply to the post : http://www.jboss.com/index.html?module=bb&op=posting&mode=reply&p=4093517 ___ jboss-user mailing list jboss-user@lists.jboss.org https://lists.jboss.org/mailman/listinfo/jboss-user
[jboss-user] [JBoss Seam] - Re: h:message for / s:decorate question
I am using the js implementation coming with jboss-4.0.5.GA () i specified the label attribute on the inputText, still same behaviour. Well guess ill try to update the jsf implementation libs on my jboss server I realized that the newest myfaces implemenations are horrible slow so i tried to avoid an update. Sigh ok ill post here when i am done with it , thx for your quick help pete. View the original post : http://www.jboss.com/index.html?module=bb&op=viewtopic&p=4093494#4093494 Reply to the post : http://www.jboss.com/index.html?module=bb&op=posting&mode=reply&p=4093494 ___ jboss-user mailing list jboss-user@lists.jboss.org https://lists.jboss.org/mailman/listinfo/jboss-user
[jboss-user] [JBoss Seam] - h:message for / s:decorate question
Hello, first of all ill explain what i want to do and then let me ask if its possible with seam look at the following code, it displays an error message for an input field | | | This will produce the following output: "myInput":Value required The thing is that if you use the "for" attribute of a tag It will display the id of the inputText in the resulting error message "myInput":Value required Thats a very very ugly behaviour becourse: 1) if you want to support internationalization you have to localize the ids!(id should be unique and identify sth, and an id is not a label! - very very bad idea) or you have to use to display all messages- 2) i use the ids for updating issues, i cant localized them and ids cant contain spaces, as i already said in point 1 its very stupid design(in my opinion) I whish it could be like this | | | So what to do now? My question is: Is this possible to either get rid of the id string in the error message(and still use the for attribute) or to localize the id part of the error message(without actually changing the value of the id attribute) without programming anything ? (Just with the seam s:message or h:message tags) OR Do i have to programm my own inputText and message implementation? (And how to start with that).Will s:decorate still work with my own implementation(i doubt it) ? Hmm just some words on JSF: I am using jsf for a while now and i am wondering if any of the designers actually use their own framework, such simple things(and many many more) are not possible, very inflexible and far away from daily work, seriously JSF sucks but whats worse, JSF is best Java Web Framework currrently. Anyway thx for your help, and it could all be worse ^^ View the original post : http://www.jboss.com/index.html?module=bb&op=viewtopic&p=4093483#4093483 Reply to the post : http://www.jboss.com/index.html?module=bb&op=posting&mode=reply&p=4093483 ___ jboss-user mailing list jboss-user@lists.jboss.org https://lists.jboss.org/mailman/listinfo/jboss-user
[jboss-user] [JBoss Seam] - logoff question
Hello,i have problems with my logoff action, i need to set the user object to null. The code below dont works (i also made sure theres no seam component with name "user") | @Stateless | @Name("logoff") | public class LogoffAction implements Logoff { | | @In | @Out(required=false) | Member user; | | public String logoff() { | Seam.invalidateSession(); | user = null; | | // TODO Auto-generated method stub | return "logoffsuccess"; | } | | } | | View the original post : http://www.jboss.com/index.html?module=bb&op=viewtopic&p=4005902#4005902 Reply to the post : http://www.jboss.com/index.html?module=bb&op=posting&mode=reply&p=4005902 ___ jboss-user mailing list jboss-user@lists.jboss.org https://lists.jboss.org/mailman/listinfo/jboss-user
[jboss-user] [JBoss Seam] - Re: outject a constant string value from pages.xml
finally found out how to uotput a constant string for example use : use | | View the original post : http://www.jboss.com/index.html?module=bb&op=viewtopic&p=4005538#4005538 Reply to the post : http://www.jboss.com/index.html?module=bb&op=posting&mode=reply&p=4005538 ___ jboss-user mailing list jboss-user@lists.jboss.org https://lists.jboss.org/mailman/listinfo/jboss-user
[jboss-user] [JBoss Seam] - need help pls!!!
Hello in need urgent help for this problem or at least a comment on this http://www.jboss.com/index.html?module=bb&op=viewtopic&t=99753 Sorry for any cross posting but i really need an answer / reaction on this (didnt got any) View the original post : http://www.jboss.com/index.html?module=bb&op=viewtopic&p=4005457#4005457 Reply to the post : http://www.jboss.com/index.html?module=bb&op=posting&mode=reply&p=4005457 ___ jboss-user mailing list jboss-user@lists.jboss.org https://lists.jboss.org/mailman/listinfo/jboss-user
[jboss-user] [JBoss Seam] - Re: outject a constant string value from pages.xml
i noticed the same problem occurs if u use params, u cant output a constant string(u can only use el expression which will be evaluated), i am really getting crazy/ mad on this , why o why? Such a simple thing and i am stuck on it, pls help. View the original post : http://www.jboss.com/index.html?module=bb&op=viewtopic&p=4005459#4005459 Reply to the post : http://www.jboss.com/index.html?module=bb&op=posting&mode=reply&p=4005459 ___ jboss-user mailing list jboss-user@lists.jboss.org https://lists.jboss.org/mailman/listinfo/jboss-user
[jboss-user] [JBoss Seam] - outject a constant string value from pages.xml
| | | | | Hello, i noticed in the rule tag u can sepcifiy an out tag, i want that this out tag to output a constant string value (no el expression), how can i do this, is this possible at all(it really should, i am really confused)? When i use the code above i get the error message "Parsed Expression of unexpected type java.lang.String" Thx very much , it urgent, Bye, Holger View the original post : http://www.jboss.com/index.html?module=bb&op=viewtopic&p=4005347#4005347 Reply to the post : http://www.jboss.com/index.html?module=bb&op=posting&mode=reply&p=4005347 ___ jboss-user mailing list jboss-user@lists.jboss.org https://lists.jboss.org/mailman/listinfo/jboss-user
[jboss-user] [JBoss Seam] - Re: access faces-config.xml in a java bean
Hello i noticed a nice feature in the rule element u can specify out tag, that would be just perfect! I only got 1 problem how can i specify a constant string expression to be outjected: like | | | | | if i put that code in side i got the error message "Parsed Expression of unexpected type java.lang.String" Thx, Holger View the original post : http://www.jboss.com/index.html?module=bb&op=viewtopic&p=4005123#4005123 Reply to the post : http://www.jboss.com/index.html?module=bb&op=posting&mode=reply&p=4005123 ___ jboss-user mailing list jboss-user@lists.jboss.org https://lists.jboss.org/mailman/listinfo/jboss-user
[jboss-user] [JBoss Seam] - Re: access faces-config.xml in a java bean
Oh i got 1 final question, i can get access to the rule i need to know, but i need to get the target viewId How can i archieve this (i am stuck at this point) | | | | java code | Page page = pages.getPage("/index.xhtml"); | Navigation nav = page.getDefaultNavigation(); | for(Rule tmpRule: nav.getRules()) { | log.info("tmp rule: "+tmpRule.getOutcomeValue()); | for(Output tmpOutput: tmpRule.getOutputs()) { | log.info(tmpOutput.getValue()); | } | } | View the original post : http://www.jboss.com/index.html?module=bb&op=viewtopic&p=4005118#4005118 Reply to the post : http://www.jboss.com/index.html?module=bb&op=posting&mode=reply&p=4005118 ___ jboss-user mailing list jboss-user@lists.jboss.org https://lists.jboss.org/mailman/listinfo/jboss-user
[jboss-user] [JBoss Seam] - Re: access faces-config.xml in a java bean
Ah ok :-) Its also in the api if one can read ^^ | @Name(value="org.jboss.seam.core.pages") | and again thx very much, everything is working now :-) Bye, Holger View the original post : http://www.jboss.com/index.html?module=bb&op=viewtopic&p=4005115#4005115 Reply to the post : http://www.jboss.com/index.html?module=bb&op=posting&mode=reply&p=4005115 ___ jboss-user mailing list jboss-user@lists.jboss.org https://lists.jboss.org/mailman/listinfo/jboss-user
[jboss-user] [JBoss Seam] - Re: access faces-config.xml in a java bean
ok the navigation rule defined in pages.xml take effect! Great! Only 1 final problem how can i inject that component? Thx, Holger View the original post : http://www.jboss.com/index.html?module=bb&op=viewtopic&p=4005111#4005111 Reply to the post : http://www.jboss.com/index.html?module=bb&op=posting&mode=reply&p=4005111 ___ jboss-user mailing list jboss-user@lists.jboss.org https://lists.jboss.org/mailman/listinfo/jboss-user
[jboss-user] [JBoss Seam] - Re: access faces-config.xml in a java bean
ok i found potential mistake change to code blow -still no effect (have problems posting xml code) - pages page navigation rule if-outcome="loginsuccess" redirect view-id="/welcome.xhtml" / /rule /navigation /page /pages View the original post : http://www.jboss.com/index.html?module=bb&op=viewtopic&p=4005074#4005074 Reply to the post : http://www.jboss.com/index.html?module=bb&op=posting&mode=reply&p=4005074 ___ jboss-user mailing list jboss-user@lists.jboss.org https://lists.jboss.org/mailman/listinfo/jboss-user
[jboss-user] [JBoss Seam] - Re: access faces-config.xml in a java bean
Hello, i also had the same idea, giving the page element a view id in my case "/index.xhtml" I tried the code u posted ,but it still has no effect. I am using jboss-seam-1.1.0.GA, the pages.xml is deployed correctly (like in the examples), somewhere i got a log "no events.xml defined" , i hope it has nothing to do with the pages.xml. Thx again , in worst case i still can parse faces-config.xml Bye, Holger View the original post : http://www.jboss.com/index.html?module=bb&op=viewtopic&p=4005094#4005094 Reply to the post : http://www.jboss.com/index.html?module=bb&op=posting&mode=reply&p=4005094 ___ jboss-user mailing list jboss-user@lists.jboss.org https://lists.jboss.org/mailman/listinfo/jboss-user
[jboss-user] [JBoss Seam] - Re: access faces-config.xml in a java bean
Oh ok, i didnt knew. (Didnt even noticed seam 1.1.1 is out, from public donwload area your cant donwload http://labs.jboss.com/portal/jbossseam/download/index.html) Well ill try to udate to Seam 1.1.1. In the case i dont post here in this thread again, i got it working. Thx very much, Holger View the original post : http://www.jboss.com/index.html?module=bb&op=viewtopic&p=4005097#4005097 Reply to the post : http://www.jboss.com/index.html?module=bb&op=posting&mode=reply&p=4005097 ___ jboss-user mailing list jboss-user@lists.jboss.org https://lists.jboss.org/mailman/listinfo/jboss-user
[jboss-user] [JBoss Seam] - Re: access faces-config.xml in a java bean
i have to correct the code above the code in pages.xml is: http://jboss.com/products/seam/pages-1.1.dtd";> View the original post : http://www.jboss.com/index.html?module=bb&op=viewtopic&p=4005064#4005064 Reply to the post : http://www.jboss.com/index.html?module=bb&op=posting&mode=reply&p=4005064 ___ jboss-user mailing list jboss-user@lists.jboss.org https://lists.jboss.org/mailman/listinfo/jboss-user
[jboss-user] [JBoss Seam] - Re: access faces-config.xml in a java bean
Hello i a curently trying to migrate the naivagation rule but somehow i making a mistake but cant see it(rule has no effect). rule from faces-config.xml (working) loginsuccess /welcome.xhtml rule in pages.xml (not working) when i deploy the application i get the log "reading pages.xml" so i am prettysure i should take effect, but i dont. Any clue what i am doing wrong? View the original post : http://www.jboss.com/index.html?module=bb&op=viewtopic&p=4005063#4005063 Reply to the post : http://www.jboss.com/index.html?module=bb&op=posting&mode=reply&p=4005063 ___ jboss-user mailing list jboss-user@lists.jboss.org https://lists.jboss.org/mailman/listinfo/jboss-user
[jboss-user] [JBoss Seam] - Re: access faces-config.xml in a java bean
i read the manual and looked at the example in seam jboss-seam-1.1.0.GA one thing i noticed: the navigation rules are defined in a file called navigation.xml, the fine grained stuff in pages.xml and the rest in faces-config.xml This makes sense to me. Now. As i understood gavin i should move that rules to pages.xml (have to redefine them course the syntax in pages.xml is different to "traditional" navigation rules) Then i can access the via the build in pages component But all i need is to access the navigation rules defined in navigation.xml. Will that build in component allow me this ? Thx very much, holger View the original post : http://www.jboss.com/index.html?module=bb&op=viewtopic&p=4005058#4005058 Reply to the post : http://www.jboss.com/index.html?module=bb&op=posting&mode=reply&p=4005058 ___ jboss-user mailing list jboss-user@lists.jboss.org https://lists.jboss.org/mailman/listinfo/jboss-user
[jboss-user] [JBoss Seam] - Re: access faces-config.xml in a java bean
thx for the tip, ill put some time on it and take a look at it right now. If i got any problem, can i post in this thread again? thx very much(this is really the only bulletin board where ppl understand what i want and help me), Bye, Holger View the original post : http://www.jboss.com/index.html?module=bb&op=viewtopic&p=4004874#4004874 Reply to the post : http://www.jboss.com/index.html?module=bb&op=posting&mode=reply&p=4004874 ___ jboss-user mailing list jboss-user@lists.jboss.org https://lists.jboss.org/mailman/listinfo/jboss-user
[jboss-user] [JBoss Seam] - Re: access faces-config.xml in a java bean
Halo, thx for the answer i have 2 questions on this. 1) Why the seam developers decided to introduce a new workflow config file (pages.xml) instead using the jsf approach (faces-config.xml), are there any real advantages on this ? (i have about 50 navigation rules in faces-config.xml, would be a pain to migrate them) 2) Is there a short example with pages.xml and how to acces them with the build in component your mentionend ? Thank your very much, Holger View the original post : http://www.jboss.com/index.html?module=bb&op=viewtopic&p=4004844#4004844 Reply to the post : http://www.jboss.com/index.html?module=bb&op=posting&mode=reply&p=4004844 ___ jboss-user mailing list jboss-user@lists.jboss.org https://lists.jboss.org/mailman/listinfo/jboss-user
[jboss-user] [JBoss Seam] - access faces-config.xml in a java bean
Hello, i need to access the navigation-cases defined in faces-config.xml in my application (a java bean has to do that). I need that becourse i am writing an own wizard (for my case a4j:include is not the right way). Is there any predefined component what does this (like messages) ? or any easy way to access them? An workaround would be to parse faces-config.xml myself, but i think there could be a better way. Can anyone help me with that?, Thank you very much, Holger View the original post : http://www.jboss.com/index.html?module=bb&op=viewtopic&p=4004588#4004588 Reply to the post : http://www.jboss.com/index.html?module=bb&op=posting&mode=reply&p=4004588 ___ jboss-user mailing list jboss-user@lists.jboss.org https://lists.jboss.org/mailman/listinfo/jboss-user
[jboss-user] [JBoss Seam] - Re: seam jsf desgin question
Sigh ^^ Well, ok that means u have -model -view package in every module, did i understood you right? I have to decide between 2 and 3, if u say solution 3) works good for you , ill adopt it. Thank you very much, Holger View the original post : http://www.jboss.com/index.html?module=bb&op=viewtopic&p=3991720#3991720 Reply to the post : http://www.jboss.com/index.html?module=bb&op=posting&mode=reply&p=3991720 ___ jboss-user mailing list jboss-user@lists.jboss.org https://lists.jboss.org/mailman/listinfo/jboss-user
[jboss-user] [JBoss Seam] - Re: seam jsf desgin question
You'll run into problems if you try to put the action methods on entities (e.g. Seam annotations have no effect). Oh i see, so i really have to split actions and model(entity) bean (like it is now) shouldnt this difference be reflected in your package structure or would u put all into the same package for example: 1) de.mycompany.groups -Group.java //entity bean -ManageGroup.java //action interface -ManageGroupAction.java //action interface implementation i noticed when i put actions and beans into the same package and that package contains, lets say 6 entity classes - u will have 18 classes (6*3 [1 for the entity , 1 for the action interface, 1 for the action implementation]) in one singly package, its gets too huge very quick. Should i make a subfolder action in every package or do it this way ? or just like this way 2) de.mycompany.model.group -Group.java de.mycompany.view.group -ManageGroup.java -ManageGroupAction.java or this way 3) de.mycompany.group.model -Group.java de.mycompany.group.view -ManageGroup.java -ManageGroupAction.java or finally this way 4) de.mycompany.group -Group.java de.mycompany.group.view -ManageGroup.java -ManageGroupAction.java waht solution would u choose ? I prefer 2) but i am not sure anymore, can u help please? Bye, Holger View the original post : http://www.jboss.com/index.html?module=bb&op=viewtopic&p=3991501#3991501 Reply to the post : http://www.jboss.com/index.html?module=bb&op=posting&mode=reply&p=3991501 ___ jboss-user mailing list jboss-user@lists.jboss.org https://lists.jboss.org/mailman/listinfo/jboss-user
[jboss-user] [JBoss Seam] - seam jsf desgin question
Hello, i just posted on the myfaces mailing list on jsf application design and package structure The most people the use this approach: 1) The managed bean (seam component) contains the action methods for itself (explanation "course they are tied together") I noticed the seam example applications use a different approach 2) The managed bean(seam component) is a pojo (maybe also an entity bean) and the Actions for it are seperated in 2 files - an interfaces marked local and the implementation for it To show some code to show the different approaches, i choose the seam registration example Approach 1) | public class User implements Serializable { | //properties | | //action method | public String register(); | } | - Approach 2) | public class User implements Serializable { |//properties | } | | @Local | public interface Register | { | //action method | public String register(); | } | | public class RegisterAction implements Register | { |//action method implementation |public String register() |{ | |} | | } | So what approach should i choose (currently using approach2 but thinking about switching to 1) Are there any technical drawback on approach 1) ? Thank your very much for your help , its a very important decision i have to make(also influences the package structure). View the original post : http://www.jboss.com/index.html?module=bb&op=viewtopic&p=3991489#3991489 Reply to the post : http://www.jboss.com/index.html?module=bb&op=posting&mode=reply&p=3991489 ___ jboss-user mailing list jboss-user@lists.jboss.org https://lists.jboss.org/mailman/listinfo/jboss-user
[jboss-user] [JBoss Seam] - Re: null component check in the view -- how does it work?
Well as far as i understand it works like this: first, seam looks if a object for this variable exists, in all scopes, if none was found, seams looks if a component with such a name exists -> (the code u posted) if yes , it will be created. currentUser would only be never null when u write something like this: @Name("currentUser") public class User { } View the original post : http://www.jboss.com/index.html?module=bb&op=viewtopic&p=3962340#3962340 Reply to the post : http://www.jboss.com/index.html?module=bb&op=posting&mode=reply&p=3962340 ___ jboss-user mailing list jboss-user@lists.jboss.org https://lists.jboss.org/mailman/listinfo/jboss-user
[jboss-user] [JBoss Seam] - Re: @OneToMany Question
Hello anonymous wrote : | It sounds like you want a ManyToMany relation. If Tasks can have many TaskItems and a TaskItem can be associated with more than one Task this is a ManyToMany relation, not a OneToMany. | Hmm but the TaskItem dont have any information about the task it owns (no getTask() method) and its not biderectional.I shoudl learn sth about database design. Thx for giving me the right hint i changed my code to: | @ManyToMany( | targetEntity=TaskItem.class, | cascade={CascadeType.PERSIST, CascadeType.MERGE} | ) | @JoinTable( | name="task_taskItems", | joinColumns = { @JoinColumn( name="task_id", unique = false)}, | inverseJoinColumns = @JoinColumn( name="taskItem_id", unique = false) | ) | and now its working - no complaining anymore about duplicated entry. Thank u very much, helped me a lot and sorry for posting in wrong forum. Bye, Holger View the original post : http://www.jboss.com/index.html?module=bb&op=viewtopic&p=3961449#3961449 Reply to the post : http://www.jboss.com/index.html?module=bb&op=posting&mode=reply&p=3961449 ___ jboss-user mailing list jboss-user@lists.jboss.org https://lists.jboss.org/mailman/listinfo/jboss-user
[jboss-user] [JBoss Seam] - @OneToMany Question
Hello, i have a site where the uses can select TaskItems (entities from the database) and set it to a task. I use a OneToMany relationship (a task hast many taskitems) When i set the TaskItems to the task and save it, everything will be ok. But when i save another task whith the same TaskItems, it will fail becourse the primary key of the temporary join table "task_taskItems" is the foreign key to the task item, this means in my case when then taskitems were set to a task, no other other task can have these taskitems So the question is: How can i specify the primary key of the temporary table? As Workaround i could write a Class which wraps around the TaskItems and inside there i can use @JoinColumn but it will mess up my code :-/ | @OneToMany | @JoinTable( | name="task_taskItems", | joinColumns = { @JoinColumn( name="task_id", unique = false), @JoinColumn( name="task_taskItems_id", unique = true) }, | inverseJoinColumns = @JoinColumn( name="taskItem_id", unique = false) | ) | public List getTaskItems() { | return this.taskItems; | } | public void setTaskItems(List taskItems) { | this.taskItems = taskItems; | } | Thank u very much, Holger View the original post : http://www.jboss.com/index.html?module=bb&op=viewtopic&p=3961443#3961443 Reply to the post : http://www.jboss.com/index.html?module=bb&op=posting&mode=reply&p=3961443 ___ jboss-user mailing list jboss-user@lists.jboss.org https://lists.jboss.org/mailman/listinfo/jboss-user
[jboss-user] [JBoss Seam] - @Out Question
Hello, i wrote a register wizard bean where u can register member. How can i tell @Out that it should only export values into context when the value is not null? I found out that @Out always export a value even when null. //export the tester as our logged in user @Out(scope=ScopeType.SESSION, required=false) private Customer user; The thing is when i reuse my wizard bean for edit action(code above) , the logged in user will be exported as a null value. So i changed to code below,which will fix the problem , but i am still wondering if can tell @Out that it should only export non null values @In(required=false) @Out(scope=ScopeType.SESSION, required=false) private Customer user; Thank u very much hope i could describe what i am searching for ^^ Bye, Holger View the original post : http://www.jboss.com/index.html?module=bb&op=viewtopic&p=3961129#3961129 Reply to the post : http://www.jboss.com/index.html?module=bb&op=posting&mode=reply&p=3961129 ___ jboss-user mailing list jboss-user@lists.jboss.org https://lists.jboss.org/mailman/listinfo/jboss-user
[jboss-user] [JBoss Seam] - Re: @Begin and @End
"[EMAIL PROTECTED]" wrote : If you really _have_ to have transparent lazy fetching of data off of the user, combined with caching of that data then create a session-scoped managed persistence context. | | There are a couple of ways to do this, but the easiest is to use Seam 1.1 CVS build and throw the following in components.xml: | | | | java:/myEntityManagerFactory | | | | | | Hello, i want to use the approache mentionend above but i have some questions regarding this. | | 1) | What does "myEntityManagerFactory" means in this context, is that the value of the "jboss.entity.manager.factory.jndi.name" property described in my persistence.xml ? | | | | java:/myEntityManagerFactory | | | | 2) how can i use this(java side)? | | Should i use | | @PersistenceContext | private EntityManager em; | | or (adepting your example nr1) | | @In(create=true) | private EntityManager userDatabase; | | | Thank u very much, | | Holger View the original post : http://www.jboss.com/index.html?module=bb&op=viewtopic&p=3959423#3959423 Reply to the post : http://www.jboss.com/index.html?module=bb&op=posting&mode=reply&p=3959423 ___ jboss-user mailing list jboss-user@lists.jboss.org https://lists.jboss.org/mailman/listinfo/jboss-user
[jboss-user] [JBoss Seam] - Re: ajax4js and seam integration - my guide
Hello, well thats strange, i somehow remember this error but i dindt get it anymore for 1 day,maybe u deploy the jars u copied to $JBOSSSERVERHOME/default/lib with your application? (look at build.xml) If all dont helps, try cleaning up/reinstalling everything, sorry i couldnt help anyfurther, Bye, Holger View the original post : http://www.jboss.com/index.html?module=bb&op=viewtopic&p=3957803#3957803 Reply to the post : http://www.jboss.com/index.html?module=bb&op=posting&mode=reply&p=3957803 ___ jboss-user mailing list jboss-user@lists.jboss.org https://lists.jboss.org/mailman/listinfo/jboss-user
[jboss-user] [JBoss Seam] - ajax4js and seam integration - my guide
Hello, after spending 3 days with trying to integrate ajax framworks with jboss seam i finally get a integration with ajax4jsf working 1) first download ajax4js https://ajax4jsf.dev.java.net/nonav/ajax/ajax-jsf/ 2) copy the following jars to $JBOSSSERVERHOME/default/lib el-api.jar el-ri.jar jsf-facelets.jar ajax4jsf.jar oscache-2.2.jar this has to be done becourse of a global JBoss Classloader Issue (cant find the the posting i found for that, i am sorry) , when i deployed these jars with my application i got a lot of problems, well u can try out maybe u get it working. Also make sure sure the jars mentionend above are not deployed with your application! 3) change web.xml to and make sure no application view handler is defined. | | http://java.sun.com/dtd/web-facesconfig_1_0.dtd";> | | | | | org.jboss.seam.jsf.SeamExtendedManagedPersistencePhaseListener | | | | | change faces-config.xml to | web-app version="2.4" | xmlns="http://java.sun.com/xml/ns/j2ee"; | xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"; | xsi:schemaLocation="http://java.sun.com/xml/ns/j2ee http://java.sun.com/xml/ns/j2ee/web-app_2_4.xsd";> | | | | org.jboss.seam.servlet.SeamListener | | | | | Seam Redirect Filter | org.jboss.seam.servlet.SeamRedirectFilter | | | | | Ajax4jsf Filter | ajax4jsf | org.ajax4jsf.Filter | | |ajax4jsf |*.seam | | | | | | Seam Redirect Filter | *.seam | | | | Seam Exception Filter | org.jboss.seam.servlet.SeamExceptionFilter | | | | Seam Exception Filter | *.jsf | | | | | | javax.faces.STATE_SAVING_METHOD | client | | | org.ajax4jsf.VIEW_HANDLERS | com.sun.facelets.FaceletViewHandler | | | javax.faces.DEFAULT_SUFFIX | .xhtml | | | facelets.REFRESH_PERIOD | 2 | | | facelets.DEVELOPMENT | true | | | com.sun.faces.validateXml | true | | | com.sun.faces.verifyObjects | true | | | org.ajax4jsf.SKIN | DEFAULT | | | | Faces Servlet | javax.faces.webapp.FacesServlet | 1 | | | | | Faces Servlet | *.seam | | | | | org.apache.myfaces.webapp.StartupServletContextListener | | | | 4) if u have a have any h:commandLink with parameters (f:param) replace them with a4j:commandLink or the parameter will get lost It works good for me even conversations seems (what a wordplay) to work. Thats it, well its only a temporary guide until maybe some of the jboss crew can give a more detailed and better solution, hopefully its integrated in the next release :-) (copying the jars in the servers /default/lib directory really gives me a bad taste) Hope i could help someone, Bye, Holger View the original post : http://www.jboss.com/index.html?module=bb&op=viewtopic&p=3957604#3957604 Reply to the post : http://www.jboss.com/index.html?module=bb&op=posting&mode=reply&p=3957604 ___ jboss-user mailing list jboss-user@lists.jboss.org https://lists.jboss.org/mailman/listinfo/jboss-user