Class PathShim
A collection of static methods to manipulate and test string paths
Inheritance
System.Object
PathShim
Inherited Members
System.Object.ToString()
System.Object.Equals(System.Object)
System.Object.Equals(System.Object, System.Object)
System.Object.ReferenceEquals(System.Object, System.Object)
System.Object.GetHashCode()
System.Object.GetType()
System.Object.MemberwiseClone()
Namespace: InventorShims
Assembly: InventorShims.dll
Syntax
public static class PathShim
Methods
| Improve this Doc View SourceIsContentCenterPath(String, Application)
A function that checks if the provided string contains a Content Center Library path.
Declaration
public static bool IsContentCenterPath(this string path, Application inventorApp)
Parameters
Type | Name | Description |
---|---|---|
System.String | path | Path as a string. |
Inventor.Application | inventorApp | Inventor.Application object. |
Returns
Type | Description |
---|---|
System.Boolean |
IsLibraryPath(String, Application)
A function that checks if the provided string contains an Inventor library path.
Declaration
public static bool IsLibraryPath(this string path, Application inventorApp)
Parameters
Type | Name | Description |
---|---|---|
System.String | path | Path as a string. |
Inventor.Application | inventorApp | Inventor.Application object. |
Returns
Type | Description |
---|---|
System.Boolean |
TrimEndingDirectorySeparator(String)
Provided a string that ends in a "/" or "", returns the string without those ending characters.
Declaration
public static string TrimEndingDirectorySeparator(string path)
Parameters
Type | Name | Description |
---|---|---|
System.String | path | string |
Returns
Type | Description |
---|---|
System.String | string |
UpOneLevel(String)
Provided a string directory path, returns the path with the last directory removed. E.g. UpOneLevel("C:\Work\Stuff") returns "C:\Work"
Declaration
public static string UpOneLevel(string path)
Parameters
Type | Name | Description |
---|---|---|
System.String | path | The path as a string |
Returns
Type | Description |
---|---|
System.String | A string |