org.aspsimon.termcomp.entity
Class LPProblem

java.lang.Object
  extended by org.aspsimon.termcomp.entity.LPProblem
All Implemented Interfaces:
TPInterface

Deprecated. since Version 1.0.2

public class LPProblem
extends java.lang.Object
implements TPInterface

Represents a Logic Programming problem for use in the competition. This class implements the generic TPInterface which ensures that a lot of code can be used generically, regardless of whether it is working with TRSProblems, SRSProblems or FPProblems. Logic Programs in the TPDB are in Prolog. This class is replaced by LPProgram which fits in the TerminationProblem inheritance hierarchy.

Version:
$Revision: 111 $
Author:
binabik

Constructor Summary
LPProblem()
          Deprecated.  
 
Method Summary
 User getApprovedBy()
          Deprecated. Get the User with database administrative rights who approved this termination problem.
 java.lang.Long getLpId()
          Deprecated. Get the unique identifier for this LPProblem.
 java.lang.String getOriginalFileName()
          Deprecated. Get the original filename of this Termination Problem where it is stored under /opt/competition/tpdb/.
 java.lang.String getProgram()
          Deprecated. Get the full text of the Prolog program.
 java.lang.String getQuery()
          Deprecated. Get the query which this program should be checked for.
 User getSubmittedBy()
          Deprecated. Get the User who submitted this termination problem.
 java.sql.Timestamp getSubmittedDate()
          Deprecated. Set the date and time this termination problem was originally submitted to the TPDB.
 java.lang.Long getTPId()
          Deprecated. Get the unique identifier for this Termination Problem.
 java.lang.String getType()
          Deprecated. Get the type of Termination Problem we are working with.
 boolean isApproved()
          Deprecated. Determine whether this termination problem is approved for public consumption.
 boolean isRejected()
          Deprecated. Determines whether this termination problem passed the review process or not.
 boolean isSecret()
          Deprecated. Return the secret status of this problem.
 void prepersist()
          Deprecated. Hibernate lifecycle convenience method.
 void setApproved(boolean approved)
          Deprecated. Set the approval status of this problem.
 void setApprovedBy(User approvedBy)
          Deprecated. Set the User with administrative rights who approved this problem.
 void setLpId(java.lang.Long lpId)
          Deprecated. Set the unique identifier for this LPProblem.
 void setOriginalFileName(java.lang.String originalFileName)
          Deprecated. Set the original filename of this Termination Problem
 void setProgram(java.lang.String program)
          Deprecated. Set the Prolog program for this Logic Programming problem.
 void setQuery(java.lang.String query)
          Deprecated. Set the query to be checked in this problem.
 void setRejected(boolean rejected)
          Deprecated. Set the rejected status of this problem.
 void setSecret(boolean secret)
          Deprecated. Set the secret status of this problem.
 void setSubmittedBy(User submittedBy)
          Deprecated. Set the User who submitted this problem.
 void setSubmittedDate(java.sql.Timestamp submittedDate)
          Deprecated. Set the date this problem was submitted to the TPDB.
 
Methods inherited from class java.lang.Object
equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

LPProblem

public LPProblem()
Deprecated. 
Method Detail

getLpId

public java.lang.Long getLpId()
Deprecated. 
Get the unique identifier for this LPProblem.

Returns:
A DB-generated identifier for internally referencing this LPProblem. Globally unique.

getOriginalFileName

public java.lang.String getOriginalFileName()
Deprecated. 
Get the original filename of this Termination Problem where it is stored under /opt/competition/tpdb/.

Specified by:
getOriginalFileName in interface TPInterface
Returns:
A path relative to /opt/competition/tpdb/.

getProgram

public java.lang.String getProgram()
Deprecated. 
Get the full text of the Prolog program. It has to be annotated as a @Lob in order for the database to not truncate it.

Returns:
The full source content of the original problem.

getQuery

public java.lang.String getQuery()
Deprecated. 
Get the query which this program should be checked for. May also contain the special string NO QUERY — these problems are ignored during a competition.

Returns:
The query in Prolog syntax.

isApproved

public boolean isApproved()
Deprecated. 
Determine whether this termination problem is approved for public consumption. Currently ignored.

Specified by:
isApproved in interface TPInterface
Returns:
A boolean value.

isRejected

public boolean isRejected()
Deprecated. 
Determines whether this termination problem passed the review process or not. Currently ignored.

Specified by:
isRejected in interface TPInterface
Returns:
A boolean value, default is false.

isSecret

public boolean isSecret()
Deprecated. 
Return the secret status of this problem.

Specified by:
isSecret in interface TPInterface
Returns:
Whether this problem is secret or not.

getSubmittedBy

public User getSubmittedBy()
Deprecated. 
Get the User who submitted this termination problem.

Specified by:
getSubmittedBy in interface TPInterface
Returns:
The User who submitted this problem.

getApprovedBy

public User getApprovedBy()
Deprecated. 
Get the User with database administrative rights who approved this termination problem. Currently unused.

Specified by:
getApprovedBy in interface TPInterface
Returns:
The User who approved this problem

getSubmittedDate

public java.sql.Timestamp getSubmittedDate()
Deprecated. 
Set the date and time this termination problem was originally submitted to the TPDB.

Specified by:
getSubmittedDate in interface TPInterface
Returns:
The date and time this problem was submitted.

setLpId

public void setLpId(java.lang.Long lpId)
Deprecated. 
Set the unique identifier for this LPProblem. Must be globally unique, otherwise the database will complain heavily. There is normally no need to actually use this call in normal programming.

Parameters:
lpId - The globally unique identifier for this LPProblem.

setOriginalFileName

public void setOriginalFileName(java.lang.String originalFileName)
Deprecated. 
Set the original filename of this Termination Problem

Specified by:
setOriginalFileName in interface TPInterface
Parameters:
originalFileName - The file name relative to /opt/competition/tpdb/.

setProgram

public void setProgram(java.lang.String program)
Deprecated. 
Set the Prolog program for this Logic Programming problem.

Parameters:
program - The source code of the Prolog program.

setQuery

public void setQuery(java.lang.String query)
Deprecated. 
Set the query to be checked in this problem.

Parameters:
query - The query which must be checked.

setApproved

public void setApproved(boolean approved)
Deprecated. 
Set the approval status of this problem. Currently unused.

Specified by:
setApproved in interface TPInterface
Parameters:
approved - A boolean value.

setRejected

public void setRejected(boolean rejected)
Deprecated. 
Set the rejected status of this problem. Currently unused.

Specified by:
setRejected in interface TPInterface
Parameters:
rejected - A boolean value.

setSecret

public void setSecret(boolean secret)
Deprecated. 
Set the secret status of this problem.

Specified by:
setSecret in interface TPInterface
Parameters:
secret - A boolean value representing whether this problem is secret or not.

setSubmittedBy

public void setSubmittedBy(User submittedBy)
Deprecated. 
Set the User who submitted this problem.

Specified by:
setSubmittedBy in interface TPInterface
Parameters:
submittedBy - The User who submitted the problem.

setApprovedBy

public void setApprovedBy(User approvedBy)
Deprecated. 
Set the User with administrative rights who approved this problem.

Specified by:
setApprovedBy in interface TPInterface
Parameters:
approvedBy - The User who approved this problem.

setSubmittedDate

public void setSubmittedDate(java.sql.Timestamp submittedDate)
Deprecated. 
Set the date this problem was submitted to the TPDB.

Specified by:
setSubmittedDate in interface TPInterface
Parameters:
submittedDate - The time and date this problem was originally submitted.

prepersist

public void prepersist()
Deprecated. 
Hibernate lifecycle convenience method.


getTPId

public java.lang.Long getTPId()
Deprecated. 
Get the unique identifier for this Termination Problem. As Hibernate maintains a single sequence for all managed database objects, this is guaranteed to be globally unique as long as the object was created through a hibernate session.

Specified by:
getTPId in interface TPInterface
Returns:
A DB-generated identifier for internally referencing this Termination Problem.

getType

public java.lang.String getType()
Deprecated. 
Get the type of Termination Problem we are working with. Can currently be one of the following:
TRS
Term Rewriting System TRSProblem
SRS
String Rewriting System SRSProblem
FP
Functional Program FPProblem
LP
Logic Program LPProblem

Specified by:
getType in interface TPInterface
Returns:
"LP"