| Author |
struts beans
|
Harshani Wickramarathna
Greenhorn
Joined: Nov 15, 2007
Posts: 28
|
|
Hi, I've got this code from tutorial. But I couldn't try it because it says the method randomString undefined. Can you please help me on this. package coreservlets; import java.util.*; public class SuggestionUtils { private static String[] suggestedAddresses = { "president@whitehouse.gov", "gates@microsoft.com", "palmisano@ibm.com", "ellison@oracle.com"}; private static String chars = "abcdefghijklmnopqrstuvwxyz0123456789#@$%^&*?!"; public static SuggestionBean getSuggestionBean() { String address = randomString(suggestedAddresses); String password = randomString(chars, 8); return(new SuggestionBean(address, password)); } }
|
 |
xu yuanzhi
Greenhorn
Joined: Nov 20, 2007
Posts: 6
|
|
|
The method 'randomString' is in the same class. Tutorial may haven't attached its codes
|
 |
 |
|
|
subject: struts beans
|
|
|