lib/k2hattrop.cc
bool K2hAttrOpsBase::AddAttrOpArray(k2hattroplist_t& attroplist, K2hAttrOpsBase* pattrop)
{
	if(!pattrop){
		ERR_K2HPRN("parameter is wrong.");
		return false;
	}
	for(k2hattroplist_t::const_iterator iter = attroplist.begin(); iter != attroplist.end(); ++iter){
		if((*iter)->VerInfo == pattrop->VerInfo){
			// found same attrop in list
			ERR_K2HPRN("found same attribute operation object(%s) in list.", pattrop->VerInfo.c_str());
			return false;
		}
	}
	attroplist.push_back(pattrop);

	return true;
}
//---------------------------------------------------------
// K2hAttrOpsBase Class Methods
//---------------------------------------------------------
//
// Add always to lastest in list.
//
K2hAttrOpsBase Class Methods
Add always to lastest in list.
K2hAttrOpsBase Class Methods Add always to lastest in list .
bool K2hAttrOpsBase::AddAttrOpArray(k2hattroplist_t& attroplist, K2hAttrOpsBase* pattrop)
{
	if(!pattrop){
		ERR_K2HPRN("parameter is wrong.");
		return false;
	}
	for(k2hattroplist_t::const_iterator iter = attroplist.begin(); iter != attroplist.end(); ++iter){
		if((*iter)->VerInfo == pattrop->VerInfo){
			ERR_K2HPRN("found same attribute operation object(%s) in list.", pattrop->VerInfo.c_str());
			return false;
		}
	}
	attroplist.push_back(pattrop);
	return true;
}
bool K2hAttrOpsBase :: AddAttrOpArray ( k2hattroplist_t & attroplist , K2hAttrOpsBase * pattrop ) { if ( ! pattrop ) { ERR_K2HPRN ( " " ) ; return false ; } for ( k2hattroplist_t :: const_iterator iter = attroplist . begin ( ) ; iter != attroplist . end ( ) ; ++ iter ) { if ( ( * iter ) -> VerInfo == pattrop -> VerInfo ) { ERR_K2HPRN ( " " , pattrop -> VerInfo . c_str ( ) ) ; return false ; } } attroplist . push_back ( pattrop ) ; return true ; }
K2hAttrOpsBase Class Methods
Add always to lastest in list.
K2hAttrOpsBase Class Methods Add always to lastest in list .
// found same attrop in list