Line | |
---|
1 | using System;
|
---|
2 | using System.Text;
|
---|
3 |
|
---|
4 | namespace HeuristicLab.Persistence.Auxiliary {
|
---|
5 |
|
---|
6 | /// <summary>
|
---|
7 | /// Extension methods for the <see cref="Type"/> class.
|
---|
8 | /// </summary>
|
---|
9 | public static class TypeExtensions {
|
---|
10 |
|
---|
11 | /// <summary>
|
---|
12 | /// Get an assembly qualified name withough version information.
|
---|
13 | /// </summary>
|
---|
14 | /// <param name="type">The type.</param>
|
---|
15 | /// <returns>A full type name without version information.</returns>
|
---|
16 | public static string VersionInvariantName(this Type type) {
|
---|
17 | return TypeNameParser.Parse(type.AssemblyQualifiedName).ToString(false);
|
---|
18 | }
|
---|
19 |
|
---|
20 | }
|
---|
21 |
|
---|
22 | } |
---|
Note: See
TracBrowser
for help on using the repository browser.