Skip to content

Commit 4a684c1

Browse files
committed
Docs WIP
1 parent d6cdfd5 commit 4a684c1

File tree

3 files changed

+26
-8
lines changed

3 files changed

+26
-8
lines changed
Lines changed: 25 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,27 @@
11
# Getting Started
22

3-
Composer install.. etc.. and other stuff.
3+
:::warning
4+
#### REQUIREMENTS
5+
\>= PHP 7.1
6+
7+
Windows and the `com_dotnet` extension enabled (available in every [`Windows PHP`](https://windows.php.net/download/) release).
8+
:::
9+
10+
## Install
11+
```sh
12+
composer require phpwintools/wmi-scripting
13+
```
14+
15+
## Configuration
16+
17+
### Static call on Win32Model class
18+
```php
19+
$connection1 = Connection::defaultNamespace('computer-one', 'administrator', 'administrator_password');
20+
$connection2 = Connection::defaultNamespace('computer-two', 'administrator', 'administrator_password');
21+
22+
// Returns an instance of Query\Builder
23+
$builder1 = LoggedOnUser::query($connection1);
24+
25+
// Returns all logged on users in an instance of ModelCollection
26+
$builder1->get();
27+
```

docs/documentation/readme.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -16,4 +16,4 @@ The current wish list consists of at least the following:
1616

1717
* Near 100% test coverage
1818
* Expand testing system
19-
* Event System
19+
* Event system

docs/readme.md

Lines changed: 0 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -47,9 +47,6 @@ composer require phpwintools/wmi-scripting
4747
### Connections with instantiation
4848

4949
```php
50-
use PhpWinTools\WmiScripting\Scripting;
51-
use PhpWinTools\WmiScripting\Connection;
52-
5350
$scripting = new Scripting;
5451

5552
// These connections can be called by name.
@@ -68,8 +65,5 @@ $scripting->query()->loggedOnUser()->get();
6865
### Connections with static calls
6966

7067
```php
71-
use PhpWinTools\WmiScripting\Connection;
72-
PhpWinTools\WmiScripting\Models\LoggedOnUser;
73-
7468
LoggedOnUser::query(Connection::defaultNamespace('server1', 'user', 'password'))->get();
7569
```

0 commit comments

Comments
 (0)