31 references to MetadataKey
Microsoft.DotNet.XliffTasks (31)
Tasks\EnsureAllResourcesTranslated.cs (1)
24
string sourceDocumentPath = item.GetMetadataOrDefault(
MetadataKey
.SourceDocumentPath, item.ItemSpec);
Tasks\GatherTranslatedSource.cs (13)
26
string translatedFullPath = xlf.GetMetadataOrThrow(
MetadataKey
.XlfTranslatedFullPath);
27
string language = xlf.GetMetadataOrThrow(
MetadataKey
.XlfLanguage);
28
bool preserveFileName = string.Equals(xlf.GetMetadata(
MetadataKey
.XlfPreserveFileName), "true", StringComparison.OrdinalIgnoreCase);
60
string link = xlf.GetMetadata(
MetadataKey
.Link);
63
link = xlf.GetMetadataOrThrow(
MetadataKey
.XlfSource);
82
output.SetMetadata(
MetadataKey
.Link, link);
87
string manifestResourceName = xlf.GetMetadata(
MetadataKey
.ManifestResourceName);
91
output.SetMetadata(
MetadataKey
.ManifestResourceName, manifestResourceName);
97
string logicalName = xlf.GetMetadata(
MetadataKey
.LogicalName);
102
output.SetMetadata(
MetadataKey
.LogicalName, logicalName);
108
string dependentUpon = xlf.GetMetadata(
MetadataKey
.DependentUpon);
111
string sourceDirectory = Path.GetDirectoryName(xlf.GetMetadataOrThrow(
MetadataKey
.XlfSource));
113
output.SetMetadata(
MetadataKey
.DependentUpon, dependentUpon);
Tasks\GatherXlf.cs (9)
34
string sourceDocumentPath = source.GetMetadataOrDefault(
MetadataKey
.SourceDocumentPath, source.ItemSpec);
40
xlf.SetMetadata(
MetadataKey
.XlfSource, source.ItemSpec);
41
xlf.SetMetadata(
MetadataKey
.XlfTranslatedFullPath, GetTranslatedOutputPath(source, language, outputPaths));
42
xlf.SetMetadata(
MetadataKey
.XlfLanguage, language);
53
bool preserveFileName = string.Equals(source.GetMetadata(
MetadataKey
.XlfPreserveFileName), "true", StringComparison.OrdinalIgnoreCase);
55
string translatedFileName = source.GetMetadata(
MetadataKey
.XlfTranslatedFilename);
59
source.SetMetadata(
MetadataKey
.XlfTranslatedFilename, translatedFileName);
62
string sourceDocumentPath = source.GetMetadataOrDefault(
MetadataKey
.SourceDocumentPath, source.ItemSpec);
73
$"Give them unique names or set unique {
MetadataKey
.XlfTranslatedFilename} metadata.");
Tasks\SortXlf.cs (1)
22
string sourceDocumentPath = item.GetMetadataOrDefault(
MetadataKey
.SourceDocumentPath, item.ItemSpec);
Tasks\TranslateSource.cs (5)
18
string sourcePath = XlfFile.GetMetadataOrThrow(
MetadataKey
.XlfSource);
19
string sourceFormat = XlfFile.GetMetadataOrThrow(
MetadataKey
.XlfSourceFormat);
20
string language = XlfFile.GetMetadataOrThrow(
MetadataKey
.XlfLanguage);
21
string translatedFullPath = XlfFile.GetMetadataOrThrow(
MetadataKey
.XlfTranslatedFullPath);
23
TranslatableDocument sourceDocument = XlfTask.LoadSourceDocument(sourcePath, XlfFile.GetMetadata(
MetadataKey
.XlfSourceFormat));
Tasks\UpdateXlf.cs (2)
32
string sourceDocumentPath = item.GetMetadataOrDefault(
MetadataKey
.SourceDocumentPath, item.ItemSpec);
33
string sourceFormat = item.GetMetadataOrThrow(
MetadataKey
.XlfSourceFormat);