CIdentifier { @Nullable public static String createPercentDecoded (@Nullable final String sURL) { return URLHelper.urlDecodeOrNull (sURL); } private  CIdentifier(); @Nonnull @Nonempty static String getURIEncoded(@Nonnull final IIdentifier aID); @Nonnull @Nonempty static String getURIEncoded(@Nonnull final ParticipantIdentifierType aID); @Nonnull @Nonempty static String getURIEncoded(@Nonnull final DocumentIdentifierType aID); @Nonnull @Nonempty static String getURIEncoded(@Nonnull final ProcessIdentifierType aID); @Nonnull @Nonempty static String getURIEncoded(@Nonnull final com.helger.xsds.bdxr.smp1.ParticipantIdentifierType aID); @Nonnull @Nonempty static String getURIEncoded(@Nonnull final com.helger.xsds.bdxr.smp1.DocumentIdentifierType aID); @Nonnull @Nonempty static String getURIEncoded(@Nonnull final com.helger.xsds.bdxr.smp1.ProcessIdentifierType aID); @Nonnull @Nonempty static String getURIEncoded(@Nonnull final com.helger.xsds.ccts.cct.schemamodule.IdentifierType aID); @Nonnull @Nonempty static String getURIEncoded(@Nullable final String sScheme, @Nullable final String sValue); @Nullable static String createPercentEncoded(@Nullable final String sURL); @Nullable static String createPercentDecoded(@Nullable final String sURL); @Nonnull static String getURIPercentEncoded(@Nonnull final IIdentifier aID); @Nonnull static String getURIPercentEncoded(@Nonnull final ParticipantIdentifierType aID); @Nonnull static String getURIPercentEncoded(@Nonnull final DocumentIdentifierType aID); @Nonnull static String getURIPercentEncoded(@Nonnull final ProcessIdentifierType aID); @Nonnull static String getURIPercentEncoded(@Nonnull final com.helger.xsds.bdxr.smp1.ParticipantIdentifierType aID); @Nonnull static String getURIPercentEncoded(@Nonnull final com.helger.xsds.bdxr.smp1.DocumentIdentifierType aID); @Nonnull static String getURIPercentEncoded(@Nonnull final com.helger.xsds.bdxr.smp1.ProcessIdentifierType aID); @Nonnull @Nonempty static String getURIPercentEncoded(@Nonnull final com.helger.xsds.ccts.cct.schemamodule.IdentifierType aID); @Nonnull static String getURIPercentEncoded(@Nullable final String sScheme, @Nullable final String sValue); static final String DEFAULT_PROCESS_IDENTIFIER_NOPROCESS; static final String URL_SCHEME_VALUE_SEPARATOR; static final ClassPathResource XSD_PEPPOL_IDENTIFIERS; static final String NS_URI_PEPPOL_IDENTIFIERS; }
@Test public void testCreatePercentDecodedURL () { assertNull (CIdentifier.createPercentDecoded (null)); assertEquals ("", CIdentifier.createPercentDecoded ("")); assertEquals ("abc", CIdentifier.createPercentDecoded ("abc")); assertEquals (":", CIdentifier.createPercentDecoded ("%3A")); assertEquals ("::", CIdentifier.createPercentDecoded ("%3A%3a")); assertEquals ("a%b", CIdentifier.createPercentDecoded ("a%25b")); assertEquals ("a%%b", CIdentifier.createPercentDecoded ("a%25%25b")); assertEquals ("a/b", CIdentifier.createPercentDecoded ("a%2Fb")); assertEquals ("äöü", CIdentifier.createPercentDecoded ("äöü")); }