Browse Source

Updated read me

Joachim M. Giæver 4 years ago
parent
commit
8d3d01b6ed
1 changed files with 132 additions and 11 deletions
  1. 132 11
      README.md

+ 132 - 11
README.md

@@ -1,5 +1,5 @@
 
-Sami Markdown Extension
+Yr Forecast
 ===
 
 # Table of content    
@@ -10,12 +10,13 @@ Sami Markdown Extension
 			2. [Tabular](#appyrforecasttabular "App\Yr\Forecast\Tabular")
 				1. [Time](#appyrforecasttabulartime "App\Yr\Forecast\Tabular\Time")
 					1. [AbstractUnit](#abstractunit-appyrforecasttabulartime "App\Yr\Forecast\Tabular\Time\AbstractUnit") Time-object entity should inherit this
-					2. [DiffInterface](#diffinterface-appyrforecasttabulartime "App\Yr\Forecast\Tabular\Time\DiffInterface") Defines that an entity can be checked for differencesagains another entity.
-					3. [Pressure](#pressure-appyrforecasttabulartime "App\Yr\Forecast\Tabular\Time\Pressure") Airpressure
-					4. [Symbol](#symbol-appyrforecasttabulartime "App\Yr\Forecast\Tabular\Time\Symbol") Contains the sky data, e.g «Clody» etc
-					5. [Temperature](#temperature-appyrforecasttabulartime "App\Yr\Forecast\Tabular\Time\Temperature") Temperature
-					6. [WindDirection](#winddirection-appyrforecasttabulartime "App\Yr\Forecast\Tabular\Time\WindDirection") Wind direction
-					7. [WindSpeed](#windspeed-appyrforecasttabulartime "App\Yr\Forecast\Tabular\Time\WindSpeed") Wind speed
+					2. [CustomUnit](#customunit-appyrforecasttabulartime "App\Yr\Forecast\Tabular\Time\CustomUnit")
+					3. [DiffInterface](#diffinterface-appyrforecasttabulartime "App\Yr\Forecast\Tabular\Time\DiffInterface") Defines that an entity can be checked for differencesagains another entity.
+					4. [Pressure](#pressure-appyrforecasttabulartime "App\Yr\Forecast\Tabular\Time\Pressure") Airpressure
+					5. [Symbol](#symbol-appyrforecasttabulartime "App\Yr\Forecast\Tabular\Time\Symbol") Contains the sky data, e.g «Clody» etc
+					6. [Temperature](#temperature-appyrforecasttabulartime "App\Yr\Forecast\Tabular\Time\Temperature") Temperature
+					7. [WindDirection](#winddirection-appyrforecasttabulartime "App\Yr\Forecast\Tabular\Time\WindDirection") Wind direction
+					8. [WindSpeed](#windspeed-appyrforecasttabulartime "App\Yr\Forecast\Tabular\Time\WindSpeed") Wind speed
 				2. [Statistics](#statistics-appyrforecasttabular "App\Yr\Forecast\Tabular\Statistics") Make simple statistic on analysed time objects,such as highest/lowest wind speed and temperature,average wind speed and temperature etc.
 				3. [Time](#time-appyrforecasttabular "App\Yr\Forecast\Tabular\Time") Forecast data witin a time period
 				4. [Variations](#variations-appyrforecasttabular "App\Yr\Forecast\Tabular\Variations") Removes superfluous forecast data in an Time-objectonly storing changes.
@@ -416,6 +417,8 @@ average wind speed and temperature etc.
 |:---|:---|:---|:---|
 |[__construct](#__construct-appyrforecasttabularstatistics)||public| |
 |[analyse](#analyse-appyrforecasttabularstatistics)|[Statistics](#statistics-appyrforecasttabular)|public| Analyse a single Time-object|
+|[getAverageTemperature](#getaveragetemperature-appyrforecasttabularstatistics)|[AbstractUnit](#abstractunit-appyrforecasttabulartime)|public| |
+|[getAverageWindSpeed](#getaveragewindspeed-appyrforecasttabularstatistics)|[AbstractUnit](#abstractunit-appyrforecasttabulartime)|public| |
 
 #### Method details
 
@@ -444,6 +447,26 @@ Returns: [Statistics](#statistics-appyrforecasttabular)
 ---
 
 
+##### getAverageTemperature `App\Yr\Forecast\Tabular\Statistics`
+```php
+public function getAverageTemperature();
+```
+
+Returns: [AbstractUnit](#abstractunit-appyrforecasttabulartime)
+
+---
+
+
+##### getAverageWindSpeed `App\Yr\Forecast\Tabular\Statistics`
+```php
+public function getAverageWindSpeed();
+```
+
+Returns: [AbstractUnit](#abstractunit-appyrforecasttabulartime)
+
+---
+
+
 ### Time `App\Yr\Forecast\Tabular`
 
 
@@ -663,6 +686,10 @@ Time-object entity should inherit this
 |Name|Return|Access|Description|
 |:---|:---|:---|:---|
 |[__construct](#__construct-appyrforecasttabulartimeabstractunit)||public| |
+|[transformClass](#transformclass-appyrforecasttabulartimeabstractunit)|[AbstractUnit](#abstractunit-appyrforecasttabulartime)|protected| |
+|[add](#add-appyrforecasttabulartimeabstractunit)|[AbstractUnit](#abstractunit-appyrforecasttabulartime)|public| Addition method|
+|[mul](#mul-appyrforecasttabulartimeabstractunit)|[AbstractUnit](#abstractunit-appyrforecasttabulartime)|public| Multiplication method|
+|[div](#div-appyrforecasttabulartimeabstractunit)|[AbstractUnit](#abstractunit-appyrforecasttabulartime)|public| Divide method|
 |[getValue](#getvalue-appyrforecasttabulartimeabstractunit)|float|public| Get the value|
 |[getUnit](#getunit-appyrforecasttabulartimeabstractunit)|string|public| Return the unit (e.g «degree»)|
 |[diff](#diff-appyrforecasttabulartimeabstractunit)|int|public| Check for differences with another DiffInterface.|
@@ -684,6 +711,76 @@ Parameters
 ---
 
 
+##### transformClass `App\Yr\Forecast\Tabular\Time\AbstractUnit`
+```php
+protected function transformClass(CustomUnit $cu);
+```
+
+Parameters
+
+| Type | Variable | Description |
+|---|---|---|
+|[CustomUnit](#time-appyrforecasttabular)|$cu|*None*|
+
+Returns: [AbstractUnit](#abstractunit-appyrforecasttabulartime)
+
+---
+
+
+##### add `App\Yr\Forecast\Tabular\Time\AbstractUnit`
+```php
+public function add(AbstractUnit $with);
+```
+ Addition method
+
+
+Parameters
+
+| Type | Variable | Description |
+|---|---|---|
+|[AbstractUnit](#time-appyrforecasttabular)|$with|Unit to add with|
+
+Returns: [AbstractUnit](#abstractunit-appyrforecasttabulartime)
+
+---
+
+
+##### mul `App\Yr\Forecast\Tabular\Time\AbstractUnit`
+```php
+public function mul(AbstractUnit $with);
+```
+ Multiplication method
+
+
+Parameters
+
+| Type | Variable | Description |
+|---|---|---|
+|[AbstractUnit](#time-appyrforecasttabular)|$with|Unit to multiply with|
+
+Returns: [AbstractUnit](#abstractunit-appyrforecasttabulartime)
+
+---
+
+
+##### div `App\Yr\Forecast\Tabular\Time\AbstractUnit`
+```php
+public function div(AbstractUnit $with);
+```
+ Divide method
+
+
+Parameters
+
+| Type | Variable | Description |
+|---|---|---|
+|[AbstractUnit](#time-appyrforecasttabular)|$with|Unit to divide with|
+
+Returns: [AbstractUnit](#abstractunit-appyrforecasttabulartime)
+
+---
+
+
 ##### getValue `App\Yr\Forecast\Tabular\Time\AbstractUnit`
 ```php
 public function getValue();
@@ -738,6 +835,13 @@ Returns: string
 ---
 
 
+### CustomUnit `App\Yr\Forecast\Tabular\Time`
+
+
+* Class extends [App\Yr\Forecast\Tabular\Time\AbstractUnit](#abstractunit-appyrforecasttabulartime)
+* Class implements[App\Yr\Forecast\Tabular\Time\DiffInterface](#diffinterface-appyrforecasttabulartime)
+
+
 ### Pressure `App\Yr\Forecast\Tabular\Time`
 
 
@@ -931,14 +1035,14 @@ Temperature
 
 ##### __construct `App\Yr\Forecast\Tabular\Time\Temperature`
 ```php
-public function __construct(SimpleXMLElement $xml);
+public function __construct(SimpleXMLElement null $xml);
 ```
 
 Parameters
 
 | Type | Variable | Description |
 |---|---|---|
-|SimpleXMLElement|$xml|XML containing the temperature|
+|SimpleXMLElement null|$xml|XML containing the temperature|
 ---
 
 
@@ -1019,8 +1123,9 @@ Wind speed
 |Name|Return|Access|Description|
 |:---|:---|:---|:---|
 |[__construct](#__construct-appyrforecasttabulartimewindspeed)||public| |
-|[convertTo](#convertto-appyrforecasttabulartimewindspeed)|int|public| Convert the wind speed to a different unit|
+|[convertTo](#convertto-appyrforecasttabulartimewindspeed)|[WindSpeed](#windspeed-appyrforecasttabulartime)|public| Convert the wind speed to a different unit|
 |[getName](#getname-appyrforecasttabulartimewindspeed)|string|public| Returns the wind name, e.g «light breeze»|
+|[setName](#setname-appyrforecasttabulartimewindspeed)|[WindSpeed](#windspeed-appyrforecasttabulartime)|protected| |
 |[diff](#diff-appyrforecasttabulartimewindspeed)|int|public| Check for differences with another DiffInterface.|
 |[__toString](#__tostring-appyrforecasttabulartimewindspeed)|string|public| |
 
@@ -1052,7 +1157,7 @@ Parameters
 |---|---|---|
 |string|$unit|The unit to convert to, eg UNIT_FTS|
 
-Returns: int
+Returns: [WindSpeed](#windspeed-appyrforecasttabulartime)
 
 ---
 
@@ -1069,6 +1174,22 @@ Returns: string
 ---
 
 
+##### setName `App\Yr\Forecast\Tabular\Time\WindSpeed`
+```php
+protected function setName(string $name);
+```
+
+Parameters
+
+| Type | Variable | Description |
+|---|---|---|
+|string|$name|*None*|
+
+Returns: [WindSpeed](#windspeed-appyrforecasttabulartime)
+
+---
+
+
 ##### diff `App\Yr\Forecast\Tabular\Time\WindSpeed`
 ```php
 public function diff(DiffInterface $e);