「Windows/powershell/クラス」の版間の差分
提供: 初心者エンジニアの簡易メモ
(ページの作成:「==サンプル== hello.ps1 <pre> class HelloClass { [string] hello() { return "Hello!!" } } $helloObj = New-Object HelloClass $helloObj.hello() </pre>」) |
(相違点なし)
|
2021年8月23日 (月) 16:07時点における版
サンプル
hello.ps1
class HelloClass {
[string] hello() {
return "Hello!!"
}
}
$helloObj = New-Object HelloClass
$helloObj.hello()
