How to concatenate Macro and String in the other macro?

0 votes
asked Mar 2, 2016 in Wanted features by habdank (420 points)

Dears,

 

I would like to have uService name and stereotype, but u == greek letter micro.

The code below does not work. Do you have some hints?

 

@startuml

!define MICRO <U+00B5>

' !define MICROSERVICE MICRO##Service

 

'component MICROSERVICE as MS << MICROSERVICE >> {

'component MICRO##Service as MS <<MICRO##Service>> {

component uService as MS <<MICRO##Service>> {

}

@enduml

 

Best regards,

Seweryn.

1 Answer

+1 vote
answered Mar 4, 2016 by plantuml (298,440 points)

As workaround, you can have:

@startuml
!define MICRO(foo) <U+00B5>
!define MICROSERVICE MICRO()Service
 
component MICROSERVICE as MS1 << MICROSERVICE >> {
component uService as MS2 <<MICRO()Service>>
}
@enduml

commented Mar 7, 2016 by habdank (420 points)
Thank you very much!
...