# WHMCS\Billing\VAT\VatNumber

`Class`

## Methods

### factoryFromIdentifier

```php
public static function factoryFromIdentifier(string $identifier): self
```

**Parameters**

| Type | Name | Description |
|  --- | --- | --- |
| `string` | `$identifier` |  |


**Returns** `static`

### factoryFromInput

```php
public static function factoryFromInput(string $input): self
```

Create new instance, normalizing input prior to instantiation

**Parameters**

| Type | Name | Description |
|  --- | --- | --- |
| `string` | `$input` |  |


**Returns** `static`

### getIdentifier

```php
public function getIdentifier(): string
```

Full string representation of a VAT number

**Returns** `string`

### getPrefix

```php
public function getPrefix(): string
```

(country) prefix related to the VAT number.

WHMCS has a legacy that UK VAT number may or may not have the GB prefix.

**Returns** `string`

### getNumber

```php
public function getNumber(): string
```

The number portion of the VAT number (ie, sans any prefix). Note while
by convention this is named a number, there may be alpha characters
present.

**Returns** `string`

### isUK

```php
public function isUK(): bool
```

Should the VAT number be treated as belonging to a UK business entity

**Returns** `bool`

### isEU

```php
public function isEU(): bool
```

Should the VAT number be treated as belonging to a country in the EEA

**Returns** `bool`

### isValid

```php
public function isValid(): bool
```