예제 #1
0
파일: ItemTest.php 프로젝트: sqrt-pro/db
 function testMakeNames()
 {
     $this->assertEquals('getHelloThere', \SQRT\DB\Item::MakeGetterName('hello_there'), 'Геттер');
     $this->assertEquals('setHelloThere', \SQRT\DB\Item::MakeSetterName('hello_there'), 'Сеттер');
 }
예제 #2
0
파일: Schema.php 프로젝트: sqrt-pro/db
 protected function makeItemSetter($col)
 {
     return "  /** @return static */\n" . "  public function " . Item::MakeSetterName($col) . "(\${$col})\n" . "  {\n" . "    return \$this->set('{$col}', \${$col});\n" . "  }";
 }