예제 #1
0
        protected override void ExecuteCmdlet()
        {
            switch (ParameterSetName)
            {
            case "WithContent":
            {
                SelectedWeb.AddWikiPageByUrl(ServerRelativePageUrl, Content);
                break;
            }

            case "WithLayout":
            {
                SelectedWeb.AddWikiPageByUrl(ServerRelativePageUrl);
                SelectedWeb.AddLayoutToWikiPage(Layout, ServerRelativePageUrl);
                break;
            }

            default:
            {
                SelectedWeb.AddWikiPageByUrl(ServerRelativePageUrl);
                break;
            }
            }
        }