HuiSheng Xu [http://community.jboss.org/people/rebody] created the discussion

"Why cannot use slash(/) in activity name"

To view the discussion, visit: http://community.jboss.org/message/545240#545240

--------------------------------------------------------------
Hi guys,

It is totally weird, that jPDL didn't allow using slash(/) in activity name.  I 
searched though XML specification and there is no limitation for this.  And, 
there is no such limitation for transition name, only for activity name.

Now our customer's process need put a slash(/) in an activity name,  I went to 
do some demostration, Every designing stuff are all right. Then when I try to 
deploy the process, it tell me the process is invalid.  It is horrible.

So I really want to know, is there any reason that we shouldn't use slash(/) in 
activity name?  Because if this rule is not necessary, I didn't want to tell 
our customers that they must change their process to remove all of slash(/).

Here is the validation in JpdlBinding.java
public void parseName(Element element, ActivityImpl activity, Parse parse) {
    String name = XmlUtil.attribute(element, "name", isNameRequired(), parse);
    
    if (name!=null) {
      // basic name validation
      if ("".equals(name)) {
        parse.addProblem(XmlUtil.errorMessageAttribute(element, "name", name, 
"is empty"), element);
      } else if (name.indexOf('/')!=-1) {
        parse.addProblem(XmlUtil.errorMessageAttribute(element, "name", name, 
"contains slash (/)"), element);
      }
      activity.setName(name);
    }
  }


--------------------------------------------------------------

Reply to this message by going to Community
[http://community.jboss.org/message/545240#545240]

Start a new discussion in jBPM Development at Community
[http://community.jboss.org/choose-container!input.jspa?contentType=1&containerType=14&container=2035]

_______________________________________________
jboss-user mailing list
jboss-user@lists.jboss.org
https://lists.jboss.org/mailman/listinfo/jboss-user

Reply via email to