Skip to content

Commit

Permalink
temporal
Browse files Browse the repository at this point in the history
  • Loading branch information
wisdompoet committed Dec 18, 2017
1 parent 00e8613 commit 7bc0a83
Show file tree
Hide file tree
Showing 2 changed files with 11 additions and 15 deletions.
20 changes: 7 additions & 13 deletions parser/TemporalAction.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -233,22 +233,16 @@ void TemporalAction::parse( Filereader & f, TokenStruct< std::string > & ts, Dom
f.assert_token( ")" );
}

CondVec TemporalAction::preconsOverall() {
And * a = dynamic_cast< And * >( pre_o );
if ( a ) return a->conds;

CondVec precons;
if ( pre_o ) precons.push_back( pre_o );
return precons;
GroundVec TemporalAction::preconsStart() {
return getGroundsFromCondition( pre, false );
}

CondVec TemporalAction::preconsEnd() {
And * a = dynamic_cast< And * >( pre_e );
if ( a ) return a->conds;
GroundVec TemporalAction::preconsOverall() {
return getGroundsFromCondition( pre_o, false );
}

CondVec precons;
if ( pre_e ) precons.push_back( pre_e );
return precons;
GroundVec TemporalAction::preconsEnd() {
return getGroundsFromCondition( pre_e, false );
}

GroundVec TemporalAction::addEndEffects() {
Expand Down
6 changes: 4 additions & 2 deletions parser/TemporalAction.h
Original file line number Diff line number Diff line change
Expand Up @@ -182,9 +182,11 @@ class TemporalAction : public Action {

void parse( Filereader & f, TokenStruct< std::string > & ts, Domain & d );

CondVec preconsOverall();
GroundVec preconsStart();

CondVec preconsEnd();
GroundVec preconsOverall();

GroundVec preconsEnd();

GroundVec addEndEffects();

Expand Down

0 comments on commit 7bc0a83

Please sign in to comment.