Добавил:
Studfiles2
Опубликованный материал нарушает ваши авторские права? Сообщите нам.
Вуз:
Предмет:
Файл:Лабораторная работа 15 / templ / TriangleEntity
.cpp/********************************************************************************/
#include "TriangleEntity.h"
#include <iostream>
/********************************************************************************/
CTriangleEntity::CTriangleEntity( const int iB, const int iH,
const int iX, const int iY )
:CPointEntity( iX,iY )
{
setBase( iB );
setHeight( iH );
}
/********************************************************************************/
CTriangleEntity::~CTriangleEntity()
{
}
/********************************************************************************/
int CTriangleEntity::getBase() const
{
return mBase;
}
/********************************************************************************/
int CTriangleEntity::getHeight() const
{
return mHeight;
}
/********************************************************************************/
void CTriangleEntity::setBase( int iB )
{
mBase = iB;
}
/********************************************************************************/
void CTriangleEntity::setHeight( int iH )
{
mHeight = iH;
}
/********************************************************************************/
void CTriangleEntity::Printfig(std::ostream& os)
{
os << "Triangle:" <<std::endl;
os << " X=" << mX<<std::endl;
os << " Y=" << mY<<std::endl;
os << " B=" << mBase<<std::endl;
os << " H=" << mHeight<<std::endl;
}
/********************************************************************************/
Соседние файлы в папке templ