fr.paris.lutece.plugins.blobstoreclient.util
Class UrlUtils

java.lang.Object
  extended by fr.paris.lutece.plugins.blobstoreclient.util.UrlUtils

public final class UrlUtils
extends java.lang.Object

URLUtils


Method Summary
static java.lang.String buildCreateBlobUrl(java.lang.String strBaseUrl, java.lang.String strBlobStore)
          Build the url to upload a file.
static java.lang.String buildDeleteBlobUrl(java.lang.String strBaseUrl)
          Build the url to delete a file.
static java.lang.String buildFileUrl(java.lang.String strBaseUrl, java.lang.String strBlobStore, java.lang.String strBlobKey)
          Build the url to get a file url.
static java.lang.String getBlobKeyFromUrl(java.lang.String strUrl)
          Get the blob key from the url
static java.lang.String getBlobStoreFromUrl(java.lang.String strUrl)
          Get the blobstore service name from the url
static java.lang.String getParameterValue(java.lang.String strUrl, java.lang.String strParameter)
          Extract the parameter value from the url
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Method Detail

buildCreateBlobUrl

public static java.lang.String buildCreateBlobUrl(java.lang.String strBaseUrl,
                                                  java.lang.String strBlobStore)
Build the url to upload a file.
This will append the url defined in blobstoreclient.properties to the given base url

Parameters:
strBaseUrl - the base url
strBlobStore - the blobstore service name
Returns:
the url to upload a file

buildDeleteBlobUrl

public static java.lang.String buildDeleteBlobUrl(java.lang.String strBaseUrl)
Build the url to delete a file.
This will append the url defined in blobstoreclient.properties to the given base url

Parameters:
strBaseUrl - the base url
Returns:
the url to delete a file

buildFileUrl

public static java.lang.String buildFileUrl(java.lang.String strBaseUrl,
                                            java.lang.String strBlobStore,
                                            java.lang.String strBlobKey)
Build the url to get a file url.
This will append the url defined in blobstoreclient.properties to the given base url

Parameters:
strBaseUrl - the base url
strBlobStore - the blobstore service name
strBlobKey - the blob key
Returns:
the url to delete a file

getParameterValue

public static java.lang.String getParameterValue(java.lang.String strUrl,
                                                 java.lang.String strParameter)
Extract the parameter value from the url

Parameters:
strUrl - the url
strParameter - the parameter
Returns:
the parameter value

getBlobStoreFromUrl

public static java.lang.String getBlobStoreFromUrl(java.lang.String strUrl)
Get the blobstore service name from the url

Parameters:
strUrl - the url
Returns:
the blobstore service name

getBlobKeyFromUrl

public static java.lang.String getBlobKeyFromUrl(java.lang.String strUrl)
Get the blob key from the url

Parameters:
strUrl - the url
Returns:
the blob key


Copyright © 2012 Mairie de Paris. All Rights Reserved.