Changeset 911
- Timestamp:
- 09/12/07 11:54:49 (1 year ago)
- Files:
Legend:
- Unmodified
- Added
- Removed
- Modified
- Copied
- Moved
trunk/src/main/php/net/stubbles/rdbms/persistence/stubPersistenceHelper.php
r907 r911 27 27 { 28 28 /** 29 * list of forbidden methods 30 * 31 * @var array<string> 32 */ 33 protected $forbiddenMethods = array('getClass', 34 'getPackage', 35 'getClassName', 36 'getPackageName', 37 'getSerialized' 38 ); 39 40 /** 29 41 * helper method to create the correct table definition 30 42 * … … 54 66 protected function getTableColumn(stubReflectionMethod $method) 55 67 { 56 if ($method->isStatic() === true || $method->isPublic() === false || $method->hasAnnotation('Transient') === true) { 68 if ($method->isStatic() === true || $method->isPublic() === false 69 || in_array($method->getName(), $this->forbiddenMethods) === true 70 || $method->hasAnnotation('Transient') === true) { 57 71 return null; 58 72 } … … 60 74 if ($method->hasAnnotation('DBColumn') === true) { 61 75 $column = $method->getAnnotation('DBColumn')->getTableColumn(); 62 } elseif (substr($method->getName(), 0, 3) !== 'get') { 63 return null; 64 } elseif (in_array($method->getDeclaringClass()->getName(), array('stubBaseObject', 'stubSerializableObject'))) { 76 } elseif (substr($method->getName(), 0, 3) !== 'get' && substr($method->getName(), 0, 2) !== 'is') { 65 77 return null; 66 78 } else {
