public function getFieldNameFromPeer($field_name) { if ($field_name == 'force_stop') { return CuePointPeer::FORCE_STOP; } if ($field_name == 'duration') { return CuePointPeer::DURATION; } return CuePointPeer::translateFieldName($field_name, $this->field_name_translation_type, BasePeer::TYPE_COLNAME); }
/** * Retrieves a field from the object by name passed in as a string. * * @param string $name name * @param string $type The type of fieldname the $name is of: * one of the class type constants BasePeer::TYPE_PHPNAME, BasePeer::TYPE_STUDLYPHPNAME * BasePeer::TYPE_COLNAME, BasePeer::TYPE_FIELDNAME, BasePeer::TYPE_NUM * @return mixed Value of field. */ public function getByName($name, $type = BasePeer::TYPE_PHPNAME) { $pos = CuePointPeer::translateFieldName($name, $type, BasePeer::TYPE_NUM); $field = $this->getByPosition($pos); return $field; }