public String getDomainName ( ) { DomainModel model = ( ( IIntDomainAccess ) this . domainAccess ) . getInternalDomainAccess ( ) . getDomainModel ( ) ; StringWriter sw = new StringWriter ( ) ; JsonGenerator generator ; if ( this . prettyFormat != Format . NONE ) { JsonGeneratorFactory gf = JSONWriter . getPrettyGeneratorFactory ( ) ; generator = gf . createGenerator ( sw ) ; } else generator = Json . createGenerator ( sw ) ; generator . writeStartObject ( ) ; generator . write ( "domainName" , model . getDomainName ( ) ) ; generator . writeEnd ( ) ; generator . flush ( ) ; return sw . toString ( ) ; }
Answer a JSON object containing the domain name