com.nimbusds.openid.connect.sdk.util
Class Resource

java.lang.Object
  extended by com.nimbusds.openid.connect.sdk.util.Resource

@Immutable
public final class Resource
extends Object

Resource with optional associated content type. This class is immutable.

Author:
Vladimir Dzhuvinov

Constructor Summary
Resource(String content, javax.mail.internet.ContentType contentType)
          Creates a new resource with optional associated content type.
 
Method Summary
 String getContent()
          Gets the content of this resource.
 javax.mail.internet.ContentType getContentType()
          Gets the content type of this resource.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

Resource

public Resource(String content,
                javax.mail.internet.ContentType contentType)
Creates a new resource with optional associated content type.

Parameters:
content - The resource content, empty string if none. Must not be null.
contentType - The resource content type, null if not specified.
Method Detail

getContent

public String getContent()
Gets the content of this resource.

Returns:
The content, empty string if none.

getContentType

public javax.mail.internet.ContentType getContentType()
Gets the content type of this resource.

Returns:
The content type, null if not specified.


Copyright © 2013 NimbusDS. All Rights Reserved.