convert string to object?
convert string to object?
- Subject: convert string to object?
- From: "Janice M. Cheung" <email@hidden>
- Date: Mon, 01 Dec 2003 12:48:42 -0500
Hi there,
Is there a simple function to convert a string to an object?
I am attempting to use something like this for outputting PDFs in
WebObjects, so that
any selections from a dropdown menu (String type) will create those
selected Objects
in a report:
Here is one of my functions to change selected String values into
objects of type Department:
public java.lang.String toObject(){
String currentDept;
currentDept = toObject();
return currentDept;
}
I've also tried to set string types in Search.java and set them in
Session.java to type Department, to
no avail:
--- Search.java
String m_currentDept;
s.setCurrentDepartment(m_currentDept);
(basically I want "currentDept" to be converted to type Department)
--- Session.java
public Department currentDepartment(String currentDept){
return currentDepartment;
}
public Department getCurrentDepartment(String currentDept){
return currentDepartment;
}
public void setCurrentDepartment(Department newCurrentDepartment){
currentDepartment=newCurrentDepartment;
}
These string values are retrieved as qualifiers from the database...
any advice or guidance
would be greatly appreciated!!
Thanks very much!
Happy Happy Holidays!
Janice
_______________________________________________
webobjects-dev mailing list | email@hidden
Help/Unsubscribe/Archives: http://www.lists.apple.com/mailman/listinfo/webobjects-dev
Do not post admin requests to the list. They will be ignored.