    import {PublicKey} from '@solana/web3'

public class | source

# PublicKey

You can directly use an instance of this class. SYSTEM_TOKEN_PROGRAM_ID VALIDATOR_INFO_KEY VOTE_ACCOUNT_KEY

A public key

## Static Method Summary

Static Public Methods
public static | isPublicKey(o: Object): boolean Checks if the provided object is a PublicKey |

## Constructor Summary

Public Constructor
public | constructor(value: number | string | Buffer | Array<number>) Create a new PublicKey object |

## Method Summary

Public Methods
public | equals(publicKey: PublicKey): boolean Checks if two publicKeys are equal |
public | toBase58(): string Return the base-58 representation of the public key |
public | toBuffer(): Buffer Return the Buffer representation of the public key |
public | toString(): string Returns a string representation of the public key |

## Static Public Methods

### public static isPublicKey(o: Object): boolean source

Checks if the provided object is a PublicKey

#### Params:

Name | Type | Attribute | Description
o | Object |  |

#### Return:

boolean

## Public Constructors

### public constructor(value: number | string | Buffer | Array<number>) source

Create a new PublicKey object

#### Params:

Name | Type | Attribute | Description
value | number | string | Buffer | Array<number> |  |

## Public Methods

### public equals(publicKey: PublicKey): boolean source

Checks if two publicKeys are equal

#### Params:

Name | Type | Attribute | Description
publicKey | PublicKey |  |

#### Return:

boolean

### public toBase58(): string source

Return the base-58 representation of the public key

#### Return:

string

### public toBuffer(): Buffer source

Return the Buffer representation of the public key

#### Return:

Buffer

### public toString(): string source

Returns a string representation of the public key

#### Return:

string