dap4/d4lib/src/main/java/dap4/dap4lib/XURI.java
static public String
    canonical(String s)
    {
        if(s != null) {
            s = s.trim();
            if(s.length() == 0)
                s = null;
        }
        return s;
    }
static public String
    canonical(String s)
    {
        if(s != null) {
            s = s.trim();
            if(s.length() == 0)
                s = null;
        }
        return s;
    }
static public String canonical ( String s ) { if ( s != null ) { s = s . trim ( ) ; if ( s . length ( ) == 0 ) s = null ; } return s ; }
Canonicalize a part of a URL

@param s part of the url
Canonicalize a part of a URL