コード例 #1
0
ファイル: ExtensionHarvester.cs プロジェクト: zqb971/Orchard2
        private ExtensionDescriptor GetExtensionDescriptor(string locationPath, string extensionId, string extensionType, string manifestPath, bool manifestIsOptional)
        {
            var manifestText = _fileSystem.ReadFile(manifestPath);

            if (manifestText == null)
            {
                if (manifestIsOptional)
                {
                    manifestText = string.Format("Id: {0}", extensionId);
                }
                else
                {
                    return(null);
                }
            }

            return(GetDescriptorForExtension(locationPath, extensionId, extensionType, manifestText));
        }
コード例 #2
0
 public string ReadFile(string path)
 {
     return(_fileSystem.ReadFile(path));
 }