cancel
Showing results for 
Search instead for 
Did you mean: 

Convert UUID

emmanuel_turci
Advisor
Advisor
0 Kudos

Hi All,

In ABAP there is a class: CL_GDT_CONVERSION + method GUID_INBOUND or GUID_OUTBOUND which allows converting UUID.

Convert a UUID from ABAP internal format to ISO 11578 / IETF Draft format

UUID string format example: "f81d4fae-7dec-11d0-a765-00a0c91e6bf6"

I try to find the same method in the Java world for WD, any idea if such method exist somewhere ?

Thanks in advance and best regards, Emmanuel.

Accepted Solutions (1)

Accepted Solutions (1)

Former Member
0 Kudos

Hi,

Use UUID.toString();

http://java.sun.com/j2se/1.5.0/docs/api/java/util/UUID.html

Regards

Ayyapparaj

emmanuel_turci
Advisor
Advisor
0 Kudos

Hi Ayyapparaj,

one question, to use the toString method in that case I need to create one instance of UUID

my problem here is that I received a string like : 4C7C6000A4A911DCB03F00300571C976 which I need to transform into 4c7...-...-...-

Thanks for your help and best regards, Emmanue.

Former Member
0 Kudos

Hi,

Did you tried this method

static UUID fromString(String name)

Regards

Ayyapparaj

emmanuel_turci
Advisor
Advisor
0 Kudos

Hi,

yes and get this :

Invalid UUID string: 4C7C6000A4A911DCB03F00300571C976

what I understand is If I use this class I need to create a new instance

means by using this : UUID(long mostSigBits,long leastSigBits) and in that case ...which value ?

Regards, Emmanuel.

Answers (1)

Answers (1)

emmanuel_turci
Advisor
Advisor
0 Kudos

done for myself