Inheritance: Microsoft.Azure.Commands.StreamAnalytics.Models.JobParametersBase
        public override void ExecuteCmdlet()
        {
            if (ResourceGroupName != null && string.IsNullOrWhiteSpace(ResourceGroupName))
            {
                throw new PSArgumentNullException("ResourceGroupName");
            }

            if (JobName != null && string.IsNullOrWhiteSpace(JobName))
            {
                throw new PSArgumentNullException("JobName");
            }

            if (File != null && string.IsNullOrWhiteSpace(File))
            {
                throw new PSArgumentNullException("File");
            }

            string rawJsonContent = StreamAnalyticsClient.ReadJsonFileContent(this.TryResolvePath(File));

            Name = ResolveResourceName(rawJsonContent, Name, "Function");

            if (Name != null && string.IsNullOrWhiteSpace(Name))
            {
                throw new ArgumentException(Resources.FunctionNameCannotBeEmpty);
            }

            RetrieveDefaultPSFunctionDefinitionParameter parameter = new RetrieveDefaultPSFunctionDefinitionParameter
            {
                ResourceGroupName = ResourceGroupName,
                JobName = JobName,
                FunctionName = Name,
                RawJsonContent = rawJsonContent
            };

            WriteObject(StreamAnalyticsClient.RetrieveDefaultPSFunctionDefinition(parameter));
        }
        public virtual PSFunction RetrieveDefaultPSFunctionDefinition(RetrieveDefaultPSFunctionDefinitionParameter parameter)
        {
            if (parameter == null)
            {
                throw new ArgumentNullException("parameter");
            }

            var response = StreamAnalyticsManagementClient.Functions.RetrieveDefaultDefinitionWithRawJsonContent(
                parameter.ResourceGroupName, parameter.JobName, parameter.FunctionName,
                new FunctionRetrieveDefaultDefinitionWithRawJsonContentParameters() {Content = parameter.RawJsonContent});

            return new PSFunction(response.Function)
            {
                ResourceGroupName = parameter.ResourceGroupName,
                JobName = parameter.JobName
            };
        }