code: private function createRelation($field, $relation)
      {
          switch ($relation) {
              case self::ONE_TO_ONE_RELATION:
                  return new OneToOneRelation($field);
                  break;
  
              case self::ONE_TO_MANY_RELATION:
                  return new OneToManyRelation($field);
          }
      }
docs: @param string $field
  @param string $relation
  
  @return Relation