Skip to content
GitLab
Explore
Sign in
Primary navigation
Search or go to…
Project
T
TeeTime-Framework
Manage
Activity
Members
Labels
Plan
Issues
Issue boards
Milestones
Wiki
Code
Merge requests
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Build
Pipelines
Jobs
Pipeline schedules
Artifacts
Deploy
Releases
Model registry
Operate
Environments
Monitor
Incidents
Analyze
Value stream analytics
Contributor analytics
CI/CD analytics
Repository analytics
Model experiments
Help
Help
Support
GitLab documentation
Compare GitLab plans
Community forum
Contribute to GitLab
Provide feedback
Terms and privacy
Keyboard shortcuts
?
Snippets
Groups
Projects
Show more breadcrumbs
Nelson Tavares de Sousa
TeeTime-Framework
Commits
41e1a7d8
Commit
41e1a7d8
authored
10 years ago
by
Nelson Tavares de Sousa
Browse files
Options
Downloads
Patches
Plain Diff
enhanched classes
parent
b4caff33
No related branches found
No related tags found
No related merge requests found
Changes
2
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
src/main/java/teetime/framework/StageException.java
+7
-1
7 additions, 1 deletion
src/main/java/teetime/framework/StageException.java
src/main/java/teetime/framework/StageExceptionListener.java
+22
-1
22 additions, 1 deletion
src/main/java/teetime/framework/StageExceptionListener.java
with
29 additions
and
2 deletions
src/main/java/teetime/framework/StageException.java
+
7
−
1
View file @
41e1a7d8
...
...
@@ -12,12 +12,18 @@ public class StageException extends Exception {
private
static
final
long
serialVersionUID
=
6724637605943897808L
;
private
final
Stage
throwingStage
;
private
final
Exception
originalException
;
public
StageException
(
final
Stage
throwingStage
)
{
public
StageException
(
final
Exception
e
,
final
Stage
throwingStage
)
{
super
();
this
.
originalException
=
e
;
this
.
throwingStage
=
throwingStage
;
}
public
Exception
getOriginalException
()
{
return
originalException
;
}
/**
* Returns the stage, which failed with an uncatched exception
*
...
...
This diff is collapsed.
Click to expand it.
src/main/java/teetime/framework/StageExceptionListener.java
+
22
−
1
View file @
41e1a7d8
package
teetime.framework
;
/**
* Represent a minimalistic StageExceptionListener. Listener which extend from this one, must a least implement this functionality.
*
*/
public
abstract
class
StageExceptionListener
{
private
final
Thread
thread
;
...
...
@@ -8,6 +12,23 @@ public abstract class StageExceptionListener {
this
.
thread
=
thread
;
}
public
abstract
void
onStageException
(
Stage
throwingStage
);
/**
* This method will be executed if an exception arises.
*
* @param e
* thrown exception
* @param throwingStage
* the stage, which has thrown the exception.
*/
public
abstract
void
onStageException
(
Exception
e
,
Stage
throwingStage
);
/**
* Retrieves the thread in which the exception occurred.
*
* @return exception throwing thread
*/
public
Thread
getThread
()
{
return
thread
;
}
}
This diff is collapsed.
Click to expand it.
Preview
0%
Loading
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Save comment
Cancel
Please
register
or
sign in
to comment