-
Notifications
You must be signed in to change notification settings - Fork 4k
Az.network function1 #18966
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Merged
Merged
Az.network function1 #18966
Changes from 26 commits
Commits
Show all changes
28 commits
Select commit
Hold shift + click to select a range
4dfbe27
updated readme
kukulkarni1 db5b027
Added custom script for get traffic collector
kukulkarni1 bb8f081
readme indentation
kukulkarni1 d0f68f8
resolving compile issues
kukulkarni1 f0ebf4d
resolving compile issues
kukulkarni1 31f160c
removed extra file
kukulkarni1 ba7e6fa
renamed file
kukulkarni1 82e1aa6
added new collector policy cmdlet
kukulkarni1 e497394
solving compile issues
kukulkarni1 6253baa
solving compile issues
kukulkarni1 e424ea6
solving compile issues
kukulkarni1 ce56968
added new ps script
kukulkarni1 3cd1cf9
added new ps script
kukulkarni1 8302601
New cmdlet csharp script
kukulkarni1 d1efa74
New cmdlet csharp bug fix
kukulkarni1 be35ed5
change operationId in readme
kukulkarni1 39e45d2
Changed functions to export
kukulkarni1 6c2a104
removing new cmdlet
kukulkarni1 eccb83b
Updated swagger commit id
kukulkarni1 cf1fd66
added customization for location property
kukulkarni1 1b5568d
Adding all files after running buildmodule
kukulkarni1 8a0489a
updated docs and examples
kukulkarni1 f212db6
minor typo
kukulkarni1 09c0c8c
removed set cmdlet, simplified custom cmdlets
kukulkarni1 5f5a30d
removed set cmdlet
kukulkarni1 13c6c8e
Added update cmdlet
kukulkarni1 b4a799b
updated examples
kukulkarni1 dae6e1c
updating docs folder
kukulkarni1 File filter
Filter by extension
Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
There are no files selected for viewing
This file contains hidden or 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 |
---|---|---|
@@ -1,5 +1,16 @@ | ||
bin | ||
obj | ||
.vs | ||
generated | ||
internal | ||
exports | ||
tools | ||
custom/*.psm1 | ||
custom/autogen-model-cmdlets | ||
test/*-TestResults.xml | ||
/*.ps1 | ||
/*.ps1xml | ||
/*.psm1 | ||
/*.snk | ||
/*.csproj | ||
/*.nuspec |
This file contains hidden or 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 hidden or 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
178 changes: 178 additions & 0 deletions
178
src/NetworkFunction/custom/New-AzNetworkFunctionCollectorPolicy.ps1
This file contains hidden or 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,178 @@ | ||
|
||
# ---------------------------------------------------------------------------------- | ||
# Copyright (c) Microsoft Corporation. All rights reserved. | ||
# Licensed under the Apache License, Version 2.0 (the "License"); | ||
# you may not use this file except in compliance with the License. | ||
# You may obtain a copy of the License at | ||
# http://www.apache.org/licenses/LICENSE-2.0 | ||
# Unless required by applicable law or agreed to in writing, software | ||
# distributed under the License is distributed on an "AS IS" BASIS, | ||
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. | ||
# See the License for the specific language governing permissions and | ||
# limitations under the License. | ||
# Code generated by Microsoft (R) AutoRest Code Generator.Changes may cause incorrect behavior and will be lost if the code | ||
# is regenerated. | ||
# ---------------------------------------------------------------------------------- | ||
|
||
<# | ||
.Synopsis | ||
Creates or updates a Collector Policy resource | ||
.Description | ||
Creates or updates a Collector Policy resource | ||
.Example | ||
{{ Add code here }} | ||
.Example | ||
{{ Add code here }} | ||
|
||
.Outputs | ||
Microsoft.Azure.PowerShell.Cmdlets.NetworkFunction.Models.Api20220801.ICollectorPolicy | ||
.Notes | ||
COMPLEX PARAMETER PROPERTIES | ||
|
||
To create the parameters described below, construct a hash table containing the appropriate properties. For information on hash tables, run Get-Help about_Hash_Tables. | ||
|
||
EMISSIONPOLICY <IEmissionPoliciesPropertiesFormat[]>: Emission policies. | ||
[EmissionDestination <IEmissionPolicyDestination[]>]: Emission policy destinations. | ||
[DestinationType <DestinationType?>]: Emission destination type. | ||
[EmissionType <EmissionType?>]: Emission format type. | ||
|
||
INGESTIONPOLICYINGESTIONSOURCE <IIngestionSourcesPropertiesFormat[]>: Ingestion Sources. | ||
[ResourceId <String>]: Resource ID. | ||
[SourceType <SourceType?>]: Ingestion source type. | ||
.Link | ||
https://docs.microsoft.com/powershell/module/az.networkfunction/new-aznetworkfunctioncollectorpolicy | ||
#> | ||
function New-AzNetworkFunctionCollectorPolicy { | ||
[OutputType([Microsoft.Azure.PowerShell.Cmdlets.NetworkFunction.Models.Api20220801.ICollectorPolicy])] | ||
[CmdletBinding(DefaultParameterSetName='CreateExpanded', PositionalBinding=$false, SupportsShouldProcess, ConfirmImpact='Medium')] | ||
param( | ||
[Parameter(Mandatory)] | ||
[Microsoft.Azure.PowerShell.Cmdlets.NetworkFunction.Category('Path')] | ||
[System.String] | ||
# Azure Traffic Collector name | ||
${AzureTrafficCollectorName}, | ||
|
||
[Parameter(Mandatory)] | ||
[Alias('CollectorPolicyName')] | ||
[Microsoft.Azure.PowerShell.Cmdlets.NetworkFunction.Category('Path')] | ||
[System.String] | ||
# Collector Policy Name | ||
${Name}, | ||
|
||
[Parameter(Mandatory)] | ||
[Microsoft.Azure.PowerShell.Cmdlets.NetworkFunction.Category('Path')] | ||
[System.String] | ||
# The name of the resource group. | ||
${ResourceGroupName}, | ||
|
||
[Parameter()] | ||
[Microsoft.Azure.PowerShell.Cmdlets.NetworkFunction.Category('Path')] | ||
[Microsoft.Azure.PowerShell.Cmdlets.NetworkFunction.Runtime.DefaultInfo(Script='(Get-AzContext).Subscription.Id')] | ||
[System.String] | ||
# Azure Subscription ID. | ||
${SubscriptionId}, | ||
|
||
[Parameter()] | ||
[AllowEmptyCollection()] | ||
[Microsoft.Azure.PowerShell.Cmdlets.NetworkFunction.Category('Body')] | ||
[Microsoft.Azure.PowerShell.Cmdlets.NetworkFunction.Models.Api20220801.IEmissionPoliciesPropertiesFormat[]] | ||
# Emission policies. | ||
# To construct, see NOTES section for EMISSIONPOLICY properties and create a hash table. | ||
${EmissionPolicy}, | ||
|
||
[Parameter()] | ||
[AllowEmptyCollection()] | ||
[Microsoft.Azure.PowerShell.Cmdlets.NetworkFunction.Category('Body')] | ||
[Microsoft.Azure.PowerShell.Cmdlets.NetworkFunction.Models.Api20220801.IIngestionSourcesPropertiesFormat[]] | ||
# Ingestion Sources. | ||
# To construct, see NOTES section for INGESTIONPOLICYINGESTIONSOURCE properties and create a hash table. | ||
${IngestionPolicyIngestionSource}, | ||
|
||
[Parameter()] | ||
[ArgumentCompleter([Microsoft.Azure.PowerShell.Cmdlets.NetworkFunction.Support.IngestionType])] | ||
[Microsoft.Azure.PowerShell.Cmdlets.NetworkFunction.Category('Body')] | ||
[Microsoft.Azure.PowerShell.Cmdlets.NetworkFunction.Support.IngestionType] | ||
# The ingestion type. | ||
${IngestionPolicyIngestionType}, | ||
|
||
[Parameter(Mandatory)] | ||
[Microsoft.Azure.PowerShell.Cmdlets.NetworkFunction.Category('Body')] | ||
[System.String] | ||
# Resource location. | ||
${Location}, | ||
|
||
[Parameter()] | ||
[Microsoft.Azure.PowerShell.Cmdlets.NetworkFunction.Category('Body')] | ||
[Microsoft.Azure.PowerShell.Cmdlets.NetworkFunction.Runtime.Info(PossibleTypes=([Microsoft.Azure.PowerShell.Cmdlets.NetworkFunction.Models.Api20220801.ITrackedResourceTags]))] | ||
[System.Collections.Hashtable] | ||
# Resource tags. | ||
${Tag}, | ||
|
||
[Parameter()] | ||
[Alias('AzureRMContext', 'AzureCredential')] | ||
[ValidateNotNull()] | ||
[Microsoft.Azure.PowerShell.Cmdlets.NetworkFunction.Category('Azure')] | ||
[System.Management.Automation.PSObject] | ||
# The credentials, account, tenant, and subscription used for communication with Azure. | ||
${DefaultProfile}, | ||
|
||
[Parameter()] | ||
[Microsoft.Azure.PowerShell.Cmdlets.NetworkFunction.Category('Runtime')] | ||
[System.Management.Automation.SwitchParameter] | ||
# Run the command as a job | ||
${AsJob}, | ||
|
||
[Parameter(DontShow)] | ||
[Microsoft.Azure.PowerShell.Cmdlets.NetworkFunction.Category('Runtime')] | ||
[System.Management.Automation.SwitchParameter] | ||
# Wait for .NET debugger to attach | ||
${Break}, | ||
|
||
[Parameter(DontShow)] | ||
[ValidateNotNull()] | ||
[Microsoft.Azure.PowerShell.Cmdlets.NetworkFunction.Category('Runtime')] | ||
[Microsoft.Azure.PowerShell.Cmdlets.NetworkFunction.Runtime.SendAsyncStep[]] | ||
# SendAsync Pipeline Steps to be appended to the front of the pipeline | ||
${HttpPipelineAppend}, | ||
|
||
[Parameter(DontShow)] | ||
[ValidateNotNull()] | ||
[Microsoft.Azure.PowerShell.Cmdlets.NetworkFunction.Category('Runtime')] | ||
[Microsoft.Azure.PowerShell.Cmdlets.NetworkFunction.Runtime.SendAsyncStep[]] | ||
# SendAsync Pipeline Steps to be prepended to the front of the pipeline | ||
${HttpPipelinePrepend}, | ||
|
||
[Parameter()] | ||
[Microsoft.Azure.PowerShell.Cmdlets.NetworkFunction.Category('Runtime')] | ||
[System.Management.Automation.SwitchParameter] | ||
# Run the command asynchronously | ||
${NoWait}, | ||
|
||
[Parameter(DontShow)] | ||
[Microsoft.Azure.PowerShell.Cmdlets.NetworkFunction.Category('Runtime')] | ||
[System.Uri] | ||
# The URI for the proxy server to use | ||
${Proxy}, | ||
|
||
[Parameter(DontShow)] | ||
[ValidateNotNull()] | ||
[Microsoft.Azure.PowerShell.Cmdlets.NetworkFunction.Category('Runtime')] | ||
[System.Management.Automation.PSCredential] | ||
# Credentials for a proxy server to use for the remote call | ||
${ProxyCredential}, | ||
|
||
[Parameter(DontShow)] | ||
[Microsoft.Azure.PowerShell.Cmdlets.NetworkFunction.Category('Runtime')] | ||
[System.Management.Automation.SwitchParameter] | ||
# Use the default credentials for the proxy | ||
${ProxyUseDefaultCredentials} | ||
) | ||
|
||
process { | ||
try { | ||
kukulkarni1 marked this conversation as resolved.
Show resolved
Hide resolved
|
||
Az.NetworkFunction.internal\New-AzNetworkFunctionCollectorPolicy @PSBoundParameters | ||
} catch { | ||
throw | ||
} | ||
} | ||
} |
Oops, something went wrong.
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Uh oh!
There was an error while loading. Please reload this page.