public virtual void VisitOverrideCollection(OverrideCollection overrides) { foreach (MethodReference method in overrides) { VisitOverride(method); } }
static void AppendToPartitionViaMerge(Database database, string table, string partitionName, string query, string tempPartitionName) { AddPartition(database, AASTableName, SQLDatabase, SQLQueryNil, AASTempPartitionName); database.Update(UpdateOptions.ExpandFull); Partition tempPartition = database.Model.Tables[table].Partitions[tempPartitionName]; Partition appendPartition = database.Model.Tables[table].Partitions[partitionName]; OverrideCollection oc = new OverrideCollection { Partitions = { new PartitionOverride { OriginalObject = tempPartition, Source = new QueryPartitionSourceOverride { DataSource = ((QueryPartitionSource)tempPartition.Source).DataSource, Query = query } } } }; var listOc = new List <OverrideCollection>(); listOc.Add(oc); tempPartition.RequestRefresh(Microsoft.AnalysisServices.Tabular.RefreshType.Automatic, listOc); //database.Update(UpdateOptions.ExpandFull); appendPartition.RequestMerge(new List <Partition>() { tempPartition }); database.Update(UpdateOptions.ExpandFull); }
public override void VisitOverrideCollection(OverrideCollection meth) { VisitCollection(meth); for (int i = 0; i < meth.Count; i++) { meth [i] = GetMethodReference(meth [i]); } }
void AddExplicitInterfaceImplementations(OverrideCollection overrides, IMember targetMember) { foreach (MethodReference overrideRef in overrides) { if (overrideRef.Name == targetMember.Name && targetMember.IsPublic) { continue; // is like implicit interface implementation / normal override } targetMember.InterfaceImplementations.Add(new ExplicitInterfaceImplementation( CreateType(this.ProjectContent, targetMember, overrideRef.DeclaringType), overrideRef.Name )); } }
/// <summary> /// Default ctor /// </summary> public NetMethodDefinition(string name, JvmClassLib.MethodDefinition javaMethod, NetTypeDefinition declaringType, TargetFramework target, SignedByteMode signMode, string createReason) { if (name == null) throw new ArgumentNullException("name"); if (declaringType == null) throw new ArgumentNullException("declaringType"); if (target == null) throw new ArgumentNullException("target"); Name = name; DeclaringType = declaringType; this.javaMethod = javaMethod; // Can be null this.target = target; this.signMode = signMode; this.createReason = createReason; overrides = new OverrideCollection(this); }
/// <summary> /// Default ctor /// </summary> public NetMethodDefinition(string name, JvmClassLib.MethodDefinition javaMethod, NetTypeDefinition declaringType, TargetFramework target, SignedByteMode signMode, string createReason) { if (name == null) { throw new ArgumentNullException("name"); } if (declaringType == null) { throw new ArgumentNullException("declaringType"); } if (target == null) { throw new ArgumentNullException("target"); } Name = name; DeclaringType = declaringType; this.javaMethod = javaMethod; // Can be null this.target = target; this.signMode = signMode; this.createReason = createReason; overrides = new OverrideCollection(this); }
static void AppendToPartition(Database database, string table, string partitionName, string query) { Partition partition = database.Model.Tables[table].Partitions[partitionName]; OverrideCollection oc = new OverrideCollection { Partitions = { new PartitionOverride { OriginalObject = partition, Source = new QueryPartitionSourceOverride { DataSource = ((QueryPartitionSource)partition.Source).DataSource, Query = query } } } }; var listOc = new List <OverrideCollection>(); listOc.Add(oc); partition.RequestRefresh(Microsoft.AnalysisServices.Tabular.RefreshType.Add, listOc); database.Update(UpdateOptions.ExpandFull); }
public void VisitOverrideCollection(OverrideCollection meth) { }
public override void VisitOverrideCollection(OverrideCollection meth) { VisitCollection(meth); }