Thank you all!
Using the API Javadocs i've created the user yesterday but your example it's
really useful (and cleaner than my code).

Luca

2007/10/16, Steynberg, Calman <[EMAIL PROTECTED]>:
>
> The code below shows how to create an user using the 7.1 API, but it
> should not be too hard porting it back to the 7.0 API.
>
> Calman
>
> import com.bmc.arsys.api.ARServerUser;
> import com.bmc.arsys.api.Constants;
> import com.bmc.arsys.api.DataType;
> import com.bmc.arsys.api.Entry;
> import com.bmc.arsys.api.Value;
>
> public class UserExample {
>
>     public static void main(String[] args) throws Exception {
>
>         ARServerUser context = new ARServerUser("Demo", "", "",
> "localhost");
>         context.login();
>
>         Entry userEntry = new Entry();
>         // set the login name
>         userEntry.put(Constants.AR_RESERV_USER_NAME, new
> Value("sampleuser"));
>         // set the full name
>         userEntry.put(Constants.AR_CORE_SHORT_DESCRIPTION, new
> Value("Sample User"));
>         // set the group list (make the user an administrator)
>         userEntry.put(Constants.AR_RESERV_GROUP_LIST, new Value("1;"));
>         // set the license type
>         userEntry.put(Constants.AR_RESERV_LICENSE_TYPE, new
> Value(Constants.AR_LICENSE_TAG_WRITE, DataType.ENUM));
>         // set the full text
>         userEntry.put(Constants.AR_RESERV_LIC_FULL_TEXT, new Value(0,
> DataType.ENUM));
>         // set the submitter
>         userEntry.put(Constants.AR_CORE_SUBMITTER, new Value("2"));
>         // set the status
>         userEntry.put(Constants.AR_CORE_STATUS, new Value(0,
> DataType.ENUM));
>         // set the password
>         userEntry.put(Constants.AR_RESERV_PASSWORD, new
> Value("password"));
>         // set the email
>         userEntry.put(Constants.AR_RESERV_EMAIL, new
> Value("[EMAIL PROTECTED]"));
>
>         context.createEntry("User", userEntry);
>
>         context.logout();
>
>     }
> }
>
> -----Original Message-----
> From: Action Request System discussion list(ARSList)
> [mailto:[EMAIL PROTECTED] On Behalf Of Luca Bacco
> Sent: Tuesday, October 16, 2007 2:40 AM
> To: [email protected]
> Subject: JAVA API
>
> Hi,
>
> I'm trying to use JAVA API (7.0) to automatically create users in
> Remedy becouse I need to "reconcile" the users of another application
> (I need to create the same users in Remedy...)
> First of all I didn't found a valid documentation to the api so if you
> know about some docs, please report me.
> If i've understand I need:
>
> 1) Create a connection to the Remedy server (this seems to work)
> 2) Create an entry for a schema (in my case users form)
>
> It's correct? Can you provide some example?
>
> Thank you all,
>
> Luca
> syrry for double post
>
> ________________________________________________________________________
> _______
> UNSUBSCRIBE or access ARSlist Archives at www.arslist.org ARSlist:"Where
> the Answers Are"
>
>
> _______________________________________________________________________________
> UNSUBSCRIBE or access ARSlist Archives at www.arslist.org ARSlist:"Where
> the Answers Are"
>

_______________________________________________________________________________
UNSUBSCRIBE or access ARSlist Archives at www.arslist.org ARSlist:"Where the 
Answers Are"

Reply via email to