org.glassfish.jersey.server.model
Class ResourceModelIssue

java.lang.Object
  extended by org.glassfish.jersey.server.model.ResourceModelIssue

public final class ResourceModelIssue
extends Object

Resource model validity issue. Covers various model issues, such as duplicate URI templates, duplicate HTTP method annotations, etc.

The model issues can be either fatal or non-fatal (see isFatal()). While the non-fatal issues are merely reported as warnings in the log, the fatal issues prevent the successful application deployment.

Author:
Jakub Podlesak (jakub.podlesak at oracle.com), Marek Potociar (marek.potociar at oracle.com)

Constructor Summary
ResourceModelIssue(Object source, String message)
          Create a new non-fatal resource model issue.
ResourceModelIssue(Object source, String message, boolean isFatal)
          Create a new resource model issue.
 
Method Summary
 boolean equals(Object obj)
           
 String getMessage()
          Human-readable description of the issue.
 Object getSource()
          The issue source.
 int hashCode()
           
 boolean isFatal()
          Check if the issue is fatal.
 String toString()
           
 
Methods inherited from class java.lang.Object
clone, finalize, getClass, notify, notifyAll, wait, wait, wait
 

Constructor Detail

ResourceModelIssue

public ResourceModelIssue(Object source,
                          String message)
Create a new non-fatal resource model issue.

Parameters:
source - issue source.
message - human-readable issue description.

ResourceModelIssue

public ResourceModelIssue(Object source,
                          String message,
                          boolean isFatal)
Create a new resource model issue.

Parameters:
source - issue source.
message - human-readable issue description.
isFatal - true if the issue is fatal, false otherwise.
Method Detail

getMessage

public String getMessage()
Human-readable description of the issue.

Returns:
message describing the issue.

isFatal

public boolean isFatal()
Check if the issue is fatal. Fatal issues typically prevent the deployment of the application to succeed.

Returns:
true if the issue is fatal, false otherwise.

getSource

public Object getSource()
The issue source. Identifies the object where the issue was found.

Returns:
source of the issue.

toString

public String toString()
Overrides:
toString in class Object

equals

public boolean equals(Object obj)
Overrides:
equals in class Object

hashCode

public int hashCode()
Overrides:
hashCode in class Object


Copyright © 2007-2012 Oracle Corporation. All Rights Reserved. Use is subject to license terms.