<commit_before>Thepixeldeveloper\Sitemap
=========================

[![Author](http://img.shields.io/badge/author-@colonelrosa-blue.svg?style=flat-square)](https://twitter.com/colonelrosa)
[![Build Status](https://img.shields.io/travis/ThePixelDeveloper/Sitemap-v2/master.svg?style=flat-square)](https://travis-ci.org/ThePixelDeveloper/Sitemap-v2)
[![Software License](https://img.shields.io/badge/license-MIT-brightgreen.svg?style=flat-square)](LICENSE)
[![Packagist Version](https://img.shields.io/packagist/v/thepixeldeveloper/sitemap.svg?style=flat-square)](https://packagist.org/packages/thepixeldeveloper/sitemap)
[![Total Downloads](https://img.shields.io/packagist/dt/thepixeldeveloper/sitemap.svg?style=flat-square)](https://packagist.org/packages/thepixeldeveloper/sitemap)

A tool to generate XML sitemaps

Usage
-----

Generating a _urlset_ sitemap

``` php

$urlSet = new Thepixeldeveloper\Sitemap\Urlset(); 

foreach ($entities as $entity) {
  $urlSet->addUrl(
      new Thepixeldeveloper\Sitemap\Url(
          $loc,
          $lastMod,
          $changeFreq,
          $priority
      )
  );
}
```

Generating a _sitemapindex_ sitemap


``` php

$sitemapIndex = new Thepixeldeveloper\Sitemap\SitemapIndex(); 

foreach ($entities as $entity) {
  $sitemapIndex->addUrl(
      new Thepixeldeveloper\Sitemap\Sitemap(
          $loc,
          $lastMod
      )
  );
}
```

Then pass either SitemapIndex or Urlset to a Formatter to generate output


``` php

$formatter = new Thepixeldeveloper\Sitemap\Formatter();

$output = $formatter->format($sitemapIndex);

echo $output;

```
<commit_msg>Update README whitespace.<commit_after>Thepixeldeveloper\Sitemap
=========================

[![Author](http://img.shields.io/badge/author-@colonelrosa-blue.svg?style=flat-square)](https://twitter.com/colonelrosa)
[![Build Status](https://img.shields.io/travis/ThePixelDeveloper/Sitemap-v2/master.svg?style=flat-square)](https://travis-ci.org/ThePixelDeveloper/Sitemap-v2)
[![Software License](https://img.shields.io/badge/license-MIT-brightgreen.svg?style=flat-square)](LICENSE)
[![Packagist Version](https://img.shields.io/packagist/v/thepixeldeveloper/sitemap.svg?style=flat-square)](https://packagist.org/packages/thepixeldeveloper/sitemap)
[![Total Downloads](https://img.shields.io/packagist/dt/thepixeldeveloper/sitemap.svg?style=flat-square)](https://packagist.org/packages/thepixeldeveloper/sitemap)

A tool to generate XML sitemaps

Usage
-----

Generating a _urlset_ sitemap

``` php

$urlSet = new Thepixeldeveloper\Sitemap\Urlset(); 

foreach ($entities as $entity) {
  $urlSet->addUrl(
      new Thepixeldeveloper\Sitemap\Url(
          $loc,
          $lastMod,
          $changeFreq,
          $priority
      )
  );
}
```

Generating a _sitemapindex_ sitemap


``` php

$sitemapIndex = new Thepixeldeveloper\Sitemap\SitemapIndex(); 

foreach ($entities as $entity) {
  $sitemapIndex->addUrl(
      new Thepixeldeveloper\Sitemap\Sitemap(
          $loc,
          $lastMod
      )
  );
}
```

Then pass either SitemapIndex or Urlset to a Formatter to generate output


``` php
$formatter = new Thepixeldeveloper\Sitemap\Formatter();

echo $formatter->format($sitemapIndex);
```

{'fraction_non_alphanumeric': 0.16489361702127658, 'fraction_numerical': 0.0012515644555694619, 'mean_word_length': 4.364093959731544, 'pattern_counts': {'":': 0, '<': 3, '<?xml version=': 0, '>': 9, 'https://': 16, 'lorem ipsum': 0, 'www.': 0, 'xml': 0}, 'pii_count': 2, 'substrings_counts': 0, 'word_list_counts': {'cursed_substrings.json': 6, 'profanity_word_list.json': 0, 'sexual_word_list.json': 0, 'zh_pornsignals.json': 0}}
{'dir': 'git-commits-cleaned', 'id': '3152974', 'n_tokens_mistral': 1171, 'n_tokens_neox': 1092, 'n_words': 146}