Skip to content

Commit

Permalink
Merge pull request #99 from usmanazizgroupdocs/master
Browse files Browse the repository at this point in the history
Updated for v16.11.0
  • Loading branch information
Usman Aziz authored Nov 23, 2016
2 parents 8a5cd9e + ccafdfb commit 4e9d663
Show file tree
Hide file tree
Showing 10 changed files with 66 additions and 21 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -220,5 +220,14 @@ public void SaveDocument(CachedDocumentDescription description, Stream stream)
{
//TODO
}
public void AddFile(string guid, Stream content)
{
//TODO
}
public List<FileDescription> GetEntities(string path)
{
//TODO
return new List<FileDescription>();
}
}
}
Original file line number Diff line number Diff line change
Expand Up @@ -100,6 +100,15 @@ public void SaveDocument(CachedDocumentDescription description, Stream stream)
{
//TODO
}
public void AddFile(string guid, Stream content)
{
//TODO
}
public List<FileDescription> GetEntities(string path)
{
//TODO
return new List<FileDescription>();
}

}
}
Original file line number Diff line number Diff line change
Expand Up @@ -34,8 +34,8 @@
<WarningLevel>4</WarningLevel>
</PropertyGroup>
<ItemGroup>
<Reference Include="GroupDocs.Viewer, Version=16.10.0.0, Culture=neutral, PublicKeyToken=716fcc553a201e56, processorArchitecture=MSIL">
<HintPath>..\..\packages\groupdocs-viewer-dotnet.16.10.0\lib\GroupDocs.Viewer.dll</HintPath>
<Reference Include="GroupDocs.Viewer, Version=16.11.0.0, Culture=neutral, PublicKeyToken=716fcc553a201e56, processorArchitecture=MSIL">
<HintPath>..\..\packages\groupdocs-viewer-dotnet.16.11.0\lib\GroupDocs.Viewer.dll</HintPath>
<Private>True</Private>
</Reference>
<Reference Include="Microsoft.Azure.KeyVault.Core, Version=1.0.0.0, Culture=neutral, PublicKeyToken=31bf3856ad364e35, processorArchitecture=MSIL">
Expand Down Expand Up @@ -85,7 +85,9 @@
</ItemGroup>
<ItemGroup>
<None Include="bin\Debug\GroupDocs.Viewer.Examples.CSharp.vshost.exe.manifest" />
<None Include="packages.config" />
<None Include="packages.config">
<SubType>Designer</SubType>
</None>
</ItemGroup>
<ItemGroup>
<Content Include="bin\Debug\de\Microsoft.Data.Edm.resources.dll" />
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -713,13 +713,19 @@ public static void LoadFileTree(String Path)
// Create/initialize image handler
ViewerImageHandler imageHandler = new ViewerImageHandler(Utilities.GetConfigurations());

// Load file tree list for custom path
var options = new FileTreeOptions(Path);
// Load file list for custom path
FileListOptions options = new FileListOptions(Path);

// Load file tree list for ViewerConfig.StoragePath
FileTreeContainer container = imageHandler.LoadFileTree(options);
// Load file list sorted by Name and ordered Ascending for custom path
FileListOptions options1 = new FileListOptions(Path, FileListOptions.FileListSortBy.Name, FileListOptions.FileListOrderBy.Ascending);

foreach (var node in container.FileTree)
// Load file list for ViewerConfig.StoragePath
FileListContainer container = imageHandler.GetFileList();

// Load file list for custom path
FileListContainer container1 = imageHandler.GetFileList(options);

foreach (var node in container.Files)
{
if (node.IsDirectory)
{
Expand All @@ -738,7 +744,6 @@ public static void LoadFileTree(String Path)
node.Size,
node.LastModificationDate);
}

//ExEnd:LoadFileTree

}
Expand Down
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
<?xml version="1.0" encoding="utf-8"?>
<packages>
<package id="groupdocs-viewer-dotnet" version="16.10.0" targetFramework="net40" />
<package id="groupdocs-viewer-dotnet" version="16.11.0" targetFramework="net40" />
<package id="Microsoft.Azure.KeyVault.Core" version="1.0.0" targetFramework="net40" />
<package id="Microsoft.Data.Edm" version="5.6.4" targetFramework="net40" />
<package id="Microsoft.Data.OData" version="5.6.4" targetFramework="net40" />
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -180,7 +180,13 @@ Namespace GroupDocs.Viewer.Examples
Dim emptyDate As New DateTime(1, 1, 1)
Return If(dateTimeOffset.HasValue, dateTimeOffset.Value.DateTime, emptyDate)
End Function

Public Sub AddFile(guid As String, content As Stream) Implements IInputDataHandler.AddFile
'TODO
End Sub
Public Function GetEntities(path As String) As List(Of FileDescription) Implements IInputDataHandler.GetEntities
'TODO
Return New List(Of FileDescription)()
End Function
End Class
End Namespace

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -90,6 +90,13 @@ Namespace GroupDocs.Viewer.Examples
Public Sub SaveDocument(description As CachedDocumentDescription, stream As Stream) Implements IInputDataHandler.SaveDocument
'TODO
End Sub
Public Sub AddFile(guid As String, content As Stream) Implements IInputDataHandler.AddFile
'TODO
End Sub
Public Function GetEntities(path As String) As List(Of FileDescription) Implements IInputDataHandler.GetEntities
'TODO
Return New List(Of FileDescription)()
End Function
End Class
End Namespace

Original file line number Diff line number Diff line change
Expand Up @@ -48,8 +48,8 @@
<OptionInfer>On</OptionInfer>
</PropertyGroup>
<ItemGroup>
<Reference Include="GroupDocs.Viewer, Version=16.10.0.0, Culture=neutral, PublicKeyToken=716fcc553a201e56, processorArchitecture=MSIL">
<HintPath>..\packages\groupdocs-viewer-dotnet.16.10.0\lib\GroupDocs.Viewer.dll</HintPath>
<Reference Include="GroupDocs.Viewer, Version=16.11.0.0, Culture=neutral, PublicKeyToken=716fcc553a201e56, processorArchitecture=MSIL">
<HintPath>..\packages\groupdocs-viewer-dotnet.16.11.0\lib\GroupDocs.Viewer.dll</HintPath>
<Private>True</Private>
</Reference>
<Reference Include="Microsoft.Azure.KeyVault.Core, Version=1.0.0.0, Culture=neutral, PublicKeyToken=31bf3856ad364e35, processorArchitecture=MSIL">
Expand Down Expand Up @@ -139,7 +139,9 @@
<CustomToolNamespace>My</CustomToolNamespace>
<LastGenOutput>Settings.Designer.vb</LastGenOutput>
</None>
<None Include="packages.config" />
<None Include="packages.config">
<SubType>Designer</SubType>
</None>
</ItemGroup>
<Import Project="$(MSBuildToolsPath)\Microsoft.VisualBasic.targets" />
<Import Project="$(SolutionDir)\.nuget\NuGet.targets" Condition="Exists('$(SolutionDir)\.nuget\NuGet.targets')" />
Expand Down
17 changes: 11 additions & 6 deletions Examples/GroupDocs.Viewer.Examples.VisualBasic/ViewGenerator.vb
Original file line number Diff line number Diff line change
Expand Up @@ -639,21 +639,26 @@ Namespace GroupDocs.Viewer.Examples
' Create/initialize image handler
Dim imageHandler As New ViewerImageHandler(Utilities.GetConfigurations())

' Load file tree list for custom path
Dim options = New FileTreeOptions(Path)
' Load file list for custom path
Dim options As New FileListOptions(Path)

' Load file tree list for ViewerConfig.StoragePath
Dim container As FileTreeContainer = imageHandler.LoadFileTree(options)
' Load file list sorted by Name and ordered Ascending for custom path
Dim options1 As New FileListOptions(Path, FileListOptions.FileListSortBy.Name, FileListOptions.FileListOrderBy.Ascending)

For Each node As Object In container.FileTree
' Load file list for ViewerConfig.StoragePath
Dim container As FileListContainer = imageHandler.GetFileList()

' Load file list for custom path
Dim container1 As FileListContainer = imageHandler.GetFileList(options)

For Each node As Object In container.Files
If node.IsDirectory Then
Console.WriteLine("Guid: {0} | Name: {1} | LastModificationDate: {2}", node.Guid, node.Name, node.LastModificationDate)
Else
Console.WriteLine("Guid: {0} | Name: {1} | Document type: {2} | File type: {3} | Extension: {4} | Size: {5} | LastModificationDate: {6}", node.Guid, node.Name, node.DocumentType, node.FileType, node.Extension, _
node.Size, node.LastModificationDate)
End If
Next

'ExEnd:LoadFileTree

End Sub
Expand Down
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
<?xml version="1.0" encoding="utf-8"?>
<packages>
<package id="groupdocs-viewer-dotnet" version="16.10.0" targetFramework="net40" />
<package id="groupdocs-viewer-dotnet" version="16.11.0" targetFramework="net40" />
<package id="Microsoft.Azure.KeyVault.Core" version="1.0.0" targetFramework="net40" />
<package id="Microsoft.Data.Edm" version="5.6.4" targetFramework="net40" />
<package id="Microsoft.Data.OData" version="5.6.4" targetFramework="net40" />
Expand Down

0 comments on commit 4e9d663

Please sign in to comment.