public String toDisplayString(){
  if (origin_server != null)   resolveWeak();
  if (domainName != null) {
    String str;
    if (type == SID_TYPE_DOMAIN) {
      str=domainName;
    }
 else     if (type == SID_TYPE_WKN_GRP || domainName.equals("BUILTIN")) {
      if (type == SID_TYPE_UNKNOWN) {
        str=toString();
      }
 else {
        str=acctName;
      }
    }
 else {
      str=domainName + "\\" + acctName;
    }
    return str;
  }
  return toString();
}

public String toDisplayString ( ) { if ( origin_server != null ) resolveWeak ( ) ; if ( domainName != null ) { String str ; if ( type == SID_TYPE_DOMAIN ) { str = domainName ; } else if ( type == SID_TYPE_WKN_GRP || domainName . equals ( "BUILTIN" ) ) { if ( type == SID_TYPE_UNKNOWN ) { str = toString ( ) ; } else { str = acctName ; } } else { str = domainName + "\\" + acctName ; } return str ; } return toString ( ) ; }
return a string representing this sid ideal for display to users . this method should return the same text that the acl editor in windows would display . < p > specifically , if the sid has been resolved and it is not a domain sid or builtin account , the full domain \ name form of the account will be returned ( e . g . mydom \ alice or mydom \ domain users ) . if the sid has been resolved but it is is a domain sid , only the domain name will be returned ( e . g . mydom ) . if the sid has been resolved but it is a builtin account , only the name component will be returned ( e . g . system ) . if the sid cannot be resolved the numeric representation from tostring ( ) is returned .
