TokyoTyrant::setMaster

Set the replication master

&reftitle.description; public `mixed` `TokyoTyrant::setMaster` `string` `host` `int` `port` `int` `timestamp` `bool` `check_consistency` true

Sets the replication master of the database

This method is not supported on 32bit platforms.

&reftitle.parameters;

`host`

- Hostname of the replication master. If &null; the replication is disabled.

`port`

- Port of the replication master

`timestamp`

- Beginning timestamp with microseconds

`check_consistency`

- Whether to check consistency.

&reftitle.returnvalues;

This method returns the current object and throws TokyoTyrantException on failure.

&reftitle.examples;

### `TokyoTyrant::setMaster` example

    <?php
    /* Connect to a database */
    $tt = new TokyoTyrant("tokyotyrant.example.com");

    /* Disable the replication */
    $tt->setMaster(NULL, 0, 0);
    ?>

&reftitle.seealso;

- `Classname::Method`