src/Registry.php
private function aliasDefault($name)
    {
        $spec = sprintf('\Underscore\Mutator\%sMutator', ucfirst($name));

        if (!class_exists($spec)) {
            $spec = sprintf('\Underscore\Accessor\%sAccessor', ucfirst($name));
        }

        if (!class_exists($spec)) {
            $spec = sprintf('\Underscore\Initializer\%sInitializer', ucfirst($name));
        }

        if (!class_exists($spec)) {
            throw new \BadMethodCallException(sprintf('Unknown method Underscore->%s()', $name));
        }

        $this->aliases[$name] = $spec;
    }
private function aliasDefault($name)
    {
        $spec = sprintf('\Underscore\Mutator\%sMutator', ucfirst($name));

        if (!class_exists($spec)) {
            $spec = sprintf('\Underscore\Accessor\%sAccessor', ucfirst($name));
        }

        if (!class_exists($spec)) {
            $spec = sprintf('\Underscore\Initializer\%sInitializer', ucfirst($name));
        }

        if (!class_exists($spec)) {
            throw new \BadMethodCallException(sprintf('Unknown method Underscore->%s()', $name));
        }

        $this->aliases[$name] = $spec;
    }
private function aliasDefault ( $ name ) { $ spec = sprintf ( '\Underscore\Mutator\%sMutator' , ucfirst ( $ name ) ) ; if ( ! class_exists ( $ spec ) ) { $ spec = sprintf ( '\Underscore\Accessor\%sAccessor' , ucfirst ( $ name ) ) ; } if ( ! class_exists ( $ spec ) ) { $ spec = sprintf ( '\Underscore\Initializer\%sInitializer' , ucfirst ( $ name ) ) ; } if ( ! class_exists ( $ spec ) ) { throw new \ BadMethodCallException ( sprintf ( 'Unknown method Underscore->%s()' , $ name ) ) ; } $ this -> aliases [ $ name ] = $ spec ; }
Define a default mutator, accessor, or initializer for a method name.

@throws \BadMethodCallException If no default can be located.
@param  string $name
@return void
Define a default mutator accessor or initializer for a method name .