HTML-MyHTML

 view release on metacpan or  search on metacpan

README.md  view on Meta::CPAN


Return: HTML::MyHTML::String if exists, otherwise an NULL value

### wait_for_done

Wait for process token all parsing stage. Need if you use thread mode

```perl
 $token_node->wait_for_done();
```

## Detect encoding

### encoding_detect

Detect character encoding.

Now available for detect UTF-8, UTF-16LE, UTF-16BE and Russians: windows-1251,  koi8-r, iso-8859-5, x-mac-cyrillic, ibm866. Other in progress

```perl
 # $text[in] text
 # $out_encoding[out] detected encoding
 
 my $bool = $myhtml->encoding_detect($text, $out_encoding);
```

Return: 1 (true) if encoding found, otherwise 0 (false)

### encoding_detect_russian

Detect Russian character encoding

Now available for detect windows-1251,  koi8-r, iso-8859-5, x-mac-cyrillic, ibm866

```perl
 # $text[in] text
 # $out_encoding[out] detected encoding
 
 my $bool = $myhtml->encoding_detect_russian($text, $out_encoding);
```

Return: 1 (true) if encoding found, otherwise 0 (false)

### encoding_detect_unicode

Detect Unicode character encoding

Now available for detect UTF-8, UTF-16LE, UTF-16BE

```perl
 # $text[in] text
 # $out_encoding[out] detected encoding
 
 my $bool = $myhtml->encoding_detect_unicode($text, $out_encoding);
```

Return: 1 (true) if encoding found, otherwise 0 (false)

### encoding_detect_bom

Detect Unicode character encoding by BOM

Now available for detect UTF-8, UTF-16LE, UTF-16BE

```perl
 # $text[in] text
 # $out_encoding[out] detected encoding
 
 my $bool = $myhtml->encoding_detect_bom($text, $out_encoding);
```

Return: 1 (true) if encoding found, otherwise 0 (false)


## Incoming Buffer

### find_by_position

Get Incoming Buffer by position

```perl
 my $incoming_buffer = $incoming_buffer->find_by_position($begin_position);
```

Return: HTML::Incoming::Buffer if successful, otherwise a UNDEF value

### data

Get data of Incoming Buffer

```perl
 my $data = $incoming_buffer->data();
```

Return: text scalar if successful, otherwise a UNDEF value

### length

Get data length of Incoming Buffer

```perl
 my $length = $incoming_buffer->length();
```

Return: scalar length

### size

Get data size of Incoming Buffer

```perl
 my $size = $incoming_buffer->size();
```

Return: scalar size

### offset

Get data offset of Incoming Buffer. Global position of begin Incoming Buffer.

```perl



( run in 0.747 second using v1.01-cache-2.11-cpan-140bd7fdf52 )