-
Notifications
You must be signed in to change notification settings - Fork 16
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Exclude class methods when getting function definitions - Fixes #6
- Loading branch information
1 parent
4bcd774
commit 7ca8b07
Showing
3 changed files
with
100 additions
and
31 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,37 @@ | ||
Function Public () { | ||
<# | ||
.SYNOPSIS | ||
This cmdlet configures nothing and does it remarkably well. | ||
.DESCRIPTION | ||
This cmdlet configures nothing and does it remarkably well. | ||
It takes objects as input and it sets nothing to 42. | ||
#> | ||
|
||
Function Nested ($InputObject) { | ||
Get-Item $InputObject | ||
} | ||
} | ||
|
||
Function Private ($InputObject) { | ||
# A simple line of comment | ||
Get-Item $InputObject | ||
} | ||
|
||
Class Car | ||
{ | ||
Static [int]$NumberOfWheels = 4 | ||
|
||
[int]$NumberOfDoors | ||
|
||
[datetime]$Year | ||
|
||
[String]$Model | ||
|
||
[Double] GetNumberOfYearsOld() | ||
{ | ||
$Now = [datetime]::now | ||
$TimeSpan = $Now - $this.Year | ||
return $TimeSpan.Days / 365 | ||
} | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters