Skip to content

Commit

Permalink
Add samples/Manual. #9
Browse files Browse the repository at this point in the history
  • Loading branch information
veblush committed Jun 3, 2016
1 parent 7810e33 commit b9f14bd
Show file tree
Hide file tree
Showing 20 changed files with 1,495 additions and 0 deletions.
27 changes: 27 additions & 0 deletions Akka.Interfaced.sln
Original file line number Diff line number Diff line change
Expand Up @@ -138,6 +138,15 @@ Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "Akka.Interfaced-SlimClient.
{C44CF322-7993-4451-A2F6-028C4ABCFD17} = {C44CF322-7993-4451-A2F6-028C4ABCFD17}
EndProjectSection
EndProject
Project("{2150E333-8FDC-42A3-9474-1A3956D46DE8}") = "Sample-Manual", "Sample-Manual", "{3A2A835D-1790-4232-9D05-41D48764D54B}"
EndProject
Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "Manual.Interface", "samples\Manual\Interface\Manual.Interface.csproj", "{9EECBF54-7B2D-4A41-BBDE-CBFBB344A142}"
ProjectSection(ProjectDependencies) = postProject
{C44CF322-7993-4451-A2F6-028C4ABCFD17} = {C44CF322-7993-4451-A2F6-028C4ABCFD17}
EndProjectSection
EndProject
Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "Manual.Program", "samples\Manual\Program\Manual.Program.csproj", "{3933BEAA-19AC-452E-A13A-B746E1EA6A8F}"
EndProject
Global
GlobalSection(SolutionConfigurationPlatforms) = preSolution
Debug|Any CPU = Debug|Any CPU
Expand Down Expand Up @@ -420,6 +429,22 @@ Global
{6F020F23-FC16-4567-99BB-10A06F20F9D6}.Release|Any CPU.Build.0 = Release|Any CPU
{6F020F23-FC16-4567-99BB-10A06F20F9D6}.Release|Win32.ActiveCfg = Release|Any CPU
{6F020F23-FC16-4567-99BB-10A06F20F9D6}.Release|Win32.Build.0 = Release|Any CPU
{9EECBF54-7B2D-4A41-BBDE-CBFBB344A142}.Debug|Any CPU.ActiveCfg = Debug|Any CPU
{9EECBF54-7B2D-4A41-BBDE-CBFBB344A142}.Debug|Any CPU.Build.0 = Debug|Any CPU
{9EECBF54-7B2D-4A41-BBDE-CBFBB344A142}.Debug|Win32.ActiveCfg = Debug|Any CPU
{9EECBF54-7B2D-4A41-BBDE-CBFBB344A142}.Debug|Win32.Build.0 = Debug|Any CPU
{9EECBF54-7B2D-4A41-BBDE-CBFBB344A142}.Release|Any CPU.ActiveCfg = Release|Any CPU
{9EECBF54-7B2D-4A41-BBDE-CBFBB344A142}.Release|Any CPU.Build.0 = Release|Any CPU
{9EECBF54-7B2D-4A41-BBDE-CBFBB344A142}.Release|Win32.ActiveCfg = Release|Any CPU
{9EECBF54-7B2D-4A41-BBDE-CBFBB344A142}.Release|Win32.Build.0 = Release|Any CPU
{3933BEAA-19AC-452E-A13A-B746E1EA6A8F}.Debug|Any CPU.ActiveCfg = Debug|Any CPU
{3933BEAA-19AC-452E-A13A-B746E1EA6A8F}.Debug|Any CPU.Build.0 = Debug|Any CPU
{3933BEAA-19AC-452E-A13A-B746E1EA6A8F}.Debug|Win32.ActiveCfg = Debug|Any CPU
{3933BEAA-19AC-452E-A13A-B746E1EA6A8F}.Debug|Win32.Build.0 = Debug|Any CPU
{3933BEAA-19AC-452E-A13A-B746E1EA6A8F}.Release|Any CPU.ActiveCfg = Release|Any CPU
{3933BEAA-19AC-452E-A13A-B746E1EA6A8F}.Release|Any CPU.Build.0 = Release|Any CPU
{3933BEAA-19AC-452E-A13A-B746E1EA6A8F}.Release|Win32.ActiveCfg = Release|Any CPU
{3933BEAA-19AC-452E-A13A-B746E1EA6A8F}.Release|Win32.Build.0 = Release|Any CPU
EndGlobalSection
GlobalSection(SolutionProperties) = preSolution
HideSolutionNode = FALSE
Expand Down Expand Up @@ -461,5 +486,7 @@ Global
{2137109B-6ACF-43CC-834A-19064FD784B6} = {1A90348B-9EF5-475B-83D8-9D4F385BA8B5}
{369AB21A-A234-4672-9B7F-E958A93531C0} = {1A90348B-9EF5-475B-83D8-9D4F385BA8B5}
{6F020F23-FC16-4567-99BB-10A06F20F9D6} = {1A90348B-9EF5-475B-83D8-9D4F385BA8B5}
{9EECBF54-7B2D-4A41-BBDE-CBFBB344A142} = {3A2A835D-1790-4232-9D05-41D48764D54B}
{3933BEAA-19AC-452E-A13A-B746E1EA6A8F} = {3A2A835D-1790-4232-9D05-41D48764D54B}
EndGlobalSection
EndGlobal
9 changes: 9 additions & 0 deletions samples/Manual/Interface/IGreetObserver.cs
Original file line number Diff line number Diff line change
@@ -0,0 +1,9 @@
using Akka.Interfaced;

namespace Manual
{
public interface IGreetObserver : IInterfacedObserver
{
void Event(string message);
}
}
11 changes: 11 additions & 0 deletions samples/Manual/Interface/IGreeter.cs
Original file line number Diff line number Diff line change
@@ -0,0 +1,11 @@
using System.Threading.Tasks;
using Akka.Interfaced;

namespace Manual
{
public interface IGreeter : IInterfacedActor
{
Task<string> Greet(string name);
Task<int> GetCount();
}
}
17 changes: 17 additions & 0 deletions samples/Manual/Interface/IGreeterWithObserver.cs
Original file line number Diff line number Diff line change
@@ -0,0 +1,17 @@
using System.Threading.Tasks;
using Akka.Interfaced;

namespace Manual
{
public interface IGreeterWithObserver : IInterfacedActor
{
Task<string> Greet(string name);
Task<int> GetCount();

// add an observer which receives a notification message whenever Greet request comes in
Task Subscribe(IGreetObserver observer);

// remove an observer
Task Unsubscribe(IGreetObserver observer);
}
}
92 changes: 92 additions & 0 deletions samples/Manual/Interface/Manual.Interface.csproj
Original file line number Diff line number Diff line change
@@ -0,0 +1,92 @@
<?xml version="1.0" encoding="utf-8"?>
<Project ToolsVersion="14.0" DefaultTargets="Build" xmlns="http://schemas.microsoft.com/developer/msbuild/2003">
<Import Project="$(SolutionDir)core\CodeGenerator-Templates\Akka.Interfaced.Templates.props" Condition="Exists('$(SolutionDir)core\CodeGenerator-Templates\Akka.Interfaced.Templates.props')" />
<Import Project="$(MSBuildExtensionsPath)\$(MSBuildToolsVersion)\Microsoft.Common.props" Condition="Exists('$(MSBuildExtensionsPath)\$(MSBuildToolsVersion)\Microsoft.Common.props')" />
<PropertyGroup>
<Configuration Condition=" '$(Configuration)' == '' ">Debug</Configuration>
<Platform Condition=" '$(Platform)' == '' ">AnyCPU</Platform>
<ProjectGuid>{9EECBF54-7B2D-4A41-BBDE-CBFBB344A142}</ProjectGuid>
<OutputType>Library</OutputType>
<AppDesignerFolder>Properties</AppDesignerFolder>
<RootNamespace>Manual</RootNamespace>
<AssemblyName>Manual.Interface</AssemblyName>
<TargetFrameworkVersion>v4.5.2</TargetFrameworkVersion>
<FileAlignment>512</FileAlignment>
<CodeAnalysisRuleSet>..\..\..\CodeAnalysis.ruleset</CodeAnalysisRuleSet>
</PropertyGroup>
<PropertyGroup Condition=" '$(Configuration)|$(Platform)' == 'Debug|AnyCPU' ">
<DebugSymbols>true</DebugSymbols>
<DebugType>full</DebugType>
<Optimize>false</Optimize>
<OutputPath>bin\Debug\</OutputPath>
<DefineConstants>DEBUG;TRACE</DefineConstants>
<ErrorReport>prompt</ErrorReport>
<WarningLevel>4</WarningLevel>
</PropertyGroup>
<PropertyGroup Condition=" '$(Configuration)|$(Platform)' == 'Release|AnyCPU' ">
<DebugType>pdbonly</DebugType>
<Optimize>true</Optimize>
<OutputPath>bin\Release\</OutputPath>
<DefineConstants>TRACE</DefineConstants>
<ErrorReport>prompt</ErrorReport>
<WarningLevel>4</WarningLevel>
<RunCodeAnalysis>true</RunCodeAnalysis>
</PropertyGroup>
<ItemGroup>
<Reference Include="Akka, Version=1.0.8.24, Culture=neutral, processorArchitecture=MSIL">
<HintPath>..\..\..\packages\Akka.1.0.8\lib\net45\Akka.dll</HintPath>
<Private>True</Private>
</Reference>
<Reference Include="Newtonsoft.Json, Version=8.0.0.0, Culture=neutral, PublicKeyToken=30ad4fe6b2a6aeed, processorArchitecture=MSIL">
<HintPath>..\..\..\packages\Newtonsoft.Json.8.0.3\lib\net45\Newtonsoft.Json.dll</HintPath>
<Private>True</Private>
</Reference>
<Reference Include="System" />
<Reference Include="System.Collections.Immutable, Version=1.1.36.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a, processorArchitecture=MSIL">
<HintPath>..\..\..\packages\System.Collections.Immutable.1.1.36\lib\portable-net45+win8+wp8+wpa81\System.Collections.Immutable.dll</HintPath>
<Private>True</Private>
</Reference>
<Reference Include="System.Core" />
<Reference Include="System.Xml.Linq" />
<Reference Include="System.Data.DataSetExtensions" />
<Reference Include="Microsoft.CSharp" />
<Reference Include="System.Data" />
<Reference Include="System.Net.Http" />
<Reference Include="System.Xml" />
</ItemGroup>
<ItemGroup>
<Compile Include="IGreeter.cs" />
<Compile Include="IGreeterWithObserver.cs" />
<Compile Include="IGreetObserver.cs" />
<Compile Include="Properties\Akka.Interfaced.CodeGen.cs" />
<Compile Include="Properties\AssemblyInfo.cs" />
</ItemGroup>
<ItemGroup>
<ProjectReference Include="..\..\..\core\Akka.Interfaced-Base\Akka.Interfaced-Base.csproj">
<Project>{c0d22336-c49e-4245-b39d-0b3083c28205}</Project>
<Name>Akka.Interfaced-Base</Name>
</ProjectReference>
<ProjectReference Include="..\..\..\core\Akka.Interfaced\Akka.Interfaced.csproj">
<Project>{5cbda46b-b22c-474a-8b99-e2e855a8bca8}</Project>
<Name>Akka.Interfaced</Name>
</ProjectReference>
</ItemGroup>
<ItemGroup>
<None Include="app.config" />
<None Include="packages.config" />
</ItemGroup>
<ItemGroup>
<Analyzer Include="..\..\..\packages\StyleCop.Analyzers.1.0.0\analyzers\dotnet\cs\Newtonsoft.Json.dll" />
<Analyzer Include="..\..\..\packages\StyleCop.Analyzers.1.0.0\analyzers\dotnet\cs\StyleCop.Analyzers.CodeFixes.dll" />
<Analyzer Include="..\..\..\packages\StyleCop.Analyzers.1.0.0\analyzers\dotnet\cs\StyleCop.Analyzers.dll" />
</ItemGroup>
<Import Project="$(MSBuildToolsPath)\Microsoft.CSharp.targets" />
<Import Project="$(SolutionDir)core\CodeGenerator-Templates\Akka.Interfaced.Templates.Common.targets" Condition="Exists('$(SolutionDir)core\CodeGenerator-Templates\Akka.Interfaced.Templates.Common.targets')" />
<!-- To modify your build process, add your task inside one of the targets below and uncomment it.
Other similar extension points exist, see Microsoft.Common.targets.
<Target Name="BeforeBuild">
</Target>
<Target Name="AfterBuild">
</Target>
-->
</Project>
Loading

0 comments on commit b9f14bd

Please sign in to comment.