Skip to content
GitLab
Projects
Groups
Snippets
Help
Loading...
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
C
core-pdp-api
Project overview
Project overview
Details
Activity
Releases
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Issues
1
Issues
1
List
Boards
Labels
Service Desk
Milestones
Merge Requests
0
Merge Requests
0
Operations
Operations
Incidents
Analytics
Analytics
Repository
Value Stream
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Commits
Issue Boards
Open sidebar
authzforce
core-pdp-api
Commits
8a9fccef
Commit
8a9fccef
authored
Feb 17, 2018
by
cdanger
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Fixed error messages
parent
c7186c3b
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
7 additions
and
13 deletions
+7
-13
src/main/java/org/ow2/authzforce/core/pdp/api/func/BaseFunction.java
...va/org/ow2/authzforce/core/pdp/api/func/BaseFunction.java
+7
-13
No files found.
src/main/java/org/ow2/authzforce/core/pdp/api/func/BaseFunction.java
View file @
8a9fccef
...
...
@@ -36,26 +36,23 @@ public abstract class BaseFunction<RETURN_T extends Value> implements Function<R
private
transient
volatile
int
hashCode
=
0
;
// Effective Java - Item 9
@Override
public
final
String
getId
()
{
public
final
String
getId
()
{
return
this
.
functionId
;
}
protected
BaseFunction
(
final
String
functionId
)
{
this
.
functionId
=
functionId
;
this
.
indeterminateArgMessagePrefix
=
"Function
"
+
functionId
+
"
: Indeterminate arg #"
;
this
.
indeterminateArgMessagePrefix
=
"Function
'"
+
functionId
+
"'
: Indeterminate arg #"
;
}
@Override
public
final
String
toString
()
{
public
final
String
toString
()
{
return
this
.
functionId
;
}
@Override
public
final
int
hashCode
()
{
public
final
int
hashCode
()
{
if
(
hashCode
==
0
)
{
hashCode
=
this
.
functionId
.
hashCode
();
...
...
@@ -64,8 +61,7 @@ public abstract class BaseFunction<RETURN_T extends Value> implements Function<R
}
@Override
public
final
boolean
equals
(
final
Object
obj
)
{
public
final
boolean
equals
(
final
Object
obj
)
{
if
(
this
==
obj
)
{
return
true
;
...
...
@@ -88,8 +84,7 @@ public abstract class BaseFunction<RETURN_T extends Value> implements Function<R
* function argument index (#x) that could not be determined
* @return "Indeterminate arg#x" exception
*/
public
final
String
getIndeterminateArgMessage
(
final
int
argIndex
)
{
public
final
String
getIndeterminateArgMessage
(
final
int
argIndex
)
{
return
indeterminateArgMessagePrefix
+
argIndex
;
}
...
...
@@ -100,8 +95,7 @@ public abstract class BaseFunction<RETURN_T extends Value> implements Function<R
* function argument index (#x) that could not be determined
* @return "Indeterminate arg#x" exception
*/
public
final
IndeterminateEvaluationException
getIndeterminateArgException
(
final
int
argIndex
)
{
public
final
IndeterminateEvaluationException
getIndeterminateArgException
(
final
int
argIndex
)
{
return
new
IndeterminateEvaluationException
(
getIndeterminateArgMessage
(
argIndex
),
XacmlStatusCode
.
PROCESSING_ERROR
.
value
());
}
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
.
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment