Make sure that class has all necessary static properties set.
767520
private static function checkStaticProperties()
    {
        static $checkedClasses = [];
        if (!in_array(static::class, $checkedClasses)) {
            if (empty(static::$dbTableName)
                || empty(static::$dbProperties)
                || empty(static::$primaryDbPropertyKey)
                || (is_scalar(static::$primaryDbPropertyKey)
                    && !isset(static::$dbProperties[static::$primaryDbPropertyKey]['type']))
                || (is_array(static::$primaryDbPropertyKey)
                    && !Arr::allIn(static::$primaryDbPropertyKey, array_keys(static::$dbProperties)))
            ) {
                throw new \LogicException("All db entity's static properties not set");
            }
            $checkedClasses[] = static::class;
        }
    }
845952
private static void initializePropertiesIfNeeded() {
        if (translationResources != null) {
            return;
        }
        String lastException = "";
        try {
            translationResources = new Properties();
            ClassLoader classLoader = ClassLoader.getSystemClassLoader();
            translationResources.load(classLoader.getResourceAsStream(
                    propertiesFileName));
        } catch (Exception exception) {
            lastException = exception.toString() + "\n----\n" + exception.getMessage();
        }
        if (translationResources == null) {
            throw new RuntimeException("TranslationSource.initializePropertiesIfNeeded()"
                    + "Could not load TranslationResources.properties file.\n"
                    + "The exception follows:\n" + lastException);
        }
    }
808301
protected static function initialize()
    {
        $class = static::class;

        if (static::$constants === null) {
            static::$constants = (new \ReflectionClass($class))->getConstants();

            foreach (static::names() as $name) {
                static::$lcKeyMap[strtolower($name)] = $name;
            }
        }
    }
703010
public static <B> BeanPropertyAccessor<B> forClass(Class<B> clazz) {
        return forClass(clazz, PropertySet.ALL);
    }
1190685
public function setClassProperties() {

      /********************************************/
      /*     Nouvelle méthode de déclaration      */
      /********************************************/
      // Modèle par défaut : Classe XClassProperty : array('name' => '', 'type' => '', 'defaultValue' => '', 'value' => '');
  		$this->property(array('name' => 'property1', 'type' => '', 'defaultValue' => 'world', 'value' => ''));  // Propriété complète
      $this->property(array('name' => 'property2', 'type' => 'string'));                                      // Propriété avec type 'string'
      $this->property(array('name' => 'property3', 'type' => 'integer'));                                     // Propriété avec type 'integer'
      $this->property(array('name' => 'property4', 'type' => 'array'));                                       // Propriété avec type 'array'
      $this->property(array('name' => 'property5', 'type' => 'boolean'));                                     // Propriété avec type 'boolean'
      $this->property(array('name' => 'property6'));                                                          // Propriété avec un simple nom

      /********************************************/
      /*  /!\           OBSOLETE             /!\  */
      /*      Ancienne méthode de déclaration     */
      /********************************************/
      // Modèle par défaut :   $name, $type, $db_location, $with_form, $restrictions = array(), $form_components = array()
      $this->property('oldProperty', 'string', '', '', array(), array());                                     // Propriété complète
      $this->property('oldProperty2');                                                                        // Propriété avec un simple nom
      $this->property('oldProperty3',  'boolean');                                                            // Propriété avec type 'boolean'

  	}
371822
private static function initModelProperties()
    {
        $currentModel = static::class;

        if (isset(self::$modelProperties[$currentModel])) {
            return;
        }

        $properties = [
            'connection'  => ConnectionFactory::build(static::$connection),
            'dateFields'  => static::$dates ?: [],
            'fields'      => static::$fields ?: [],
            'primaryKeys' => (array) static::$primaryKey,
            'table'       => static::$table,
            'timestamps'  => (bool) static::$timestamps,
        ];

        if ($properties['timestamps']) {
            $properties['fields'][] = 'created_at';
            $properties['fields'][] = 'updated_at';
            $properties['dateFields'][] = 'created_at';
            $properties['dateFields'][] = 'updated_at';
        }

        self::$modelProperties[$currentModel] = $properties;
    }
1295272
function addStatics(statics, Subclass) {

  // static method inheritance (including `extend`)
  Object.keys(statics).forEach(function(key) {
    var descriptor = Object.getOwnPropertyDescriptor(statics, key);
    if (!descriptor.configurable) return;

    Object.defineProperty(Subclass, key, descriptor);
  });
}
1099799
public static final Set<String> getProperties(Class<?> cls)
    {
        if (cls.isPrimitive() || cls.isAnnotation() || cls.isEnum() || String.class.equals(cls))
        {
            return Collections.EMPTY_SET;
        }
        NavigableSet<String> set = setFor(cls);
        Method[] methods = cls.getMethods();
        for (Method method : methods)
        {
            if ((method.getModifiers() & ModifierMask) == 0)
            {
                String name = method.getName();
                if ((name.startsWith("get") || name.startsWith("is"))
                        && method.getParameterCount() == 0)
                {
                    String property = getProperty(method);
                    Class<?> returnType = method.getReturnType();
                    if (
                            returnType.isArray() ||
                            List.class.isAssignableFrom(returnType)
                            )
                    {
                        set.add(property);
                    }
                    else
                    {
                        if (hasMethod(methods, setter(property)))
                        {
                            set.add(property);
                        }
                    }
                }
            }
        }
        for (Field field : cls.getFields())
        {
            if ((field.getModifiers() & ModifierMask) == 0)
            {
                set.add(field.getName());
            }
        }
        return set;
    }
1273058
function() {

		var resultClasses = this._static_classes.clone(),
			name,
			value;

		for (name in this._class_bindings) {

			// do not need to check or convert, cause join() will convert everything to string, and nulls to empty string
			resultClasses.push(
				this._class_bindings[name].getValue()
			);

		}

		value = resultClasses.join(' ');

		if (Lava.schema.view.VALIDATE_CLASS_NAMES) {
			this.assertClassStringValid(value);
		}

		return value;

	}
316134
public function getStaticProperties()
    {
        if ($this->staticProperties === null) {
            // lazy load class properties list
            foreach ($this->node->stmts as $stmt) {
                if ($stmt instanceof Node\Stmt\Property) {
                    if ($stmt->isStatic() === false) {
                        continue;
                    }
                    foreach ($stmt->props as $prop) {
                        $this->staticProperties[] = new PropertyModel($this, $prop);
                    }
                }
            }
        }
        return $this->staticProperties;
    }
863432
protected function checkRequirements()
    {
        $required_properties = array('_buildFile');
        foreach ($required_properties as $required_property) {
            if (empty($this->$required_property)) {
                throw new \BuildException(
                    "Missing required property '" . $required_property . "'."
                );
            }
        }
    }
255596
private boolean checkSupertypes(Class<?> cls) {
    for(Class<?> c : knownParameterizables) {
      if(c.isAssignableFrom(cls)) {
        return true;
      }
    }
    return false;
  }
975544
public static function has($value)
    {
        if ($value instanceof static && get_class($value) === get_called_class()) {
            return true;
        }
        $class = get_called_class();
        $constants = static::detectConstants($class);
        return in_array($value, $constants, true);
    }
1068766
def _build_static_validator(exact_value):
    """"""

    def static_validator(data):
        """Validate by equality."""
        if data == exact_value:
            return data

        raise NotValid('%r is not equal to %r' % (data, exact_value))

    return static_validator
1345690
private void checkInvalidClassProperty(String className, String propertyName) {
        if (className != null && propertyName != null) {
            boolean isInvalidCombination = walkInvalidList(className, propertyName, invalidClassProperty);
            if (isInvalidCombination) {
                Tr.error(tc, "DYNA0050E", new Object[] { "'" + propertyName + "'", "'" + className + "'" });
                Tr.error(tc, "dynacache.configerror" /* DYNA0022E */
                         , new Object[] { filename });
            }
        }
    }
858928
def validate(self):
        """"""
        if not (isinstance(self.target_class, set) and
                all(isinstance(x, six.string_types) for x in self.target_class)):
            raise TypeError(u'Expected set of string target_class, got: {} {}'.format(
                type(self.target_class).__name__, self.target_class))

        for cls in self.target_class:
            validate_safe_string(cls)
885126
def validate_prop(value):
    """"""
    if (
            isinstance(value, CLASS_TYPES) and
            issubclass(value, HasProperties)
    ):
        value = Instance('', value)
    if not isinstance(value, basic.Property):
        raise TypeError('Contained prop must be a Property instance or '
                        'HasProperties class')
    if value.default is not utils.undefined:
        warn('Contained prop default ignored: {}'.format(value.default),
             RuntimeWarning)
    return value