protected override string GetLogicalPath(Project project, SuiteRelativePath file, SourceSetType sourceSetType) { var path = base.GetLogicalPath(project, file, sourceSetType); if (path.StartsWith("wpf" + Path.DirectorySeparatorChar)) return path.Substring(4).Replace(Path.DirectorySeparatorChar, '/'); else return PrefixWithRootNamespace(project, PrefixNumericComponents(path)).Replace(Path.DirectorySeparatorChar, '.'); }
public SourceSetIgnoreList Get(SourceSetType type) { SourceSetIgnoreList ignoreList; if (!ignoreLists.TryGetValue(type, out ignoreList)) { ignoreList = new SourceSetIgnoreList(); ignoreLists.Add(type, ignoreList); } return ignoreList; }
/// <summary> /// Converts a suite relative path to project relative /// </summary> /// <param name="project">Project to be relative to</param> /// <param name="suiteRelativePath">Suite relative path</param> /// <param name="sourceSetName">Source set name where the project being built stores its files</param> /// <returns>Returns the path relative to the project's root directory</returns> protected string ToProjectRelativePath(Project project, string suiteRelativePath, SourceSetType sourceSetName) { return suite.SuiteRoot.GetRelativePathFrom(project.RootDirectory.GetChildDirectory(sourceSetName.AsString), suiteRelativePath); }
/// <summary> /// Creates an empty source set /// </summary> /// <param name="type">Type of sources in this set</param> public SourceSet(SourceSetType type) { Contract.Requires(type != null); this.type = type; }
protected virtual string GetLogicalPath(Project project, SuiteRelativePath file, SourceSetType sourceSetType) { return(ToProjectRelativePath(project, file, sourceSetType)); }
protected virtual void WriteItem(XmlWriter writer, Project project, SuiteRelativePath file, string relativePath, SourceSetType sourceSetType, string logicalPath) { writer.WriteStartElement(GetElementNameFor(project, file)); writer.WriteAttributeString("Include", relativePath); if (ProjectSourceSetName != sourceSetType) { writer.WriteElementString("LogicalName", logicalPath); } WriteAdditionalOptions(writer, project, file); writer.WriteEndElement(); }
protected override string GetLogicalPath(Project project, SuiteRelativePath file, SourceSetType sourceSetType) { var path = base.GetLogicalPath(project, file, sourceSetType); if (path.StartsWith("wpf" + Path.DirectorySeparatorChar)) { return(path.Substring(4).Replace(Path.DirectorySeparatorChar, '/')); } else { return(PrefixWithRootNamespace(project, PrefixNumericComponents(path)).Replace(Path.DirectorySeparatorChar, '.')); } }
protected override void WriteItem(XmlWriter writer, Project project, SuiteRelativePath file, string relativePath, SourceSetType sourceSetType, string logicalPath) { var resrelativePath = ToProjectRelativePath(project, file, "resources"); if (!resrelativePath.StartsWith("win32" + Path.DirectorySeparatorChar)) { base.WriteItem(writer, project, file, relativePath, sourceSetType, logicalPath); } }
protected virtual string GetLogicalPath(Project project, SuiteRelativePath file, SourceSetType sourceSetType) { return ToProjectRelativePath(project, file, sourceSetType); }
/// <summary> /// Converts a suite relative path to project relative /// </summary> /// <param name="project">Project to be relative to</param> /// <param name="suiteRelativePath">Suite relative path</param> /// <param name="sourceSetName">Source set name where the project being built stores its files</param> /// <returns>Returns the path relative to the project's root directory</returns> protected string ToProjectRelativePath(Project project, string suiteRelativePath, SourceSetType sourceSetName) { return(suite.SuiteRoot.GetRelativePathFrom(project.RootDirectory.GetChildDirectory(sourceSetName.AsString), suiteRelativePath)); }