aboutsummaryrefslogtreecommitdiff
path: root/src/target.cpp
blob: 8f4cc4bdd036b47c0c9a7d8e1a913f1016ae8711 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
#include "target.h"

Target::Target( const char *sName ) :
	sName( sName )
{
}

Target::~Target()
{
}

void Target::setRule( const char *sRule )
{
	this->sRule = sRule;
}

void Target::debug()
{
	printf("   %s:\n      Rule: %s\n",
		sName.getString(),
		sRule.getString()
		);
	printf("      Input list:\n");
	for( std::list<std::string>::iterator i = lInput.begin();
		 i != lInput.end(); i++ )
	{
		printf("         %s\n", (*i).c_str() );
	}
	printf("      Output list:\n");
	for( std::list<std::string>::iterator i = lOutput.begin();
		 i != lOutput.end(); i++ )
	{
		printf("         %s\n", (*i).c_str() );
	}
}

void Target::addInput( const char *sInput )
{
	lInput.push_back( sInput );
}

void Target::addOutput( const char *sOutput )
{
	lOutput.push_back( sOutput );
}