public function init($argument = false, $multiple = false)
    {
        if (!empty($argument)) {
            return new ArgumentTypeAbstract(
                ($multiple === true) ? $this->makeMultiple($this->getArguments()) : $this->getArguments(),
                $this->getName(),
                $this->getDescription(),
                $multiple
            );
        }

        return new FieldAbstract(
            ($multiple === true) ? new ListType($this->getFields()) : $this->getFields(),
            $this->getName(),
            $this->getDescription()
        );
    }
public function init($argument = false, $multiple = false)
    {
        if (!empty($argument)) {
            return new ArgumentTypeAbstract(
                ($multiple === true) ? $this->makeMultiple($this->getArguments()) : $this->getArguments(),
                $this->getName(),
                $this->getDescription(),
                $multiple
            );
        }

        return new FieldAbstract(
            ($multiple === true) ? new ListType($this->getFields()) : $this->getFields(),
            $this->getName(),
            $this->getDescription()
        );
    }
public function init ( $ argument = false , $ multiple = false ) { if ( ! empty ( $ argument ) ) { return new ArgumentTypeAbstract ( ( $ multiple === true ) ? $ this -> makeMultiple ( $ this -> getArguments ( ) ) : $ this -> getArguments ( ) , $ this -> getName ( ) , $ this -> getDescription ( ) , $ multiple ) ; } return new FieldAbstract ( ( $ multiple === true ) ? new ListType ( $ this -> getFields ( ) ) : $ this -> getFields ( ) , $ this -> getName ( ) , $ this -> getDescription ( ) ) ; }
Create an object depends on is argument required

@param bool $argument
@return ArgumentTypeAbstract|FieldAbstract
@throws \Youshido\GraphQL\Exception\ConfigurationException
Create an object depends on is argument required