Overview | Package | Class | Use | Tree | Deprecated | Index | Help
PREV CLASS NEXT CLASS | FRAMES NO FRAMES
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD

## org.eclipse.lyo.oslc4j.core
Class OSLC4JUtils

    java.lang.Object
      org.eclipse.lyo.oslc4j.core.OSLC4JUtils

    public class OSLC4JUtils

extends Object

Constructor Summary
`OSLC4JUtils()`

Method Summary
`static String` | `getPublicURI()` Returns the value of org.eclipse.lyo.oslc4j.publicURI or null if not set.
`static boolean` | `isHostResolutionDisabled()` Returns the boolean value of org.eclipse.lyo.oslc4j.disableHostResolution Default is false if not set or invalid (hostname resolution will take place)
`static String` | `resolveURI(javax.servlet.http.HttpServletRequest request, boolean includePath)` Resolve a URI (usually a resource subject or info URI) based on the settings of org.eclipse.lyo.oslc4j.publicURI and org.eclipse.lyo.oslc4j.disableHostResolution.
`static void` | `setHostResolutionDisabled(boolean hostResDisabled)`
`static void` | `setPublicURI(String newPublicURI)` Sets the value of org.eclipse.lyo.oslc4j.publicURI

Methods inherited from class java.lang.Object
`clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait`

Constructor Detail

### OSLC4JUtils

    public OSLC4JUtils()

Method Detail

### getPublicURI

    public static String getPublicURI()

  Returns the value of org.eclipse.lyo.oslc4j.publicURI or null if not set.

  Returns:

### setPublicURI

    public static void setPublicURI(String newPublicURI)
                             throws MalformedURLException

  Sets the value of org.eclipse.lyo.oslc4j.publicURI

  Parameters:
    `publicURI` -
  Throws:
    `MalformedURLException`

### isHostResolutionDisabled

    public static boolean isHostResolutionDisabled()

  Returns the boolean value of org.eclipse.lyo.oslc4j.disableHostResolution Default is false if not set or invalid (hostname resolution will take place)

  Returns:

### setHostResolutionDisabled

    public static void setHostResolutionDisabled(boolean hostResDisabled)

### resolveURI

    public static String resolveURI(javax.servlet.http.HttpServletRequest request,
                                    boolean includePath)

  Resolve a URI (usually a resource subject or info URI) based on the settings of org.eclipse.lyo.oslc4j.publicURI and org.eclipse.lyo.oslc4j.disableHostResolution. If the publicURI property is set, it takes precedence and is used to build the full URI. If the disableHostResolution property is false or not set, resolution of the local hostname is attempted. If the disableHostResolution property is true or resolution has failed, the hostname is retrieved from the request. Query parameters from the request are not copied to the resolved URI.

  Parameters:
    `request` - - request to base resolved URI on
    `includePath` - - if the path (after the context root) should be included in the resolved URI
  Returns:

Overview | Package | Class | Use | Tree | Deprecated | Index | Help
PREV CLASS NEXT CLASS | FRAMES NO FRAMES
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD

Copyright © 2013. All Rights Reserved.