GDS\Schema::addString PHP Method

addString() public method

Add a string field to the schema
public addString ( $str_name, boolean $bol_index = TRUE ) : Schema
$str_name
$bol_index boolean
return Schema
    public function addString($str_name, $bol_index = TRUE)
    {
        return $this->addProperty($str_name, self::PROPERTY_STRING, $bol_index);
    }

Usage Example

 public function __construct()
 {
     $schema = new Schema('Credential');
     $schema->addString('email');
     $schema->addString('service');
     $schema->addString('value', false);
     $this->store = new Store($schema);
     $this->store->setEntityClass(Credential::class);
 }
All Usage Examples Of GDS\Schema::addString