def _perform_type_validation(self, path, typ, value, results):
        """
        Validates a given value to match specified type.
        The type can be defined as a Schema, type, a type name or [[TypeCode]].
        When type is a Schema, it executes validation recursively against that Schema.

        :param path: a dot notation path to the value.

        :param typ: a type to match the value type

        :param value: a value to be validated.

        :param results: a list with validation results to add new results.
        """
        # If type it not defined then skip
        if typ == None:
            return

        # Perform validation against schema
        if isinstance(typ, Schema):
            schema = typ
            schema._perform_validation(path, value, results)
            return

        # If value is null then skip
        value = ObjectReader.get_value(value)
        if value == None:
            return

        name = path if path != None else "value"
        value_type = type(value)

        # Match types
        if TypeMatcher.match_type(typ, value_type):
            return
        
        # Generate type mismatch error
        results.append(
            ValidationResult(
                path,
                ValidationResultType.Error,
                "TYPE_MISMATCH",
                name + " type must be " + self._type_to_string(typ) + " but found " + self._type_to_string(value_type),
                typ,
                value_type
            )
        )