public void SetWellKnownTagsFromRawString(string rawTags) { string[] tags = rawTags.Split(new[] { ',' }, StringSplitOptions.RemoveEmptyEntries); DeploymentParameterWellKnownTag wellKnownTags = DeploymentParameterWellKnownTag.None; foreach (string tag in tags) { try { wellKnownTags |= (DeploymentParameterWellKnownTag)Enum.Parse(typeof(DeploymentParameterWellKnownTag), tag, true); } catch (Exception) {} } WellKnownTags = wellKnownTags & DeploymentParameterWellKnownTag.AllKnown; }
private WebApplicationGalleryParamControl FindParameterControlByTag(DeploymentParameterWellKnownTag tag) { foreach (RepeaterItem item in repParams.Items) { WebApplicationGalleryParamControl paramControl = item.FindControl("param") as WebApplicationGalleryParamControl; if (paramControl != null && (paramControl.WellKnownTags & tag) == tag) return paramControl; } return null; }
private DeploymentParameter FindParameterByTag(List<DeploymentParameter> parameters, DeploymentParameterWellKnownTag tag) { return parameters.Find(delegate(DeploymentParameter p) { return ((p.WellKnownTags & tag) == tag); }); }
private void AddDatabaseEngine(DeploymentParameterWellKnownTag engine, string group, string text) { databaseEngines.Items.Add(new ListItem(text, String.Format("{0},{1}", engine, group))); }
private static DeploymentParameter FindParameterByTag(List <DeploymentParameter> parameters, DeploymentParameterWellKnownTag tag) { return(parameters.Find(p => { return (p.WellKnownTags & tag) == tag; })); }
private void SetDBPolicies(string policy, IEnumerable<DeploymentParameter> parameters, DeploymentParameterWellKnownTag dbTag) { foreach (DeploymentParameter parameter in parameters) { if ( (parameter.WellKnownTags & DeploymentParameterWellKnownTag.DBName) != 0 && (parameter.WellKnownTags & dbTag) != 0 ) { // database name string policyValue = GetPackagePolicy(policy, "DatabaseNamePolicy"); ApplyPrefixSuffixPolicy(parameter, policyValue); } if ( (parameter.WellKnownTags & DeploymentParameterWellKnownTag.DBUserName) != 0 && (parameter.WellKnownTags & dbTag) != 0 ) { // user name string policyValue = GetPackagePolicy(policy, "UserNamePolicy"); ApplyPrefixSuffixPolicy(parameter, policyValue); } } }