You are viewing a plain text version of this content. The canonical link for it is here.
Posted to user@struts.apache.org by "Weber, Jeremy" <JW...@Eventra.com> on 2003/03/20 18:45:20 UTC
Default Value Question
>From the below code, I know that the gid() method gets called because the
System.out line executes, however the ownerGroup string never gets set. Am
I doing something wrong?
import javax.servlet.http.HttpServletRequest;
import org.apache.struts.action.*;
import java.io.File;
import org.apache.struts.validator.ValidatorForm;
import java.io.Serializable;
import java.lang.System;
import com.install.util.GetGid;
public final class MyFormBean extends ValidatorForm implements Serializable
{
private String ownerGroup = gid();
public String getOwnerGroup() {
return (this.ownerGroup);
}
public void setOwnerGroup(String ownerGroup){
this.ownerGroup = ownerGroup;
}
public String gid() {
System.out.println("Should be returning GID: " +
GetGid.getGid());
return GetGid.getGid();
}
}
Thanks,
Jeremy Weber
jweber@eventra.com
---------------------------------------------------------------------
To unsubscribe, e-mail: struts-user-unsubscribe@jakarta.apache.org
For additional commands, e-mail: struts-user-help@jakarta.apache.org