# jc-importer/2.15.0/class/Common/Util/Singleton.php

Import WP – CSV &amp; XML Import Export for WordPress, version 2.15.0. 18 lines.

- Page: https://pluginprobe.com/plugins/jc-importer/2.15.0/code/class/Common/Util/Singleton.php
- Raw: https://pluginprobe.com/plugins/jc-importer/2.15.0/raw/class/Common/Util/Singleton.php
- Modified: 2020-09-22T19:27:48+00:00

Line numbers below start at 1. Link to a line or a range by appending a fragment to the
page URL, for example `https://pluginprobe.com/plugins/jc-importer/2.15.0/code/class/Common/Util/Singleton.php#L10-L20`.

```php
<?php

namespace ImportWP\Common\Util;

trait Singleton
{
    private static $instance;

    public static function getInstance()
    {
        if (!(self::$instance instanceof self)) {
            self::$instance = new self;
        }

        return self::$instance;
    }
}

```
