├── .gitignore
├── .nuget
├── NuGet.Config
├── NuGet.exe
└── NuGet.targets
├── Apworks.sln
├── Apworks.vsmdi
├── Local.testsettings
├── Packages.dgml
├── README.md
├── Settings.StyleCop
├── Tests
├── Apworks.Tests.Buses
│ ├── Apworks.Tests.Buses.csproj
│ ├── CommandBusTests.cs
│ ├── CommandHandlers
│ │ └── ChangeEmailCommandHandler.cs
│ ├── Commands
│ │ └── ChangeEmailCommand.cs
│ ├── Properties
│ │ └── AssemblyInfo.cs
│ ├── StorageMappings.xml
│ └── app.config
├── Apworks.Tests.Common
│ ├── AggregateRoots
│ │ ├── Customer.cs
│ │ ├── EFAddress.cs
│ │ ├── EFCustomer.cs
│ │ ├── EFCustomerNote.cs
│ │ ├── EFNote.cs
│ │ ├── SourcedCustomer.cs
│ │ └── SourcedCustomerSnapshot.cs
│ ├── App.config
│ ├── Apworks.Tests.Common.csproj
│ ├── Commands
│ │ └── CreateCustomerCommand.cs
│ ├── Customer.hbm.xml
│ ├── EFContexts
│ │ └── EFTestContext.cs
│ ├── Events
│ │ ├── ChangeCustomerNameDomainEvent.cs
│ │ ├── ChangeEmailDomainEvent.cs
│ │ └── CreateCustomerDomainEvent.cs
│ ├── ExceptionHandlers
│ │ ├── ExceptionExceptionHandler.cs
│ │ ├── InvalidOperationExceptionHandler.cs
│ │ └── SystemExceptionHandler.cs
│ ├── Helper.cs
│ ├── Interceptors
│ │ ├── ExceptionHandlingInterceptor.cs
│ │ ├── LoggingInterceptor.cs
│ │ ├── MockInterceptorA.cs
│ │ └── MockInterceptorB.cs
│ ├── MessageHandlers
│ │ ├── CreateCustomerCommandHandler.cs
│ │ ├── CustomerCreatedEventHandler.cs
│ │ ├── EmailChangedEventHandler.cs
│ │ └── YetAnotherEmailChangedEventHandler.cs
│ ├── MongoDB
│ │ └── MongoDBRepositoryContextSettings.cs
│ ├── Properties
│ │ └── AssemblyInfo.cs
│ ├── SourcedCustomer.hbm.xml
│ └── packages.config
├── Apworks.Tests.Configuration
│ ├── Apworks.Tests.Configuration.csproj
│ ├── FluentInterfaceTests.cs
│ ├── Properties
│ │ └── AssemblyInfo.cs
│ ├── app.config
│ └── packages.config
├── Apworks.Tests.DomainEvents
│ ├── AggregateRootVersionTests.cs
│ ├── AnotherDomainEvent.cs
│ ├── Apworks.Tests.DomainEvents.csproj
│ ├── DomainEventTests.cs
│ ├── EventSourcedRepository_StorageMappings.xml
│ ├── OneDomainEvent.cs
│ ├── Properties
│ │ └── AssemblyInfo.cs
│ └── app.config
├── Apworks.Tests.EventStore.MySql
│ ├── Apworks.Tests.EventStore.MySql.csproj
│ ├── MySqlEventStorageTests.cs
│ ├── Properties
│ │ └── AssemblyInfo.cs
│ ├── StorageMappings.xml
│ ├── app.config
│ └── packages.config
├── Apworks.Tests.EventStore.SqlExpress
│ ├── Apworks.Tests.EventStore.SqlExpress.csproj
│ ├── Properties
│ │ └── AssemblyInfo.cs
│ ├── SqlExpressEventStorageTests.cs
│ ├── StorageMappings.xml
│ └── app.config
├── Apworks.Tests.ExceptionHandling
│ ├── Apworks.Tests.ExceptionHandling.csproj
│ ├── ExceptionHandlingInvalidStorage.xml
│ ├── ExceptionHandlingTests.cs
│ ├── Properties
│ │ └── AssemblyInfo.cs
│ └── app.config
├── Apworks.Tests.Generators
│ ├── App.config
│ ├── Apworks.Tests.Generators.csproj
│ ├── GeneratorTests.cs
│ └── Properties
│ │ └── AssemblyInfo.cs
├── Apworks.Tests.Interception
│ ├── AddInterceptorsTests.cs
│ ├── Apworks.Tests.Interception.csproj
│ ├── InitializeInterceptorsTests.cs
│ ├── Properties
│ │ └── AssemblyInfo.cs
│ ├── app.config
│ └── packages.config
├── Apworks.Tests.MessageDispatcher
│ ├── Apworks.Tests.MessageDispatcher.csproj
│ ├── MessageDispatcherTests.cs
│ ├── Properties
│ │ └── AssemblyInfo.cs
│ └── app.config
├── Apworks.Tests.Repositories.DomainRepository
│ ├── Apworks.Tests.Repositories.DomainRepository.csproj
│ ├── EventSourcedDomainRepositoryTests.cs
│ ├── EventSourcedRepository_StorageMappings.xml
│ ├── Properties
│ │ └── AssemblyInfo.cs
│ ├── RegularDomainRepositoryTests.cs
│ ├── RegularEventPublisherDomainRepositoryTests.cs
│ ├── SnapshotDomainRepositoryTests.cs
│ ├── SnapshotDomainRepository_StorageMappings.xml
│ ├── app.config
│ └── packages.config
├── Apworks.Tests.Repositories.EntityFrameworkRepository
│ ├── App.config
│ ├── Apworks.Tests.Repositories.EntityFrameworkRepository.csproj
│ ├── EFRepositoryTests.cs
│ ├── Properties
│ │ └── AssemblyInfo.cs
│ └── packages.config
├── Apworks.Tests.Repositories.MongoDB
│ ├── Apworks.Tests.Repositories.MongoDB.csproj
│ ├── MongoDBRepositoryTests.cs
│ ├── Properties
│ │ └── AssemblyInfo.cs
│ ├── app.config
│ └── packages.config
└── Apworks.Tests.Repositories.NHibernateRepository
│ ├── Apworks.Tests.Repositories.NHibernateRepository.csproj
│ ├── NHibernateRepositoryTests.cs
│ ├── Properties
│ └── AssemblyInfo.cs
│ ├── app.config
│ └── packages.config
├── TraceAndTestImpact.testsettings
├── UnitTestEnvSetup.txt
├── build.bat
├── build.sh
├── docs
├── Apache20.rtf
├── ClsLibRef.chm
├── ReleaseNotes.txt
└── WalkthroughDocument.chm
├── scripts
├── ApworksConfigurationProject.xml
├── CQRSArchTestScript_EventStore_MySql.sql
├── CQRSArchTestScript_EventStore_SqlServer.sql
├── CQRSEventStoreXmlMapping.xml
├── ClassicArchTestScript_SqlServer.sql
├── ConfigProject.xsd
├── SampleConfiguration.xml
└── XmlStorageMappingSchema.xsd
└── src
├── Apworks.Bus.DirectBus
├── Apworks.Bus.DirectBus.csproj
├── Apworks.Bus.DirectBus.nuspec
├── DirectBus.cs
├── DirectCommandBus.cs
├── DirectEventBus.cs
├── Properties
│ └── AssemblyInfo.cs
└── key.snk
├── Apworks.Bus.EventAggregator
├── Apworks.Bus.EventAggregator.csproj
├── Apworks.Bus.EventAggregator.nuspec
├── EventAggregatorBus.cs
├── EventAggregatorCommandBus.cs
├── EventAggregatorEventBus.cs
├── Properties
│ └── AssemblyInfo.cs
└── key.snk
├── Apworks.Bus.MSMQ
├── Apworks.Bus.MSMQ.csproj
├── Apworks.Bus.MSMQ.nuspec
├── MSMQBus.cs
├── MSMQBusOptions.cs
├── MSMQCommandBus.cs
├── MSMQEventBus.cs
├── Properties
│ └── AssemblyInfo.cs
└── key.snk
├── Apworks.Events.Storage.General
├── Apworks.Events.Storage.General.csproj
├── Apworks.Events.Storage.General.nuspec
├── Properties
│ └── AssemblyInfo.cs
├── SqlDomainEventStorage.cs
└── key.snk
├── Apworks.Events.Storage.MySql
├── Apworks.Events.Storage.MySql.csproj
├── Apworks.Events.Storage.MySql.nuspec
├── MySqlDomainEventStorage.cs
├── Properties
│ └── AssemblyInfo.cs
└── key.snk
├── Apworks.ObjectContainers.Unity
├── Apworks.ObjectContainers.Unity.csproj
├── Apworks.ObjectContainers.Unity.nuspec
├── InstanceItems.cs
├── LifetimeManagers
│ ├── GlobalSuppressions.cs
│ ├── UnityBehaviorExtensionElement.cs
│ ├── UnityCallContextInitializer.cs
│ ├── UnityContextChannelExtension.cs
│ ├── UnityContextChannelLifetimeManager.cs
│ ├── UnityInstanceContextExtension.cs
│ ├── UnityInstanceContextInitializer.cs
│ ├── UnityInstanceContextLifetimeManager.cs
│ ├── UnityInstanceProvider.cs
│ ├── UnityOperationContextExtension.cs
│ ├── UnityOperationContextLifetimeManager.cs
│ ├── UnityOperationContextMessageInspector.cs
│ ├── UnityServiceBehavior.cs
│ ├── UnityServiceHostBaseExtension.cs
│ ├── UnityServiceHostBaseLifetimeManager.cs
│ ├── UnityWcfExtension.cs
│ └── UnityWcfLifetimeManager.cs
├── PerRequestLifetimeManager.cs
├── Properties
│ └── AssemblyInfo.cs
├── UnityContainerFluentExtender.cs
├── UnityObjectContainer.cs
├── key.snk
└── packages.config
├── Apworks.Repositories.EntityFramework
├── App.config
├── Apworks.Repositories.EntityFramework.csproj
├── Apworks.Repositories.EntityFramework.nuspec
├── EntityFrameworkRepository.cs
├── EntityFrameworkRepositoryContext.cs
├── IEntityFrameworkRepositoryContext.cs
├── Properties
│ └── AssemblyInfo.cs
├── SortByExtension.cs
├── key.snk
└── packages.config
├── Apworks.Repositories.MongoDB
├── Apworks.Repositories.MongoDB.csproj
├── Apworks.Repositories.MongoDB.nuspec
├── Conventions
│ ├── GuidIDGeneratorConvention.cs
│ └── UseLocalDateTimeConvention.cs
├── IMongoDBRepositoryContext.cs
├── IMongoDBRepositoryContextSettings.cs
├── MongoDBRepository.cs
├── MongoDBRepositoryContext.cs
├── Properties
│ └── AssemblyInfo.cs
├── SortExpressionHelper.cs
├── key.snk
└── packages.config
├── Apworks.Repositories.NHibernate
├── Apworks.Repositories.NHibernate.csproj
├── Apworks.Repositories.NHibernate.nuspec
├── DatabaseSessionFactory.cs
├── INHibernateContext.cs
├── NHibernateApplicationConfiguration.cs
├── NHibernateContext.cs
├── NHibernateRepository.cs
├── Properties
│ └── AssemblyInfo.cs
├── key.snk
└── packages.config
├── Apworks.Storage.General
├── Apworks.Storage.General.csproj
├── Apworks.Storage.General.nuspec
├── Builders
│ └── SqlWhereClauseBuilder.cs
├── Properties
│ └── AssemblyInfo.cs
├── SqlStorage.cs
└── key.snk
├── Apworks.Storage.MySql
├── Apworks.Storage.MySql.csproj
├── Apworks.Storage.MySql.nuspec
├── MySqlStorage.cs
├── MySqlWhereClauseBuilder.cs
├── Properties
│ └── AssemblyInfo.cs
├── app.config
├── key.snk
└── packages.config
└── Apworks
├── AggregateRoot.cs
├── Application
├── App.cs
├── AppInitEventArgs.cs
├── AppRuntime.cs
└── IApp.cs
├── Apworks.csproj
├── Apworks.nuspec
├── ApworksException.cs
├── Bus
├── BusException.cs
├── DispatchingException.cs
├── IBus.cs
├── ICommandBus.cs
├── IEventBus.cs
├── IMessageDispatcher.cs
├── MessageDispatchEventArgs.cs
├── MessageDispatcher.cs
└── RegisterDispatchAttribute.cs
├── Commands
├── Command.cs
├── CommandHandler.cs
├── ICommand.cs
└── ICommandHandler.cs
├── Config
├── AppConfigSource.cs
├── ApworksConfiguration.Partial.cs
├── ApworksConfiguration.cs
├── ApworksConfiguration.csd
├── ApworksConfiguration.csd.config
├── ApworksConfiguration.csd.cs
├── ApworksConfiguration.csd.diagram
├── ApworksConfiguration.csd.xsd
├── ConfigException.cs
├── Fluent
│ ├── ApplicationConfigurator.cs
│ ├── ApworksConfigurator.cs
│ ├── ConfigSourceConfigurator.cs
│ ├── Configurator.cs
│ ├── ExceptionHandlerConfigurator.cs
│ ├── Extensions.cs
│ ├── HandlerConfigurator.cs
│ ├── IdentityGeneratorConfigurator.cs
│ ├── InterceptionConfigurator.cs
│ ├── ObjectContainerConfigurator.cs
│ ├── SequenceGeneratorConfigurator.cs
│ └── TypeSpecifiedConfigSourceConfigurator.cs
├── IConfigSource.cs
└── RegularConfigSource.cs
├── Constants.cs
├── DisposableObject.cs
├── DomainException.cs
├── Events
├── ActionDelegatedEventHandler.cs
├── DomainEvent.cs
├── EventAggregator.cs
├── EventHandler.cs
├── HandlesAttribute.cs
├── IDomainEvent.cs
├── IDomainEventHandler.cs
├── IEvent.cs
├── IEventAggregator.cs
├── IEventHandler.cs
├── InlineDomainEventHandler.cs
├── ParallelExecutionAttribute.cs
├── Serialization
│ ├── DomainEventBinarySerializer.cs
│ ├── DomainEventDataContractSerializer.cs
│ ├── DomainEventJsonSerializer.cs
│ ├── DomainEventXmlSerializer.cs
│ └── IDomainEventSerializer.cs
└── Storage
│ ├── DomainEventDataObject.cs
│ ├── IDomainEventStorage.cs
│ └── RdbmsDomainEventStorage.cs
├── Exceptions
├── ExceptionHandler.cs
├── ExceptionManager.cs
└── IExceptionHandler.cs
├── ExpressionParser.cs
├── Generators
├── IIdentityGenerator.cs
├── ISequenceGenerator.cs
├── IdentityGenerator.cs
├── SequenceGenerator.cs
└── SequentialIdentityGenerator.cs
├── IAggregateRoot.cs
├── IEntity.cs
├── IHandler.cs
├── IObjectContainer.cs
├── IServiceLocator.cs
├── IServiceRegister.cs
├── ISourcedAggregateRoot.cs
├── IUnitOfWork.cs
├── InfrastructureException.cs
├── Interception
├── AdditionalInterfaceToProxyAttribute.cs
├── BaseTypeForInterfaceProxyAttribute.cs
├── ExceptionHandlingInterceptor.cs
└── InterceptorSelector.cs
├── ObjectContainer.cs
├── PagedResult.cs
├── Properties
├── AssemblyInfo.cs
├── Resources.Designer.cs
└── Resources.resx
├── Queries
├── IQueryObject.cs
└── Storage
│ └── IQueryObjectStorage.cs
├── Repositories
├── DomainRepository.cs
├── EventPublisherDomainRepository.cs
├── EventSourcedDomainRepository.cs
├── IDomainRepository.cs
├── IRepository.cs
├── IRepositoryContext.cs
├── RegularDomainRepository.cs
├── RegularEventPublisherDomainRepository.cs
├── Repository.cs
├── RepositoryContext.cs
├── RepositoryException.cs
└── SnapshotDomainRepository.cs
├── Serialization
├── IObjectSerializer.cs
├── ObjectBinarySerializer.cs
├── ObjectDataContractSerializer.cs
├── ObjectJsonSerializer.cs
├── ObjectXmlSerializer.cs
└── SerializationException.cs
├── ServiceLocator.cs
├── Services
└── ApplicationServices
│ └── DataTransferObject.cs
├── Snapshots
├── ISnapshot.cs
├── ISnapshotOrignator.cs
├── Providers
│ ├── EventNumberSnapshotProvider.cs
│ ├── ISnapshotProvider.cs
│ ├── SnapshotProvider.cs
│ ├── SnapshotProviderOption.cs
│ ├── StorageBasedSnapshotProvider.cs
│ └── SuppressedSnapshotProvider.cs
├── Serialization
│ ├── ISnapshotSerializer.cs
│ ├── SnapshotBinarySerializer.cs
│ ├── SnapshotDataContractSerializer.cs
│ ├── SnapshotJsonSerializer.cs
│ └── SnapshotXmlSerializer.cs
├── Snapshot.cs
└── SnapshotDataObject.cs
├── SourcedAggregateRoot.cs
├── Specifications
├── AndNotSpecification.cs
├── AndSpecification.cs
├── AnySpecification.cs
├── CompositeSpecification.cs
├── ExpressionFuncExtender.cs
├── ExpressionSpecification.cs
├── ICompositeSpecification.cs
├── ISpecification.cs
├── ISpecificationParser.cs
├── NoneSpecification.cs
├── NotSpecification.cs
├── OrSpecification.cs
├── ParameterRebinder.cs
├── Specification.cs
└── SpecificationException.cs
├── Storage
├── Builders
│ ├── IWhereClauseBuilder.cs
│ ├── WhereClauseBuildResult.cs
│ └── WhereClauseBuilder.cs
├── IStorage.cs
├── IStorageMappingResolver.cs
├── PropertyBag.cs
├── RdbmsStorage.cs
├── SortOrder.cs
├── StorageException.cs
├── StorageMappingSchema.cs
├── StorageMappingSchema.xsd
└── XmlStorageMappingResolver.cs
├── Transactions
├── DistributedTransactionCoordinator.cs
├── ITransactionCoordinator.cs
├── SuppressedTransactionCoordinator.cs
├── TransactionCoordinator.cs
└── TransactionCoordinatorFactory.cs
├── Utils.cs
├── key.snk
└── packages.config
/.gitignore:
--------------------------------------------------------------------------------
1 | # Build Folders (you can keep bin if you'd like, to store dlls and pdbs)
2 | [Bb]in/
3 | [Oo]bj/
4 |
5 | # mstest test results
6 | TestResults
7 |
8 | ## Ignore Visual Studio temporary files, build results, and
9 | ## files generated by popular Visual Studio add-ons.
10 |
11 | # User-specific files
12 | *.suo
13 | *.user
14 | *.sln.docstates
15 |
16 | # Build results
17 | [Dd]ebug/
18 | [Rr]elease/
19 | x64/
20 | *_i.c
21 | *_p.c
22 | *.ilk
23 | *.meta
24 | *.obj
25 | *.pch
26 | *.pdb
27 | *.pgc
28 | *.pgd
29 | *.rsp
30 | *.sbr
31 | *.tlb
32 | *.tli
33 | *.tlh
34 | *.tmp
35 | *.log
36 | *.vspscc
37 | *.vssscc
38 | .builds
39 |
40 | # Visual C++ cache files
41 | ipch/
42 | *.aps
43 | *.ncb
44 | *.opensdf
45 | *.sdf
46 |
47 | # Visual Studio profiler
48 | *.psess
49 | *.vsp
50 | *.vspx
51 |
52 | # Guidance Automation Toolkit
53 | *.gpState
54 |
55 | # ReSharper is a .NET coding add-in
56 | _ReSharper*
57 |
58 | # NCrunch
59 | *.ncrunch*
60 | .*crunch*.local.xml
61 |
62 | # Installshield output folder
63 | [Ee]xpress
64 |
65 | # DocProject is a documentation generator add-in
66 | DocProject/buildhelp/
67 | DocProject/Help/*.HxT
68 | DocProject/Help/*.HxC
69 | DocProject/Help/*.hhc
70 | DocProject/Help/*.hhk
71 | DocProject/Help/*.hhp
72 | DocProject/Help/Html2
73 | DocProject/Help/html
74 |
75 | # Click-Once directory
76 | publish
77 |
78 | # Publish Web Output
79 | *.Publish.xml
80 |
81 | # NuGet Packages Directory
82 | packages
83 |
84 | # NuGet Package Files
85 | *.nupkg
86 | # *.nuspec
87 |
88 | # Windows Azure Build Output
89 | csx
90 | *.build.csdef
91 |
92 | # Windows Store app package directory
93 | AppPackages/
94 |
95 | #Apworks CoreDebug/ReleaseDeployment directory
96 | CoreDebugDeployment/
97 | CoreReleaseDeployment/
98 |
99 | # Others
100 | [Bb]in
101 | [Oo]bj
102 | sql
103 | TestResults
104 | [Tt]est[Rr]esult*
105 | *.Cache
106 | ClientBin
107 | [Ss]tyle[Cc]op.*
108 | ~$*
109 | *.dbmdl
110 | Generated_Code #added for RIA/Silverlight projects
111 |
112 | # Backup & report files from converting an old project file to a newer
113 | # Visual Studio version. Backup files are not needed, because we have git ;-)
114 | _UpgradeReport_Files/
115 | Backup*/
116 | UpgradeLog*.XML
--------------------------------------------------------------------------------
/.nuget/NuGet.Config:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 |
5 |
6 |
--------------------------------------------------------------------------------
/.nuget/NuGet.exe:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/daxnet/Apworks/6de4b83e94c1e39b55c93590617e4491880eed39/.nuget/NuGet.exe
--------------------------------------------------------------------------------
/Apworks.vsmdi:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 |
5 |
6 |
--------------------------------------------------------------------------------
/Local.testsettings:
--------------------------------------------------------------------------------
1 |
2 |
3 | These are default test settings for a local test run.
4 |
5 |
6 |
7 |
8 |
9 |
10 |
--------------------------------------------------------------------------------
/Tests/Apworks.Tests.Buses/CommandHandlers/ChangeEmailCommandHandler.cs:
--------------------------------------------------------------------------------
1 | using Apworks.Commands;
2 | using Apworks.Repositories;
3 | using Apworks.Tests.Buses.Commands;
4 | using Apworks.Tests.Common.AggregateRoots;
5 |
6 | namespace Apworks.Tests.Buses.CommandHandlers
7 | {
8 | public class ChangeEmailCommandHandler : CommandHandler
9 | {
10 | public ChangeEmailCommandHandler()
11 | {
12 | }
13 |
14 | public override void Handle(ChangeEmailCommand command)
15 | {
16 | using (IDomainRepository repository = this.DomainRepository)
17 | {
18 | var cust = repository.Get(command.CustomerId);
19 | for (int i = 0; i < 1005; i++)
20 | {
21 | cust.ChangeEmail(command.NewEmail);
22 | }
23 | repository.Save(cust);
24 | repository.Commit();
25 | }
26 | }
27 | }
28 | }
29 |
--------------------------------------------------------------------------------
/Tests/Apworks.Tests.Buses/Commands/ChangeEmailCommand.cs:
--------------------------------------------------------------------------------
1 | using Apworks.Commands;
2 | using System;
3 |
4 | namespace Apworks.Tests.Buses.Commands
5 | {
6 | public class ChangeEmailCommand : Command
7 | {
8 | public string NewEmail { get; set; }
9 | public Guid CustomerId { get; set; }
10 | public ChangeEmailCommand(Guid customerId, string newEmail)
11 | {
12 | CustomerId = customerId;
13 | NewEmail = newEmail;
14 | }
15 | }
16 | }
17 |
--------------------------------------------------------------------------------
/Tests/Apworks.Tests.Buses/Properties/AssemblyInfo.cs:
--------------------------------------------------------------------------------
1 | using System.Reflection;
2 | using System.Runtime.InteropServices;
3 |
4 | // General Information about an assembly is controlled through the following
5 | // set of attributes. Change these attribute values to modify the information
6 | // associated with an assembly.
7 | [assembly: AssemblyTitle("Apworks.Tests.Buses")]
8 | [assembly: AssemblyDescription("")]
9 | [assembly: AssemblyConfiguration("")]
10 | [assembly: AssemblyCompany("HP")]
11 | [assembly: AssemblyProduct("Apworks.Tests.Buses")]
12 | [assembly: AssemblyCopyright("Copyright © HP 2011")]
13 | [assembly: AssemblyTrademark("")]
14 | [assembly: AssemblyCulture("")]
15 |
16 | // Setting ComVisible to false makes the types in this assembly not visible
17 | // to COM components. If you need to access a type in this assembly from
18 | // COM, set the ComVisible attribute to true on that type.
19 | [assembly: ComVisible(false)]
20 |
21 | // The following GUID is for the ID of the typelib if this project is exposed to COM
22 | [assembly: Guid("66f305fa-36c0-4bf4-9eb1-473692ac66b6")]
23 |
24 | // Version information for an assembly consists of the following four values:
25 | //
26 | // Major Version
27 | // Minor Version
28 | // Build Number
29 | // Revision
30 | //
31 | // You can specify all the values or you can default the Build and Revision Numbers
32 | // by using the '*' as shown below:
33 | [assembly: AssemblyVersion("1.0.0.0")]
34 | [assembly: AssemblyFileVersion("1.0.0.0")]
35 |
--------------------------------------------------------------------------------
/Tests/Apworks.Tests.Buses/StorageMappings.xml:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 |
5 |
6 |
7 |
8 |
9 |
10 |
11 |
12 |
13 |
14 |
15 |
16 |
--------------------------------------------------------------------------------
/Tests/Apworks.Tests.Buses/app.config:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 |
5 |
6 |
7 |
8 |
9 |
10 |
11 |
12 |
--------------------------------------------------------------------------------
/Tests/Apworks.Tests.Common/AggregateRoots/Customer.cs:
--------------------------------------------------------------------------------
1 | using System;
2 |
3 | namespace Apworks.Tests.Common.AggregateRoots
4 | {
5 | public class Customer : IAggregateRoot
6 | {
7 | public virtual string Username { get; set; }
8 | public virtual string Password { get; set; }
9 | public virtual string FirstName { get; set; }
10 | public virtual string LastName { get; set; }
11 | public virtual string Email { get; set; }
12 | public virtual DateTime Birth { get; set; }
13 | public virtual int Sequence { get; set; }
14 |
15 | #region Public Methods
16 | ///
17 | /// Returns the hash code for current aggregate root.
18 | ///
19 | /// The calculated hash code for the current aggregate root.
20 | public override int GetHashCode()
21 | {
22 | return Utils.GetHashCode(this.ID.GetHashCode());
23 | }
24 | ///
25 | /// Returns a value indicating whether this instance is equal to a specified
26 | /// object.
27 | ///
28 | /// An object to compare with this instance.
29 | /// True if obj is an instance of the type and equals the value of this
30 | /// instance; otherwise, false.
31 | public override bool Equals(object obj)
32 | {
33 | if (ReferenceEquals(this, obj))
34 | return true;
35 | if (obj == null)
36 | return false;
37 | Customer other = obj as Customer;
38 | if ((object)other == (object)null)
39 | return false;
40 | return other.ID == this.ID;
41 | }
42 | #endregion
43 |
44 | #region IEntity Members
45 | ///
46 | /// Gets or sets the identifier of the aggregate root.
47 | ///
48 | public virtual Guid ID { get; set; }
49 | #endregion
50 |
51 | }
52 | }
53 |
--------------------------------------------------------------------------------
/Tests/Apworks.Tests.Common/AggregateRoots/EFCustomer.cs:
--------------------------------------------------------------------------------
1 | using System;
2 | using System.Collections.Generic;
3 | using System.Linq;
4 | using System.Text;
5 |
6 | namespace Apworks.Tests.Common.AggregateRoots
7 | {
8 | public class EFCustomer : IAggregateRoot
9 | {
10 | public string UserName { get; set; }
11 | public string Password { get; set; }
12 | public EFAddress Address { get; set; }
13 | public string Email { get; set; }
14 | public int Sequence { get; set; }
15 |
16 | #region IEntity Members
17 |
18 | public Guid ID
19 | {
20 | get;
21 | set;
22 | }
23 |
24 | #endregion
25 | }
26 | }
27 |
--------------------------------------------------------------------------------
/Tests/Apworks.Tests.Common/AggregateRoots/EFCustomerNote.cs:
--------------------------------------------------------------------------------
1 | using System;
2 | using System.Collections.Generic;
3 | using System.Linq;
4 | using System.Text;
5 |
6 | namespace Apworks.Tests.Common.AggregateRoots
7 | {
8 | public class EFCustomerNote : IAggregateRoot
9 | {
10 |
11 | public EFCustomer Customer { get; set; }
12 | public List Notes { get; set; }
13 |
14 | #region IEntity Members
15 |
16 | public Guid ID
17 | {
18 | get;
19 | set;
20 | }
21 |
22 | #endregion
23 |
24 | }
25 | }
26 |
--------------------------------------------------------------------------------
/Tests/Apworks.Tests.Common/AggregateRoots/EFNote.cs:
--------------------------------------------------------------------------------
1 | using System;
2 | using System.Collections.Generic;
3 | using System.Linq;
4 | using System.Text;
5 |
6 | namespace Apworks.Tests.Common.AggregateRoots
7 | {
8 | public class EFNote : IEntity
9 | {
10 |
11 | public string NoteText { get; set; }
12 |
13 | #region IEntity Members
14 |
15 | public Guid ID
16 | {
17 | get;
18 | set;
19 | }
20 |
21 | #endregion
22 |
23 | }
24 | }
25 |
--------------------------------------------------------------------------------
/Tests/Apworks.Tests.Common/AggregateRoots/SourcedCustomerSnapshot.cs:
--------------------------------------------------------------------------------
1 | using System;
2 |
3 | namespace Apworks.Tests.Common.AggregateRoots
4 | {
5 | [Serializable]
6 | public class SourcedCustomerSnapshot : Snapshots.Snapshot
7 | {
8 | public string Username { get; set; }
9 | public string Password { get; set; }
10 | public string FirstName { get; set; }
11 | public string LastName { get; set; }
12 | public string Email { get; set; }
13 | public DateTime Birth { get; set; }
14 | }
15 | }
16 |
--------------------------------------------------------------------------------
/Tests/Apworks.Tests.Common/App.config:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 |
5 |
6 |
7 |
8 |
9 |
10 |
11 |
12 |
13 |
14 |
15 |
16 |
17 |
18 |
19 |
20 |
21 |
22 |
23 |
24 |
25 |
26 |
27 |
28 |
29 |
30 |
31 |
32 |
33 |
34 |
--------------------------------------------------------------------------------
/Tests/Apworks.Tests.Common/Commands/CreateCustomerCommand.cs:
--------------------------------------------------------------------------------
1 | using Apworks.Commands;
2 |
3 | namespace Apworks.Tests.Common.Commands
4 | {
5 | public class CreateCustomerCommand : Command
6 | {
7 | private string name;
8 |
9 | public string Name
10 | {
11 | get { return name; }
12 | set { name = value; }
13 | }
14 |
15 | }
16 | }
17 |
--------------------------------------------------------------------------------
/Tests/Apworks.Tests.Common/Customer.hbm.xml:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 |
5 |
6 |
7 |
8 |
9 |
10 |
11 |
12 |
13 |
14 |
15 |
16 |
--------------------------------------------------------------------------------
/Tests/Apworks.Tests.Common/EFContexts/EFTestContext.cs:
--------------------------------------------------------------------------------
1 | using System.Data.Entity;
2 | using Apworks.Tests.Common.AggregateRoots;
3 | using System.ComponentModel.DataAnnotations.Schema;
4 |
5 | namespace Apworks.Tests.Common.EFContexts
6 | {
7 | public class EFTestContext : DbContext
8 | {
9 | public EFTestContext()
10 | : base("EFTestContext")
11 | { }
12 |
13 | public DbSet Customers
14 | {
15 | get { return Set(); }
16 | }
17 |
18 | public DbSet CustomerNotes
19 | {
20 | get { return Set(); }
21 | }
22 |
23 | protected override void OnModelCreating(DbModelBuilder modelBuilder)
24 | {
25 | modelBuilder.Entity().HasKey(p => p.ID);
26 | modelBuilder.Entity().Property(p => p.ID).IsRequired().HasDatabaseGeneratedOption(DatabaseGeneratedOption.Identity);
27 | base.OnModelCreating(modelBuilder);
28 | }
29 | }
30 | }
31 |
--------------------------------------------------------------------------------
/Tests/Apworks.Tests.Common/Events/ChangeCustomerNameDomainEvent.cs:
--------------------------------------------------------------------------------
1 | using System;
2 | using Apworks.Events;
3 |
4 | namespace Apworks.Tests.Common.Events
5 | {
6 | [Serializable]
7 | public class ChangeCustomerNameDomainEvent : DomainEvent
8 | {
9 | public string FirstName { get; set; }
10 | public string LastName { get; set; }
11 | }
12 | }
13 |
--------------------------------------------------------------------------------
/Tests/Apworks.Tests.Common/Events/ChangeEmailDomainEvent.cs:
--------------------------------------------------------------------------------
1 | using System;
2 | using Apworks.Events;
3 |
4 | namespace Apworks.Tests.Common.Events
5 | {
6 | [Serializable]
7 | public class ChangeEmailDomainEvent : DomainEvent
8 | {
9 | public string Email { get; set; }
10 | }
11 | }
12 |
--------------------------------------------------------------------------------
/Tests/Apworks.Tests.Common/Events/CreateCustomerDomainEvent.cs:
--------------------------------------------------------------------------------
1 | using System;
2 | using Apworks.Events;
3 |
4 | namespace Apworks.Tests.Common.Events
5 | {
6 | [Serializable]
7 | public class CreateCustomerDomainEvent : DomainEvent
8 | {
9 | public string Username { get; set; }
10 | public string FirstName { get; set; }
11 | public string LastName { get; set; }
12 | }
13 | }
14 |
--------------------------------------------------------------------------------
/Tests/Apworks.Tests.Common/ExceptionHandlers/ExceptionExceptionHandler.cs:
--------------------------------------------------------------------------------
1 | using System;
2 | using Apworks.Exceptions;
3 |
4 | namespace Apworks.Tests.Common.ExceptionHandlers
5 | {
6 | public class ExceptionExceptionHandler : ExceptionHandler
7 | {
8 | protected override bool DoHandle(Exception ex)
9 | {
10 | Helper.WriteTempFile("ExceptionExceptionHandler");
11 | return true;
12 | }
13 | }
14 | }
15 |
--------------------------------------------------------------------------------
/Tests/Apworks.Tests.Common/ExceptionHandlers/InvalidOperationExceptionHandler.cs:
--------------------------------------------------------------------------------
1 | using System;
2 | using Apworks.Exceptions;
3 |
4 | namespace Apworks.Tests.Common.ExceptionHandlers
5 | {
6 | public class InvalidOperationExceptionHandler : ExceptionHandler
7 | {
8 | protected override bool DoHandle(InvalidOperationException ex)
9 | {
10 | Helper.WriteTempFile("InvalidOperationExceptionHandler");
11 | return true;
12 | }
13 | }
14 | }
15 |
--------------------------------------------------------------------------------
/Tests/Apworks.Tests.Common/ExceptionHandlers/SystemExceptionHandler.cs:
--------------------------------------------------------------------------------
1 | using System;
2 | using Apworks.Exceptions;
3 |
4 | namespace Apworks.Tests.Common.ExceptionHandlers
5 | {
6 | public class SystemExceptionHandler : ExceptionHandler
7 | {
8 | protected override bool DoHandle(SystemException ex)
9 | {
10 | Helper.WriteTempFile("SystemExceptionHandler");
11 | return true;
12 | }
13 | }
14 | }
15 |
--------------------------------------------------------------------------------
/Tests/Apworks.Tests.Common/Interceptors/ExceptionHandlingInterceptor.cs:
--------------------------------------------------------------------------------
1 | using Castle.DynamicProxy;
2 |
3 | namespace Apworks.Tests.Common.Interceptors
4 | {
5 | public class ExceptionHandlingInterceptor : IInterceptor
6 | {
7 | #region IInterceptor Members
8 |
9 | public void Intercept(IInvocation invocation)
10 | {
11 | invocation.Proceed();
12 | }
13 |
14 | #endregion
15 | }
16 | }
17 |
--------------------------------------------------------------------------------
/Tests/Apworks.Tests.Common/Interceptors/LoggingInterceptor.cs:
--------------------------------------------------------------------------------
1 | using Castle.DynamicProxy;
2 |
3 | namespace Apworks.Tests.Common.Interceptors
4 | {
5 | public class LoggingInterceptor : IInterceptor
6 | {
7 | #region IInterceptor Members
8 |
9 | public void Intercept(IInvocation invocation)
10 | {
11 | invocation.Proceed();
12 | }
13 |
14 | #endregion
15 | }
16 | }
17 |
--------------------------------------------------------------------------------
/Tests/Apworks.Tests.Common/Interceptors/MockInterceptorA.cs:
--------------------------------------------------------------------------------
1 | using System;
2 | using Castle.DynamicProxy;
3 |
4 | namespace Apworks.Tests.Common.Interceptors
5 | {
6 | public class MockInterceptorA : IInterceptor
7 | {
8 | public static event EventHandler InterceptOccur;
9 |
10 | protected static void OnIntercept()
11 | {
12 | var tmp = InterceptOccur;
13 | if (tmp != null)
14 | tmp(null, EventArgs.Empty);
15 | }
16 |
17 | #region IInterceptor Members
18 |
19 | public void Intercept(IInvocation invocation)
20 | {
21 | OnIntercept();
22 | invocation.Proceed();
23 | }
24 |
25 | #endregion
26 | }
27 | }
28 |
--------------------------------------------------------------------------------
/Tests/Apworks.Tests.Common/Interceptors/MockInterceptorB.cs:
--------------------------------------------------------------------------------
1 | using System;
2 | using Castle.DynamicProxy;
3 |
4 | namespace Apworks.Tests.Common.Interceptors
5 | {
6 | public class MockInterceptorB : IInterceptor
7 | {
8 | public static event EventHandler InterceptOccur;
9 |
10 | protected static void OnIntercept()
11 | {
12 | var tmp = InterceptOccur;
13 | if (tmp != null)
14 | tmp(null, EventArgs.Empty);
15 | }
16 |
17 | #region IInterceptor Members
18 |
19 | public void Intercept(IInvocation invocation)
20 | {
21 | OnIntercept();
22 | invocation.Proceed();
23 | }
24 |
25 | #endregion
26 | }
27 | }
28 |
--------------------------------------------------------------------------------
/Tests/Apworks.Tests.Common/MessageHandlers/CreateCustomerCommandHandler.cs:
--------------------------------------------------------------------------------
1 | using Apworks.Commands;
2 |
3 | namespace Apworks.Tests.Common.MessageHandlers
4 | {
5 | public class CreateCustomerCommandHandler : CommandHandler
6 | {
7 | public override void Handle(Commands.CreateCustomerCommand command)
8 | {
9 | }
10 | }
11 | }
12 |
--------------------------------------------------------------------------------
/Tests/Apworks.Tests.Common/MessageHandlers/CustomerCreatedEventHandler.cs:
--------------------------------------------------------------------------------
1 | using Apworks.Events;
2 |
3 | namespace Apworks.Tests.Common.MessageHandlers
4 | {
5 | public class CustomerCreatedEventHandler : IEventHandler
6 | {
7 | #region IHandler Members
8 |
9 | public void Handle(Events.CreateCustomerDomainEvent message)
10 | {
11 |
12 | }
13 |
14 | #endregion
15 |
16 | //#region IHandler Members
17 |
18 | //public bool Handle(object message)
19 | //{
20 | // return true;
21 | //}
22 |
23 | //#endregion
24 | }
25 | }
26 |
--------------------------------------------------------------------------------
/Tests/Apworks.Tests.Common/MessageHandlers/EmailChangedEventHandler.cs:
--------------------------------------------------------------------------------
1 |
2 | namespace Apworks.Tests.Common.MessageHandlers
3 | {
4 | public class EmailChangedEventHandler : Apworks.Events.IEventHandler
5 | {
6 | public void Handle(Events.ChangeEmailDomainEvent message)
7 | {
8 | }
9 | }
10 | }
11 |
--------------------------------------------------------------------------------
/Tests/Apworks.Tests.Common/MessageHandlers/YetAnotherEmailChangedEventHandler.cs:
--------------------------------------------------------------------------------
1 |
2 | namespace Apworks.Tests.Common.MessageHandlers
3 | {
4 | public class YetAnotherEmailChangedEventHandler : Apworks.Events.IEventHandler
5 | {
6 | public void Handle(Events.ChangeEmailDomainEvent message)
7 | {
8 | throw new System.Exception(""); // simulate process failed.
9 | }
10 | }
11 | }
12 |
--------------------------------------------------------------------------------
/Tests/Apworks.Tests.Common/MongoDB/MongoDBRepositoryContextSettings.cs:
--------------------------------------------------------------------------------
1 | using System;
2 | using System.Collections.Generic;
3 | using System.Linq;
4 | using System.Text;
5 | using Apworks.Repositories.MongoDB;
6 | using MongoDB.Driver;
7 |
8 | namespace Apworks.Tests.Common.MongoDB
9 | {
10 | public class MongoDBRepositoryContextSettings : IMongoDBRepositoryContextSettings
11 | {
12 | #region IMongoDBRepositoryContextSettings Members
13 |
14 | public MongoServerSettings ServerSettings
15 | {
16 | get
17 | {
18 | var settings = new MongoServerSettings();
19 | settings.Server = new MongoServerAddress("localhost");
20 | settings.WriteConcern = WriteConcern.Acknowledged;
21 | return settings;
22 | }
23 | }
24 |
25 | public MongoDatabaseSettings GetDatabaseSettings(MongoServer server)
26 | {
27 | return new MongoDatabaseSettings();
28 | }
29 |
30 | public MapTypeToCollectionNameDelegate MapTypeToCollectionName
31 | {
32 | get { return null; }
33 | }
34 |
35 | public string DatabaseName
36 | {
37 | get { return Helper.MongoDB_Database; }
38 | }
39 |
40 | #endregion
41 | }
42 | }
43 |
--------------------------------------------------------------------------------
/Tests/Apworks.Tests.Common/Properties/AssemblyInfo.cs:
--------------------------------------------------------------------------------
1 | using System.Reflection;
2 | using System.Runtime.InteropServices;
3 |
4 | // General Information about an assembly is controlled through the following
5 | // set of attributes. Change these attribute values to modify the information
6 | // associated with an assembly.
7 | [assembly: AssemblyTitle("Apworks.Tests.Common")]
8 | [assembly: AssemblyDescription("")]
9 | [assembly: AssemblyConfiguration("")]
10 | [assembly: AssemblyCompany("HP")]
11 | [assembly: AssemblyProduct("Apworks.Tests.Common")]
12 | [assembly: AssemblyCopyright("Copyright © HP 2011")]
13 | [assembly: AssemblyTrademark("")]
14 | [assembly: AssemblyCulture("")]
15 |
16 | // Setting ComVisible to false makes the types in this assembly not visible
17 | // to COM components. If you need to access a type in this assembly from
18 | // COM, set the ComVisible attribute to true on that type.
19 | [assembly: ComVisible(false)]
20 |
21 | // The following GUID is for the ID of the typelib if this project is exposed to COM
22 | [assembly: Guid("91def631-0112-4674-ae30-0d333e0a254a")]
23 |
24 | // Version information for an assembly consists of the following four values:
25 | //
26 | // Major Version
27 | // Minor Version
28 | // Build Number
29 | // Revision
30 | //
31 | // You can specify all the values or you can default the Build and Revision Numbers
32 | // by using the '*' as shown below:
33 | // [assembly: AssemblyVersion("1.0.*")]
34 | [assembly: AssemblyVersion("1.0.0.0")]
35 | [assembly: AssemblyFileVersion("1.0.0.0")]
36 |
--------------------------------------------------------------------------------
/Tests/Apworks.Tests.Common/SourcedCustomer.hbm.xml:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 |
7 |
8 |
9 |
10 |
11 |
12 |
13 |
14 |
15 |
16 |
--------------------------------------------------------------------------------
/Tests/Apworks.Tests.Common/packages.config:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 |
5 |
6 |
7 |
8 |
9 |
10 |
11 |
12 |
13 |
--------------------------------------------------------------------------------
/Tests/Apworks.Tests.Configuration/FluentInterfaceTests.cs:
--------------------------------------------------------------------------------
1 | using System;
2 | using Microsoft.VisualStudio.TestTools.UnitTesting;
3 | using Apworks.Application;
4 | using Apworks.Config.Fluent;
5 | using Apworks.Config;
6 | using Apworks.Repositories;
7 | using Apworks.Repositories.NHibernate;
8 |
9 | namespace Apworks.Tests.Configuration
10 | {
11 | [TestClass]
12 | public class FluentInterfaceTests
13 | {
14 | //[TestMethod]
15 | //public void Configuration_CreateAppWithDefaultSettingsTest()
16 | //{
17 | // var application = AppRuntime.Instance.ConfigureApworks().WithDefaultSettings().UsingUnityContainer().Create();
18 | // application.Initialize += (s, e) =>
19 | // {
20 |
21 | // };
22 | // application.Start();
23 | // Assert.IsNotNull(application);
24 | //}
25 |
26 | [TestMethod]
27 | public void Configuration_AddCQRSMessageHandlerTest()
28 | {
29 | var application = AppRuntime.Instance
30 | .ConfigureApworks()
31 | .WithDefaultSettings()
32 | .AddMessageHandler(HandlerKind.Command, HandlerSourceType.Assembly, "1")
33 | .AddMessageHandler(HandlerKind.Event, HandlerSourceType.Type, "2")
34 | .UsingUnityContainer()
35 | .Create();
36 | application.Initialize += (s, e) =>
37 | {
38 |
39 | };
40 | application.Start();
41 | Assert.IsNotNull(application);
42 | Assert.AreEqual(2, application.ConfigSource.Config.Handlers.Count);
43 | }
44 |
45 | }
46 | }
47 |
--------------------------------------------------------------------------------
/Tests/Apworks.Tests.Configuration/Properties/AssemblyInfo.cs:
--------------------------------------------------------------------------------
1 | using System.Reflection;
2 | using System.Runtime.CompilerServices;
3 | using System.Runtime.InteropServices;
4 |
5 | // General Information about an assembly is controlled through the following
6 | // set of attributes. Change these attribute values to modify the information
7 | // associated with an assembly.
8 | [assembly: AssemblyTitle("Apworks.Tests.Configuration")]
9 | [assembly: AssemblyDescription("")]
10 | [assembly: AssemblyConfiguration("")]
11 | [assembly: AssemblyCompany("Hewlett-Packard Company")]
12 | [assembly: AssemblyProduct("Apworks.Tests.Configuration")]
13 | [assembly: AssemblyCopyright("Copyright © Hewlett-Packard Company 2013")]
14 | [assembly: AssemblyTrademark("")]
15 | [assembly: AssemblyCulture("")]
16 |
17 | // Setting ComVisible to false makes the types in this assembly not visible
18 | // to COM components. If you need to access a type in this assembly from
19 | // COM, set the ComVisible attribute to true on that type.
20 | [assembly: ComVisible(false)]
21 |
22 | // The following GUID is for the ID of the typelib if this project is exposed to COM
23 | [assembly: Guid("d1234ddd-d726-4010-a9b8-91f82de556f8")]
24 |
25 | // Version information for an assembly consists of the following four values:
26 | //
27 | // Major Version
28 | // Minor Version
29 | // Build Number
30 | // Revision
31 | //
32 | // You can specify all the values or you can default the Build and Revision Numbers
33 | // by using the '*' as shown below:
34 | // [assembly: AssemblyVersion("1.0.*")]
35 | [assembly: AssemblyVersion("1.0.0.0")]
36 | [assembly: AssemblyFileVersion("1.0.0.0")]
37 |
--------------------------------------------------------------------------------
/Tests/Apworks.Tests.Configuration/app.config:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 |
5 |
6 |
7 |
8 |
9 |
10 |
11 |
12 |
--------------------------------------------------------------------------------
/Tests/Apworks.Tests.Configuration/packages.config:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 |
--------------------------------------------------------------------------------
/Tests/Apworks.Tests.DomainEvents/AnotherDomainEvent.cs:
--------------------------------------------------------------------------------
1 | using Apworks.Events;
2 | using System;
3 | using System.Collections.Generic;
4 | using System.Linq;
5 | using System.Text;
6 |
7 | namespace Apworks.Tests.DomainEvents
8 | {
9 | [Serializable]
10 | public class AnotherDomainEvent : DomainEvent
11 | {
12 | }
13 |
14 | public class AnotherDomainEventHandler : IDomainEventHandler
15 | {
16 | #region IHandler Members
17 |
18 | public void Handle(AnotherDomainEvent message)
19 | {
20 | }
21 |
22 | #endregion
23 | }
24 |
25 | }
26 |
--------------------------------------------------------------------------------
/Tests/Apworks.Tests.DomainEvents/EventSourcedRepository_StorageMappings.xml:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 |
5 |
6 |
7 |
8 |
9 |
10 |
11 |
12 |
13 |
14 |
15 |
16 |
17 |
18 |
19 |
20 |
21 |
22 |
23 |
24 |
25 |
26 |
--------------------------------------------------------------------------------
/Tests/Apworks.Tests.DomainEvents/OneDomainEvent.cs:
--------------------------------------------------------------------------------
1 | using Apworks.Events;
2 | using System;
3 | using System.Collections.Generic;
4 | using System.Linq;
5 | using System.Text;
6 |
7 | namespace Apworks.Tests.DomainEvents
8 | {
9 | [Serializable]
10 | public class OneDomainEvent : DomainEvent
11 | {
12 | }
13 |
14 | public class OneDomainEventHandler : IDomainEventHandler
15 | {
16 | #region IHandler Members
17 |
18 | public void Handle(OneDomainEvent message)
19 | {
20 |
21 | }
22 |
23 | #endregion
24 | }
25 |
26 | public class OneDomainEventAnotherHandler : IDomainEventHandler
27 | {
28 | #region IHandler Members
29 |
30 | public void Handle(OneDomainEvent message)
31 | {
32 |
33 | }
34 |
35 | #endregion
36 | }
37 |
38 |
39 | }
40 |
--------------------------------------------------------------------------------
/Tests/Apworks.Tests.DomainEvents/Properties/AssemblyInfo.cs:
--------------------------------------------------------------------------------
1 | using System.Reflection;
2 | using System.Runtime.InteropServices;
3 |
4 | // General Information about an assembly is controlled through the following
5 | // set of attributes. Change these attribute values to modify the information
6 | // associated with an assembly.
7 | [assembly: AssemblyTitle("Apworks.Tests.DomainEvents")]
8 | [assembly: AssemblyDescription("")]
9 | [assembly: AssemblyConfiguration("")]
10 | [assembly: AssemblyCompany("HP")]
11 | [assembly: AssemblyProduct("Apworks.Tests.DomainEvents")]
12 | [assembly: AssemblyCopyright("Copyright © HP 2011")]
13 | [assembly: AssemblyTrademark("")]
14 | [assembly: AssemblyCulture("")]
15 |
16 | // Setting ComVisible to false makes the types in this assembly not visible
17 | // to COM components. If you need to access a type in this assembly from
18 | // COM, set the ComVisible attribute to true on that type.
19 | [assembly: ComVisible(false)]
20 |
21 | // The following GUID is for the ID of the typelib if this project is exposed to COM
22 | [assembly: Guid("76156afe-6108-4c07-8516-5f0978333ecc")]
23 |
24 | // Version information for an assembly consists of the following four values:
25 | //
26 | // Major Version
27 | // Minor Version
28 | // Build Number
29 | // Revision
30 | //
31 | // You can specify all the values or you can default the Build and Revision Numbers
32 | // by using the '*' as shown below:
33 | [assembly: AssemblyVersion("1.0.0.0")]
34 | [assembly: AssemblyFileVersion("1.0.0.0")]
35 |
--------------------------------------------------------------------------------
/Tests/Apworks.Tests.DomainEvents/app.config:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 |
5 |
6 |
7 |
8 |
9 |
10 |
11 |
12 |
13 |
14 |
15 |
16 |
--------------------------------------------------------------------------------
/Tests/Apworks.Tests.EventStore.MySql/Properties/AssemblyInfo.cs:
--------------------------------------------------------------------------------
1 | using System.Reflection;
2 | using System.Runtime.InteropServices;
3 |
4 | // General Information about an assembly is controlled through the following
5 | // set of attributes. Change these attribute values to modify the information
6 | // associated with an assembly.
7 | [assembly: AssemblyTitle("Apworks.Tests.EventStore.MySql")]
8 | [assembly: AssemblyDescription("")]
9 | [assembly: AssemblyConfiguration("")]
10 | [assembly: AssemblyCompany("HP")]
11 | [assembly: AssemblyProduct("Apworks.Tests.EventStore.MySql")]
12 | [assembly: AssemblyCopyright("Copyright © HP 2011")]
13 | [assembly: AssemblyTrademark("")]
14 | [assembly: AssemblyCulture("")]
15 |
16 | // Setting ComVisible to false makes the types in this assembly not visible
17 | // to COM components. If you need to access a type in this assembly from
18 | // COM, set the ComVisible attribute to true on that type.
19 | [assembly: ComVisible(false)]
20 |
21 | // The following GUID is for the ID of the typelib if this project is exposed to COM
22 | [assembly: Guid("52f8b4dd-676e-4dbf-a695-4bb9e5111766")]
23 |
24 | // Version information for an assembly consists of the following four values:
25 | //
26 | // Major Version
27 | // Minor Version
28 | // Build Number
29 | // Revision
30 | //
31 | // You can specify all the values or you can default the Build and Revision Numbers
32 | // by using the '*' as shown below:
33 | [assembly: AssemblyVersion("1.0.0.0")]
34 | [assembly: AssemblyFileVersion("1.0.0.0")]
35 |
--------------------------------------------------------------------------------
/Tests/Apworks.Tests.EventStore.MySql/StorageMappings.xml:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 |
5 |
6 |
7 |
8 |
9 |
10 |
11 |
12 |
13 |
14 |
15 |
16 |
17 |
18 |
19 |
20 |
21 |
22 |
23 |
24 |
25 |
26 |
--------------------------------------------------------------------------------
/Tests/Apworks.Tests.EventStore.MySql/app.config:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 |
5 |
6 |
7 |
8 |
9 |
10 |
11 |
12 |
13 |
14 |
15 |
16 |
17 |
--------------------------------------------------------------------------------
/Tests/Apworks.Tests.EventStore.MySql/packages.config:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 |
--------------------------------------------------------------------------------
/Tests/Apworks.Tests.EventStore.SqlExpress/Properties/AssemblyInfo.cs:
--------------------------------------------------------------------------------
1 | using System.Reflection;
2 | using System.Runtime.InteropServices;
3 |
4 | // General Information about an assembly is controlled through the following
5 | // set of attributes. Change these attribute values to modify the information
6 | // associated with an assembly.
7 | [assembly: AssemblyTitle("Apworks.Tests.EventStore.SqlExpress")]
8 | [assembly: AssemblyDescription("")]
9 | [assembly: AssemblyConfiguration("")]
10 | [assembly: AssemblyCompany("SunnyChen.ORG")]
11 | [assembly: AssemblyProduct("Apworks.Tests.EventStore.SqlExpress")]
12 | [assembly: AssemblyCopyright("Copyright © SunnyChen.ORG 2011")]
13 | [assembly: AssemblyTrademark("")]
14 | [assembly: AssemblyCulture("")]
15 |
16 | // Setting ComVisible to false makes the types in this assembly not visible
17 | // to COM components. If you need to access a type in this assembly from
18 | // COM, set the ComVisible attribute to true on that type.
19 | [assembly: ComVisible(false)]
20 |
21 | // The following GUID is for the ID of the typelib if this project is exposed to COM
22 | [assembly: Guid("562994d4-8fab-4e2a-aa6f-8a198c6b0390")]
23 |
24 | // Version information for an assembly consists of the following four values:
25 | //
26 | // Major Version
27 | // Minor Version
28 | // Build Number
29 | // Revision
30 | //
31 | // You can specify all the values or you can default the Build and Revision Numbers
32 | // by using the '*' as shown below:
33 | [assembly: AssemblyVersion("1.0.0.0")]
34 | [assembly: AssemblyFileVersion("1.0.0.0")]
35 |
--------------------------------------------------------------------------------
/Tests/Apworks.Tests.EventStore.SqlExpress/StorageMappings.xml:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 |
5 |
6 |
7 |
8 |
9 |
10 |
11 |
12 |
13 |
14 |
15 |
16 |
17 |
18 |
19 |
20 |
21 |
22 |
23 |
24 |
25 |
26 |
--------------------------------------------------------------------------------
/Tests/Apworks.Tests.EventStore.SqlExpress/app.config:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 |
5 |
6 |
7 |
8 |
9 |
10 |
11 |
12 |
--------------------------------------------------------------------------------
/Tests/Apworks.Tests.ExceptionHandling/ExceptionHandlingInvalidStorage.xml:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 |
5 |
6 |
7 |
8 |
9 |
10 |
11 |
12 |
13 |
14 |
15 |
16 |
--------------------------------------------------------------------------------
/Tests/Apworks.Tests.ExceptionHandling/Properties/AssemblyInfo.cs:
--------------------------------------------------------------------------------
1 | using System.Reflection;
2 | using System.Runtime.InteropServices;
3 |
4 | // General Information about an assembly is controlled through the following
5 | // set of attributes. Change these attribute values to modify the information
6 | // associated with an assembly.
7 | [assembly: AssemblyTitle("Apworks.Tests.ExceptionHandling")]
8 | [assembly: AssemblyDescription("")]
9 | [assembly: AssemblyConfiguration("")]
10 | [assembly: AssemblyCompany("SunnyChen.ORG")]
11 | [assembly: AssemblyProduct("Apworks.Tests.ExceptionHandling")]
12 | [assembly: AssemblyCopyright("Copyright © SunnyChen.ORG 2011")]
13 | [assembly: AssemblyTrademark("")]
14 | [assembly: AssemblyCulture("")]
15 |
16 | // Setting ComVisible to false makes the types in this assembly not visible
17 | // to COM components. If you need to access a type in this assembly from
18 | // COM, set the ComVisible attribute to true on that type.
19 | [assembly: ComVisible(false)]
20 |
21 | // The following GUID is for the ID of the typelib if this project is exposed to COM
22 | [assembly: Guid("4c069ef8-5389-4ee3-bd97-7edc841b0d63")]
23 |
24 | // Version information for an assembly consists of the following four values:
25 | //
26 | // Major Version
27 | // Minor Version
28 | // Build Number
29 | // Revision
30 | //
31 | // You can specify all the values or you can default the Build and Revision Numbers
32 | // by using the '*' as shown below:
33 | [assembly: AssemblyVersion("1.0.0.0")]
34 | [assembly: AssemblyFileVersion("1.0.0.0")]
35 |
--------------------------------------------------------------------------------
/Tests/Apworks.Tests.ExceptionHandling/app.config:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 |
5 |
6 |
7 |
8 |
9 |
10 |
11 |
12 |
13 |
14 |
15 |
16 |
--------------------------------------------------------------------------------
/Tests/Apworks.Tests.Generators/App.config:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 |
5 |
6 |
7 |
8 |
9 |
10 |
11 |
12 |
13 |
14 |
15 |
--------------------------------------------------------------------------------
/Tests/Apworks.Tests.Generators/Properties/AssemblyInfo.cs:
--------------------------------------------------------------------------------
1 | using System.Reflection;
2 | using System.Runtime.InteropServices;
3 |
4 | // General Information about an assembly is controlled through the following
5 | // set of attributes. Change these attribute values to modify the information
6 | // associated with an assembly.
7 | [assembly: AssemblyTitle("Apworks.Tests.Generators")]
8 | [assembly: AssemblyDescription("")]
9 | [assembly: AssemblyConfiguration("")]
10 | [assembly: AssemblyCompany("SunnyChen.ORG")]
11 | [assembly: AssemblyProduct("Apworks.Tests.Generators")]
12 | [assembly: AssemblyCopyright("Copyright © SunnyChen.ORG 2011")]
13 | [assembly: AssemblyTrademark("")]
14 | [assembly: AssemblyCulture("")]
15 |
16 | // Setting ComVisible to false makes the types in this assembly not visible
17 | // to COM components. If you need to access a type in this assembly from
18 | // COM, set the ComVisible attribute to true on that type.
19 | [assembly: ComVisible(false)]
20 |
21 | // The following GUID is for the ID of the typelib if this project is exposed to COM
22 | [assembly: Guid("848f8f86-19c9-4635-a62d-ffd25c5a0dac")]
23 |
24 | // Version information for an assembly consists of the following four values:
25 | //
26 | // Major Version
27 | // Minor Version
28 | // Build Number
29 | // Revision
30 | //
31 | // You can specify all the values or you can default the Build and Revision Numbers
32 | // by using the '*' as shown below:
33 | [assembly: AssemblyVersion("1.0.0.0")]
34 | [assembly: AssemblyFileVersion("1.0.0.0")]
35 |
--------------------------------------------------------------------------------
/Tests/Apworks.Tests.Interception/Properties/AssemblyInfo.cs:
--------------------------------------------------------------------------------
1 | using System.Reflection;
2 | using System.Runtime.InteropServices;
3 |
4 | // General Information about an assembly is controlled through the following
5 | // set of attributes. Change these attribute values to modify the information
6 | // associated with an assembly.
7 | [assembly: AssemblyTitle("Apworks.Tests.Interception")]
8 | [assembly: AssemblyDescription("")]
9 | [assembly: AssemblyConfiguration("")]
10 | [assembly: AssemblyCompany("Hewlett-Packard Company LTD.")]
11 | [assembly: AssemblyProduct("Apworks.Tests.Interception")]
12 | [assembly: AssemblyCopyright("Copyright © Hewlett-Packard Company LTD. 2011")]
13 | [assembly: AssemblyTrademark("")]
14 | [assembly: AssemblyCulture("")]
15 |
16 | // Setting ComVisible to false makes the types in this assembly not visible
17 | // to COM components. If you need to access a type in this assembly from
18 | // COM, set the ComVisible attribute to true on that type.
19 | [assembly: ComVisible(false)]
20 |
21 | // The following GUID is for the ID of the typelib if this project is exposed to COM
22 | [assembly: Guid("6e190e68-ede8-49aa-947d-7cc4745f747c")]
23 |
24 | // Version information for an assembly consists of the following four values:
25 | //
26 | // Major Version
27 | // Minor Version
28 | // Build Number
29 | // Revision
30 | //
31 | // You can specify all the values or you can default the Build and Revision Numbers
32 | // by using the '*' as shown below:
33 | [assembly: AssemblyVersion("1.0.0.0")]
34 | [assembly: AssemblyFileVersion("1.0.0.0")]
35 |
--------------------------------------------------------------------------------
/Tests/Apworks.Tests.Interception/app.config:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 |
5 |
6 |
7 |
8 |
9 |
10 |
11 |
12 |
--------------------------------------------------------------------------------
/Tests/Apworks.Tests.Interception/packages.config:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 |
5 |
6 |
--------------------------------------------------------------------------------
/Tests/Apworks.Tests.MessageDispatcher/Properties/AssemblyInfo.cs:
--------------------------------------------------------------------------------
1 | using System.Reflection;
2 | using System.Runtime.InteropServices;
3 |
4 | // General Information about an assembly is controlled through the following
5 | // set of attributes. Change these attribute values to modify the information
6 | // associated with an assembly.
7 | [assembly: AssemblyTitle("Apworks.Tests.MessageDispatcher")]
8 | [assembly: AssemblyDescription("")]
9 | [assembly: AssemblyConfiguration("")]
10 | [assembly: AssemblyCompany("Hewlett-Packard Company LTD.")]
11 | [assembly: AssemblyProduct("Apworks.Tests.MessageDispatcher")]
12 | [assembly: AssemblyCopyright("Copyright © Hewlett-Packard Company LTD. 2011")]
13 | [assembly: AssemblyTrademark("")]
14 | [assembly: AssemblyCulture("")]
15 |
16 | // Setting ComVisible to false makes the types in this assembly not visible
17 | // to COM components. If you need to access a type in this assembly from
18 | // COM, set the ComVisible attribute to true on that type.
19 | [assembly: ComVisible(false)]
20 |
21 | // The following GUID is for the ID of the typelib if this project is exposed to COM
22 | [assembly: Guid("eac7a37d-9ff7-4856-9e99-60a117281e31")]
23 |
24 | // Version information for an assembly consists of the following four values:
25 | //
26 | // Major Version
27 | // Minor Version
28 | // Build Number
29 | // Revision
30 | //
31 | // You can specify all the values or you can default the Build and Revision Numbers
32 | // by using the '*' as shown below:
33 | [assembly: AssemblyVersion("1.0.0.0")]
34 | [assembly: AssemblyFileVersion("1.0.0.0")]
35 |
--------------------------------------------------------------------------------
/Tests/Apworks.Tests.MessageDispatcher/app.config:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 |
5 |
6 |
7 |
8 |
9 |
10 |
11 |
12 |
13 |
14 |
15 |
16 |
--------------------------------------------------------------------------------
/Tests/Apworks.Tests.Repositories.DomainRepository/EventSourcedRepository_StorageMappings.xml:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 |
5 |
6 |
7 |
8 |
9 |
10 |
11 |
12 |
13 |
14 |
15 |
16 |
--------------------------------------------------------------------------------
/Tests/Apworks.Tests.Repositories.DomainRepository/Properties/AssemblyInfo.cs:
--------------------------------------------------------------------------------
1 | using System.Reflection;
2 | using System.Runtime.InteropServices;
3 |
4 | // General Information about an assembly is controlled through the following
5 | // set of attributes. Change these attribute values to modify the information
6 | // associated with an assembly.
7 | [assembly: AssemblyTitle("Apworks.Tests.Repositories.DomainRepository")]
8 | [assembly: AssemblyDescription("")]
9 | [assembly: AssemblyConfiguration("")]
10 | [assembly: AssemblyCompany("")]
11 | [assembly: AssemblyProduct("Apworks.Tests.Repositories.DomainRepository")]
12 | [assembly: AssemblyCopyright("Copyright © 2011")]
13 | [assembly: AssemblyTrademark("")]
14 | [assembly: AssemblyCulture("")]
15 |
16 | // Setting ComVisible to false makes the types in this assembly not visible
17 | // to COM components. If you need to access a type in this assembly from
18 | // COM, set the ComVisible attribute to true on that type.
19 | [assembly: ComVisible(false)]
20 |
21 | // The following GUID is for the ID of the typelib if this project is exposed to COM
22 | [assembly: Guid("ece951c8-25cb-4d82-b79a-1207b7663053")]
23 |
24 | // Version information for an assembly consists of the following four values:
25 | //
26 | // Major Version
27 | // Minor Version
28 | // Build Number
29 | // Revision
30 | //
31 | // You can specify all the values or you can default the Build and Revision Numbers
32 | // by using the '*' as shown below:
33 | [assembly: AssemblyVersion("1.0.0.0")]
34 | [assembly: AssemblyFileVersion("1.0.0.0")]
35 |
--------------------------------------------------------------------------------
/Tests/Apworks.Tests.Repositories.DomainRepository/SnapshotDomainRepository_StorageMappings.xml:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 |
5 |
6 |
7 |
8 |
9 |
10 |
11 |
--------------------------------------------------------------------------------
/Tests/Apworks.Tests.Repositories.DomainRepository/app.config:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 |
5 |
6 |
7 |
8 |
9 |
10 |
11 |
12 |
13 |
14 |
15 |
16 |
--------------------------------------------------------------------------------
/Tests/Apworks.Tests.Repositories.DomainRepository/packages.config:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 |
5 |
--------------------------------------------------------------------------------
/Tests/Apworks.Tests.Repositories.EntityFrameworkRepository/App.config:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 |
5 |
6 |
7 |
8 |
9 |
10 |
11 |
12 |
13 |
14 |
15 |
16 |
17 |
18 |
19 |
20 |
21 |
22 |
23 |
24 |
25 |
26 |
27 |
28 |
29 |
--------------------------------------------------------------------------------
/Tests/Apworks.Tests.Repositories.EntityFrameworkRepository/Properties/AssemblyInfo.cs:
--------------------------------------------------------------------------------
1 | using System.Reflection;
2 | using System.Runtime.CompilerServices;
3 | using System.Runtime.InteropServices;
4 |
5 | // General Information about an assembly is controlled through the following
6 | // set of attributes. Change these attribute values to modify the information
7 | // associated with an assembly.
8 | [assembly: AssemblyTitle("Apworks.Tests.Repositories.EntityFrameworkRepository")]
9 | [assembly: AssemblyDescription("")]
10 | [assembly: AssemblyConfiguration("")]
11 | [assembly: AssemblyCompany("Hewlett-Packard Company")]
12 | [assembly: AssemblyProduct("Apworks.Tests.Repositories.EntityFrameworkRepository")]
13 | [assembly: AssemblyCopyright("Copyright © Hewlett-Packard Company 2012")]
14 | [assembly: AssemblyTrademark("")]
15 | [assembly: AssemblyCulture("")]
16 |
17 | // Setting ComVisible to false makes the types in this assembly not visible
18 | // to COM components. If you need to access a type in this assembly from
19 | // COM, set the ComVisible attribute to true on that type.
20 | [assembly: ComVisible(false)]
21 |
22 | // The following GUID is for the ID of the typelib if this project is exposed to COM
23 | [assembly: Guid("1ec23ecc-c1a6-4acb-b90d-c55342f16bff")]
24 |
25 | // Version information for an assembly consists of the following four values:
26 | //
27 | // Major Version
28 | // Minor Version
29 | // Build Number
30 | // Revision
31 | //
32 | // You can specify all the values or you can default the Build and Revision Numbers
33 | // by using the '*' as shown below:
34 | [assembly: AssemblyVersion("1.0.0.0")]
35 | [assembly: AssemblyFileVersion("1.0.0.0")]
36 |
--------------------------------------------------------------------------------
/Tests/Apworks.Tests.Repositories.EntityFrameworkRepository/packages.config:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 |
--------------------------------------------------------------------------------
/Tests/Apworks.Tests.Repositories.MongoDB/Properties/AssemblyInfo.cs:
--------------------------------------------------------------------------------
1 | using System.Reflection;
2 | using System.Runtime.CompilerServices;
3 | using System.Runtime.InteropServices;
4 |
5 | // General Information about an assembly is controlled through the following
6 | // set of attributes. Change these attribute values to modify the information
7 | // associated with an assembly.
8 | [assembly: AssemblyTitle("Apworks.Tests.Repositories.MongoDB")]
9 | [assembly: AssemblyDescription("")]
10 | [assembly: AssemblyConfiguration("")]
11 | [assembly: AssemblyCompany("Hewlett-Packard Company")]
12 | [assembly: AssemblyProduct("Apworks.Tests.Repositories.MongoDB")]
13 | [assembly: AssemblyCopyright("Copyright © Hewlett-Packard Company 2012")]
14 | [assembly: AssemblyTrademark("")]
15 | [assembly: AssemblyCulture("")]
16 |
17 | // Setting ComVisible to false makes the types in this assembly not visible
18 | // to COM components. If you need to access a type in this assembly from
19 | // COM, set the ComVisible attribute to true on that type.
20 | [assembly: ComVisible(false)]
21 |
22 | // The following GUID is for the ID of the typelib if this project is exposed to COM
23 | [assembly: Guid("96f8ea1e-f5ca-4e00-9f36-880059bdcfc0")]
24 |
25 | // Version information for an assembly consists of the following four values:
26 | //
27 | // Major Version
28 | // Minor Version
29 | // Build Number
30 | // Revision
31 | //
32 | // You can specify all the values or you can default the Build and Revision Numbers
33 | // by using the '*' as shown below:
34 | [assembly: AssemblyVersion("1.0.0.0")]
35 | [assembly: AssemblyFileVersion("1.0.0.0")]
36 |
--------------------------------------------------------------------------------
/Tests/Apworks.Tests.Repositories.MongoDB/app.config:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 |
5 |
6 |
7 |
8 |
9 |
10 |
11 |
12 |
--------------------------------------------------------------------------------
/Tests/Apworks.Tests.Repositories.MongoDB/packages.config:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 |
5 |
6 |
7 |
--------------------------------------------------------------------------------
/Tests/Apworks.Tests.Repositories.NHibernateRepository/Properties/AssemblyInfo.cs:
--------------------------------------------------------------------------------
1 | using System.Reflection;
2 | using System.Runtime.InteropServices;
3 |
4 | // General Information about an assembly is controlled through the following
5 | // set of attributes. Change these attribute values to modify the information
6 | // associated with an assembly.
7 | [assembly: AssemblyTitle("Apworks.Tests.Repositories.NHibernateRepository")]
8 | [assembly: AssemblyDescription("")]
9 | [assembly: AssemblyConfiguration("")]
10 | [assembly: AssemblyCompany("HP")]
11 | [assembly: AssemblyProduct("Apworks.Tests.Repositories.NHibernateRepository")]
12 | [assembly: AssemblyCopyright("Copyright © HP 2011")]
13 | [assembly: AssemblyTrademark("")]
14 | [assembly: AssemblyCulture("")]
15 |
16 | // Setting ComVisible to false makes the types in this assembly not visible
17 | // to COM components. If you need to access a type in this assembly from
18 | // COM, set the ComVisible attribute to true on that type.
19 | [assembly: ComVisible(false)]
20 |
21 | // The following GUID is for the ID of the typelib if this project is exposed to COM
22 | [assembly: Guid("9c7d448b-5116-44c4-b14c-3f22ad1b61ef")]
23 |
24 | // Version information for an assembly consists of the following four values:
25 | //
26 | // Major Version
27 | // Minor Version
28 | // Build Number
29 | // Revision
30 | //
31 | // You can specify all the values or you can default the Build and Revision Numbers
32 | // by using the '*' as shown below:
33 | [assembly: AssemblyVersion("1.0.0.0")]
34 | [assembly: AssemblyFileVersion("1.0.0.0")]
35 |
--------------------------------------------------------------------------------
/Tests/Apworks.Tests.Repositories.NHibernateRepository/app.config:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 |
5 |
6 |
7 |
8 |
9 |
10 |
11 |
12 |
--------------------------------------------------------------------------------
/Tests/Apworks.Tests.Repositories.NHibernateRepository/packages.config:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 |
5 |
--------------------------------------------------------------------------------
/TraceAndTestImpact.testsettings:
--------------------------------------------------------------------------------
1 |
2 |
3 | These are test settings for Trace and Test Impact.
4 |
5 |
6 |
7 |
8 |
9 |
10 |
11 |
12 |
13 |
14 |
15 |
16 |
17 |
18 |
19 |
20 |
21 |
--------------------------------------------------------------------------------
/UnitTestEnvSetup.txt:
--------------------------------------------------------------------------------
1 | Please setup the unit test environment as indicated below:
2 | 1. Open Apworks.Tests.Common.Helper.cs, change the connection string settings
3 | 2. Run the SQL scripts under the scrpits folder
4 | 3. Setup the MSMQ
5 | 4. Setup MongoDB
6 |
--------------------------------------------------------------------------------
/build.bat:
--------------------------------------------------------------------------------
1 | @ECHO OFF
2 | IF /I "%1"=="Debug" GOTO BuildDebug
3 | IF /I "%1"=="Release" GOTO BuildRelease
4 |
5 | :ER
6 | ECHO.
7 | ECHO Apworks Command-Line Build Tool v1.0
8 | ECHO.
9 | ECHO Usage:
10 | ECHO build.bat Debug
11 | ECHO Builds the Apworks with Debug configuration.
12 | ECHO.
13 | ECHO build.bat Release
14 | ECHO Builds the Apworks with Release configuration.
15 | ECHO.
16 | GOTO End
17 |
18 | :BuildDebug
19 | msbuild /p:Configuration=CoreDebug;TargetFrameworkVersion=v4.5 Apworks.sln
20 | GOTO End
21 |
22 | :BuildRelease
23 | msbuild /p:Configuration=CoreRelease;TargetFrameworkVersion=v4.5 Apworks.sln
24 | GOTO End
25 |
26 | :End
27 | @ECHO ON
28 |
--------------------------------------------------------------------------------
/build.sh:
--------------------------------------------------------------------------------
1 | #! /bin/bash
2 | PARAM=''
3 | PKGFILE='packages_v2_5_4878_35266.tar.gz'
4 | PKGDIR='packages'
5 | URL='http://apworks.org/wp-content/uploads/fx/'
6 | if [ "$1" == 'Debug' ]
7 | then
8 | PARAM='/property:Configuration=MonoDebug'
9 | elif [ "$1" == 'Release' ]
10 | then
11 | PARAM='/property:Configuration=MonoRelease'
12 | else
13 | printf "\n"
14 | printf "Apworks Command-Line Build Tool v1.0\n\n"
15 | printf "Usage:\n"
16 | printf " build.sh Debug\n"
17 | printf " Builds the Apworks with Debug configuration.\n\n"
18 | printf " build.sh Release\n"
19 | printf " Builds the Apworks with Release configuration.\n\n"
20 | exit $?
21 | fi
22 | if [ ! -d $PKGDIR ]
23 | then
24 | printf "\nDownloading Dependencies...\n\n"
25 | rm -rf $PKGFILE
26 | wget $URL$PKGFILE
27 | if [ $? -ne 0 ]
28 | then
29 | printf "Failed to get the Dependencies from network.\n"
30 | exit $?
31 | fi
32 |
33 | tar -zxvf $PKGFILE
34 | rm -rf $PKGFILE
35 | fi
36 | xbuild $PARAM
37 |
38 |
--------------------------------------------------------------------------------
/docs/ClsLibRef.chm:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/daxnet/Apworks/6de4b83e94c1e39b55c93590617e4491880eed39/docs/ClsLibRef.chm
--------------------------------------------------------------------------------
/docs/WalkthroughDocument.chm:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/daxnet/Apworks/6de4b83e94c1e39b55c93590617e4491880eed39/docs/WalkthroughDocument.chm
--------------------------------------------------------------------------------
/scripts/CQRSArchTestScript_EventStore_MySql.sql:
--------------------------------------------------------------------------------
1 | delimiter $$
2 |
3 | CREATE DATABASE `apworkscqrsarcheventstoretestdb` /*!40100 DEFAULT CHARACTER SET latin1 */$$
4 |
5 | delimiter $$
6 | USE `apworkscqrsarcheventstoretestdb`$$
7 |
8 | delimiter $$
9 |
10 | CREATE TABLE `domainevents` (
11 | `Id` varchar(40) NOT NULL,
12 | `SourceID` varchar(40) NOT NULL,
13 | `AssemblyQualifiedSourceType` text NOT NULL,
14 | `Timestamp` datetime NOT NULL,
15 | `Version` bigint(20) NOT NULL,
16 | `Branch` bigint(20) NOT NULL,
17 | `AssemblyQualifiedEventType` text NOT NULL,
18 | `Data` longblob NOT NULL,
19 | PRIMARY KEY (`Id`),
20 | UNIQUE KEY `Id_UNIQUE` (`Id`)
21 | ) ENGINE=InnoDB AUTO_INCREMENT=5 DEFAULT CHARSET=latin1$$
22 |
23 | delimiter $$
24 |
25 | CREATE TABLE `snapshots` (
26 | `Id` varchar(40) NOT NULL,
27 | `Timestamp` datetime NOT NULL,
28 | `SnapshotData` longblob NOT NULL,
29 | `AggregateRootID` varchar(40) NOT NULL,
30 | `AggregateRootType` text NOT NULL,
31 | `SnapshotType` text NOT NULL,
32 | `Version` bigint(20) NOT NULL,
33 | `Branch` bigint(20) NOT NULL,
34 | PRIMARY KEY (`Id`),
35 | UNIQUE KEY `Id_UNIQUE` (`Id`)
36 | ) ENGINE=InnoDB DEFAULT CHARSET=latin1$$
37 |
38 |
--------------------------------------------------------------------------------
/scripts/CQRSEventStoreXmlMapping.xml:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 |
5 |
6 |
7 |
8 |
9 |
10 |
11 |
12 |
13 |
14 |
15 |
16 |
--------------------------------------------------------------------------------
/scripts/ClassicArchTestScript_SqlServer.sql:
--------------------------------------------------------------------------------
1 | USE ApworksClassicArchTestDB;
2 | /****** Object: Table [dbo].[Customer] Script Date: 12/13/2010 16:36:56 ******/
3 | IF EXISTS (SELECT * FROM sys.objects WHERE object_id = OBJECT_ID(N'[dbo].[Customer]') AND type in (N'U'))
4 | DROP TABLE [dbo].[Customer]
5 | GO
6 | /****** Object: Table [dbo].[Customer] Script Date: 12/13/2010 16:36:56 ******/
7 | SET ANSI_NULLS ON
8 | GO
9 | SET QUOTED_IDENTIFIER ON
10 | GO
11 | IF NOT EXISTS (SELECT * FROM sys.objects WHERE object_id = OBJECT_ID(N'[dbo].[Customer]') AND type in (N'U'))
12 | BEGIN
13 | CREATE TABLE [dbo].[Customer](
14 | [Id] [uniqueidentifier] NOT NULL,
15 | [Username] [nvarchar](255) COLLATE SQL_Latin1_General_CP1_CI_AS NULL,
16 | [Password] [nvarchar](255) COLLATE SQL_Latin1_General_CP1_CI_AS NULL,
17 | [FirstName] [nvarchar](255) COLLATE SQL_Latin1_General_CP1_CI_AS NULL,
18 | [LastName] [nvarchar](255) COLLATE SQL_Latin1_General_CP1_CI_AS NULL,
19 | [Email] [nvarchar](255) COLLATE SQL_Latin1_General_CP1_CI_AS NULL,
20 | [Birth] [datetime] NULL,
21 | [Sequence] [int],
22 | CONSTRAINT [PK__Customer__3214EC0730242045] PRIMARY KEY CLUSTERED
23 | (
24 | [Id] ASC
25 | )WITH (PAD_INDEX = OFF, STATISTICS_NORECOMPUTE = OFF, IGNORE_DUP_KEY = OFF, ALLOW_ROW_LOCKS = ON, ALLOW_PAGE_LOCKS = ON)
26 | )
27 | END
28 | GO
29 |
--------------------------------------------------------------------------------
/scripts/XmlStorageMappingSchema.xsd:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 |
5 | Represents the schema for storage mapping.
6 |
7 |
8 |
9 |
10 |
11 |
12 |
13 |
14 |
15 |
16 |
17 |
18 |
19 |
20 |
21 |
22 |
23 |
24 |
25 |
26 |
27 |
28 |
29 |
30 |
31 |
32 |
33 |
34 |
35 |
36 |
37 |
38 |
39 |
40 |
41 |
42 |
43 |
44 |
45 |
--------------------------------------------------------------------------------
/src/Apworks.Bus.DirectBus/Apworks.Bus.DirectBus.nuspec:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 | Apworks.Bus.DirectBus
5 | 2.5.4878.35266
6 | Apworks Direct Bus Implementation
7 | apworks.org
8 | apworks.org
9 | http://www.apache.org/licenses/LICENSE-2.0
10 | https://github.com/daxnet/Apworks
11 | false
12 | The message bus that uses the Message Dispatcher to implement the message publishing mechanism (Will be obsolete, please use Event Aggregator implementation instead).
13 | Copyright (C) 2009-2013 apworks.org
14 |
15 |
16 |
17 |
18 |
19 |
20 |
21 |
22 |
--------------------------------------------------------------------------------
/src/Apworks.Bus.DirectBus/Properties/AssemblyInfo.cs:
--------------------------------------------------------------------------------
1 | using System.Reflection;
2 | using System.Runtime.InteropServices;
3 |
4 | // General Information about an assembly is controlled through the following
5 | // set of attributes. Change these attribute values to modify the information
6 | // associated with an assembly.
7 | [assembly: AssemblyTitle("Apworks Direct Bus Implementation")]
8 | [assembly: AssemblyDescription("The message bus that uses the Message Dispatcher to implement the message publishing mechanism (Will be obsolete, please use Event Aggregator implementation instead).")]
9 | [assembly: AssemblyConfiguration("")]
10 | [assembly: AssemblyCompany("daxnet")]
11 | [assembly: AssemblyProduct("Apworks Application Development Framework")]
12 | [assembly: AssemblyCopyright("Copyright © 2009-2015, by daxnet.")]
13 | [assembly: AssemblyTrademark("")]
14 | [assembly: AssemblyCulture("")]
15 |
16 | // Setting ComVisible to false makes the types in this assembly not visible
17 | // to COM components. If you need to access a type in this assembly from
18 | // COM, set the ComVisible attribute to true on that type.
19 | [assembly: ComVisible(true)]
20 |
21 | // The following GUID is for the ID of the typelib if this project is exposed to COM
22 | [assembly: Guid("8c800496-690a-4be7-950f-e114eca8cd0b")]
23 |
24 | // Version information for an assembly consists of the following four values:
25 | //
26 | // Major Version
27 | // Minor Version
28 | // Build Number
29 | // Revision
30 | //
31 | // You can specify all the values or you can default the Build and Revision Numbers
32 | // by using the '*' as shown below:
33 | // [assembly: AssemblyVersion("1.0.*")]
34 | [assembly: AssemblyVersion("2.5.5164.37969")]
35 |
36 |
--------------------------------------------------------------------------------
/src/Apworks.Bus.DirectBus/key.snk:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/daxnet/Apworks/6de4b83e94c1e39b55c93590617e4491880eed39/src/Apworks.Bus.DirectBus/key.snk
--------------------------------------------------------------------------------
/src/Apworks.Bus.EventAggregator/Apworks.Bus.EventAggregator.nuspec:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 | Apworks.Bus.EventAggregator
5 | 2.5.4878.35266
6 | Apworks Event Aggregator Bus
7 | apworks.org
8 | apworks.org
9 | false
10 | The message bus that uses the Event Aggregator to implement the message publishing mechanism.
11 | Copyright © 2009-2013, apworks.org
12 |
13 |
14 |
15 |
16 |
17 |
18 |
19 |
20 |
--------------------------------------------------------------------------------
/src/Apworks.Bus.EventAggregator/Properties/AssemblyInfo.cs:
--------------------------------------------------------------------------------
1 | using System.Reflection;
2 | using System.Runtime.CompilerServices;
3 | using System.Runtime.InteropServices;
4 |
5 | // General Information about an assembly is controlled through the following
6 | // set of attributes. Change these attribute values to modify the information
7 | // associated with an assembly.
8 | [assembly: AssemblyTitle("Apworks Event Aggregator Bus")]
9 | [assembly: AssemblyDescription("The message bus that uses the Event Aggregator to implement the message publishing mechanism.")]
10 | [assembly: AssemblyConfiguration("")]
11 | [assembly: AssemblyCompany("daxnet")]
12 | [assembly: AssemblyProduct("Apworks Application Development Framework")]
13 | [assembly: AssemblyCopyright("Copyright © 2009-2015, by daxnet.")]
14 | [assembly: AssemblyTrademark("")]
15 | [assembly: AssemblyCulture("")]
16 |
17 | // Setting ComVisible to false makes the types in this assembly not visible
18 | // to COM components. If you need to access a type in this assembly from
19 | // COM, set the ComVisible attribute to true on that type.
20 | [assembly: ComVisible(false)]
21 |
22 | // The following GUID is for the ID of the typelib if this project is exposed to COM
23 | [assembly: Guid("e59f5e63-118b-4608-8e5c-80d5c42ac3f3")]
24 |
25 | // Version information for an assembly consists of the following four values:
26 | //
27 | // Major Version
28 | // Minor Version
29 | // Build Number
30 | // Revision
31 | //
32 | // You can specify all the values or you can default the Build and Revision Numbers
33 | // by using the '*' as shown below:
34 | // [assembly: AssemblyVersion("1.0.*")]
35 | [assembly: AssemblyVersion("2.5.5164.37969")]
36 |
--------------------------------------------------------------------------------
/src/Apworks.Bus.EventAggregator/key.snk:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/daxnet/Apworks/6de4b83e94c1e39b55c93590617e4491880eed39/src/Apworks.Bus.EventAggregator/key.snk
--------------------------------------------------------------------------------
/src/Apworks.Bus.MSMQ/Apworks.Bus.MSMQ.nuspec:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 | Apworks.Bus.MSMQ
5 | 2.5.4878.35266
6 | Apworks MSMQ Bus
7 | apworks.org
8 | apworks.org
9 | false
10 | The message bus that uses the MSMQ as the message publishing mechanism.
11 | Copyright © 2009-2013, apworks.org
12 |
13 |
14 |
15 |
16 |
17 |
18 |
19 |
20 |
--------------------------------------------------------------------------------
/src/Apworks.Bus.MSMQ/MSMQCommandBus.cs:
--------------------------------------------------------------------------------
1 | using Apworks.Commands;
2 |
3 | namespace Apworks.Bus.MSMQ
4 | {
5 | ///
6 | /// Represents the command bus which uses Microsoft Message Queuing technology.
7 | ///
8 | public class MSMQCommandBus : MSMQBus, ICommandBus
9 | {
10 | #region Ctor
11 | ///
12 | /// Initializes a new instance of MSMQCommandBus class.
13 | ///
14 | /// The location of the queue.
15 | public MSMQCommandBus(string path) : base(path) { }
16 | ///
17 | /// Initializes a new instance of MSMQCommandBus class.
18 | ///
19 | /// The location of the queue.
20 | /// A value which indicates
21 | /// whether the internal transaction should be used to manipulate the message queue.
22 | public MSMQCommandBus(string path, bool useInternalTransaction) : base(path, useInternalTransaction) { }
23 | ///
24 | /// Initializes a new instance of MSMQCommandBus class.
25 | ///
26 | /// The instance of class
27 | /// which contains the option information to initialize the message queue.
28 | public MSMQCommandBus(MSMQBusOptions options) : base(options) { }
29 | #endregion
30 | }
31 | }
32 |
--------------------------------------------------------------------------------
/src/Apworks.Bus.MSMQ/MSMQEventBus.cs:
--------------------------------------------------------------------------------
1 | using Apworks.Events;
2 |
3 | namespace Apworks.Bus.MSMQ
4 | {
5 | ///
6 | /// Represents the event bus which uses the Microsoft Message Queuing technology.
7 | ///
8 | public class MSMQEventBus : MSMQBus, IEventBus
9 | {
10 | #region Ctor
11 | ///
12 | /// Initializes a new instance of MSMQEventBus class.
13 | ///
14 | /// The location of the queue.
15 | public MSMQEventBus(string path) : base(path) { }
16 | ///
17 | /// Initializes a new instance of MSMQEventBus class.
18 | ///
19 | /// The location of the queue.
20 | /// A value which indicates
21 | /// whether the internal transaction should be used to manipulate the message queue.
22 | public MSMQEventBus(string path, bool useInternalTransaction) : base(path, useInternalTransaction) { }
23 | ///
24 | /// Initializes a new instance of MSMQEventBus class.
25 | ///
26 | /// The instance of class
27 | /// which contains the option information to initialize the message queue.
28 | public MSMQEventBus(MSMQBusOptions options) : base(options) { }
29 | #endregion
30 | }
31 | }
32 |
--------------------------------------------------------------------------------
/src/Apworks.Bus.MSMQ/Properties/AssemblyInfo.cs:
--------------------------------------------------------------------------------
1 | using System.Reflection;
2 | using System.Runtime.InteropServices;
3 |
4 | // General Information about an assembly is controlled through the following
5 | // set of attributes. Change these attribute values to modify the information
6 | // associated with an assembly.
7 | [assembly: AssemblyTitle("Apworks MSMQ Bus")]
8 | [assembly: AssemblyDescription("The message bus that uses the MSMQ as the message publishing mechanism.")]
9 | [assembly: AssemblyConfiguration("")]
10 | [assembly: AssemblyCompany("daxnet")]
11 | [assembly: AssemblyProduct("Apworks Application Development Framework")]
12 | [assembly: AssemblyCopyright("Copyright © 2009-2015, by daxnet.")]
13 | [assembly: AssemblyTrademark("")]
14 | [assembly: AssemblyCulture("")]
15 |
16 | // Setting ComVisible to false makes the types in this assembly not visible
17 | // to COM components. If you need to access a type in this assembly from
18 | // COM, set the ComVisible attribute to true on that type.
19 | [assembly: ComVisible(true)]
20 |
21 | // The following GUID is for the ID of the typelib if this project is exposed to COM
22 | [assembly: Guid("92c1ca0e-0fd0-4710-8dc4-c39f426e9259")]
23 |
24 | // Version information for an assembly consists of the following four values:
25 | //
26 | // Major Version
27 | // Minor Version
28 | // Build Number
29 | // Revision
30 | //
31 | // You can specify all the values or you can default the Build and Revision Numbers
32 | // by using the '*' as shown below:
33 | // [assembly: AssemblyVersion("1.0.*")]
34 | [assembly: AssemblyVersion("2.5.5164.37969")]
35 |
36 |
--------------------------------------------------------------------------------
/src/Apworks.Bus.MSMQ/key.snk:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/daxnet/Apworks/6de4b83e94c1e39b55c93590617e4491880eed39/src/Apworks.Bus.MSMQ/key.snk
--------------------------------------------------------------------------------
/src/Apworks.Events.Storage.General/Apworks.Events.Storage.General.nuspec:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 | Apworks.Events.Storage.General
5 | 2.5.4878.35266
6 | Apworks General Event Storage
7 | apworks.org
8 | apworks.org
9 | false
10 | The implementation of Domain Event Storages built with general RDBMS, such as SQL Server or OleDB databases.
11 | Copyright © 2009-2013, apworks.org
12 |
13 |
14 |
15 |
16 |
17 |
18 |
19 |
20 |
21 |
--------------------------------------------------------------------------------
/src/Apworks.Events.Storage.General/Properties/AssemblyInfo.cs:
--------------------------------------------------------------------------------
1 | using System.Reflection;
2 | using System.Runtime.InteropServices;
3 |
4 | // General Information about an assembly is controlled through the following
5 | // set of attributes. Change these attribute values to modify the information
6 | // associated with an assembly.
7 | [assembly: AssemblyTitle("Apworks General Event Storage")]
8 | [assembly: AssemblyDescription("The implementation of Domain Event Storages built with general RDBMS, such as SQL Server or OleDB databases.")]
9 | [assembly: AssemblyConfiguration("")]
10 | [assembly: AssemblyCompany("daxnet")]
11 | [assembly: AssemblyProduct("Apworks Application Development Framework")]
12 | [assembly: AssemblyCopyright("Copyright © 2009-2015, by daxnet.")]
13 | [assembly: AssemblyTrademark("")]
14 | [assembly: AssemblyCulture("")]
15 |
16 | // Setting ComVisible to false makes the types in this assembly not visible
17 | // to COM components. If you need to access a type in this assembly from
18 | // COM, set the ComVisible attribute to true on that type.
19 | [assembly: ComVisible(true)]
20 |
21 | // The following GUID is for the ID of the typelib if this project is exposed to COM
22 | [assembly: Guid("a2cdf709-4ea7-47d1-9d73-0d1b9a295d14")]
23 |
24 | // Version information for an assembly consists of the following four values:
25 | //
26 | // Major Version
27 | // Minor Version
28 | // Build Number
29 | // Revision
30 | //
31 | // You can specify all the values or you can default the Build and Revision Numbers
32 | // by using the '*' as shown below:
33 | // [assembly: AssemblyVersion("1.0.*")]
34 | [assembly: AssemblyVersion("2.5.5164.37969")]
35 |
36 |
--------------------------------------------------------------------------------
/src/Apworks.Events.Storage.General/SqlDomainEventStorage.cs:
--------------------------------------------------------------------------------
1 | using Apworks.Storage;
2 | using Apworks.Storage.General;
3 |
4 | namespace Apworks.Events.Storage.General
5 | {
6 | ///
7 | /// Represents the domain event storage that uses SQL Server as the storage device.
8 | ///
9 | public class SqlDomainEventStorage : RdbmsDomainEventStorage// SqlStorage, IDomainEventStorage
10 | {
11 | #region Ctor
12 | ///
13 | /// Initializes a new instance of SqlDomainEventStorage class.
14 | ///
15 | /// The connection string.
16 | /// The mapping resolver.
17 | public SqlDomainEventStorage(string connectionString, IStorageMappingResolver mappingResolver)
18 | : base(connectionString, mappingResolver)
19 | {
20 | }
21 | #endregion
22 | }
23 | }
24 |
--------------------------------------------------------------------------------
/src/Apworks.Events.Storage.General/key.snk:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/daxnet/Apworks/6de4b83e94c1e39b55c93590617e4491880eed39/src/Apworks.Events.Storage.General/key.snk
--------------------------------------------------------------------------------
/src/Apworks.Events.Storage.MySql/Apworks.Events.Storage.MySql.nuspec:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 | Apworks.Events.Storage.MySql
5 | 2.5.4878.35266
6 | Apworks MySQL Event Storage
7 | apworks.org
8 | apworks.org
9 | false
10 | The implementation of Domain Event Storages built with MySQL database.
11 | Copyright © 2009-2013, apworks.org
12 |
13 |
14 |
15 |
16 |
17 |
18 |
19 |
20 |
21 |
--------------------------------------------------------------------------------
/src/Apworks.Events.Storage.MySql/MySqlDomainEventStorage.cs:
--------------------------------------------------------------------------------
1 | using Apworks.Storage;
2 | using Apworks.Storage.MySql;
3 |
4 | namespace Apworks.Events.Storage.MySql
5 | {
6 | ///
7 | /// Represents the domain event storage that uses MySQL as the storage device.
8 | ///
9 | public class MySqlDomainEventStorage : RdbmsDomainEventStorage
10 | {
11 | #region Ctor
12 | ///
13 | /// Initializes a new instance of MySqlDomainEventStorage class.
14 | ///
15 | /// The connection string.
16 | /// The mapping resolver.
17 | public MySqlDomainEventStorage(string connectionString, IStorageMappingResolver mappingResolver)
18 | : base(connectionString, mappingResolver)
19 | {
20 |
21 | }
22 | #endregion
23 | }
24 | }
25 |
--------------------------------------------------------------------------------
/src/Apworks.Events.Storage.MySql/Properties/AssemblyInfo.cs:
--------------------------------------------------------------------------------
1 | using System.Reflection;
2 | using System.Runtime.InteropServices;
3 |
4 | // General Information about an assembly is controlled through the following
5 | // set of attributes. Change these attribute values to modify the information
6 | // associated with an assembly.
7 | [assembly: AssemblyTitle("Apworks MySQL Event Storage")]
8 | [assembly: AssemblyDescription("The implementation of Domain Event Storages built with MySQL database.")]
9 | [assembly: AssemblyConfiguration("")]
10 | [assembly: AssemblyCompany("daxnet")]
11 | [assembly: AssemblyProduct("Apworks Application Development Framework")]
12 | [assembly: AssemblyCopyright("Copyright © 2009-2015, by daxnet.")]
13 | [assembly: AssemblyTrademark("")]
14 | [assembly: AssemblyCulture("")]
15 |
16 | // Setting ComVisible to false makes the types in this assembly not visible
17 | // to COM components. If you need to access a type in this assembly from
18 | // COM, set the ComVisible attribute to true on that type.
19 | [assembly: ComVisible(true)]
20 |
21 | // The following GUID is for the ID of the typelib if this project is exposed to COM
22 | [assembly: Guid("cfa4f7ca-30a1-4a86-88ae-825219bca165")]
23 |
24 | // Version information for an assembly consists of the following four values:
25 | //
26 | // Major Version
27 | // Minor Version
28 | // Build Number
29 | // Revision
30 | //
31 | // You can specify all the values or you can default the Build and Revision Numbers
32 | // by using the '*' as shown below:
33 | // [assembly: AssemblyVersion("1.0.*")]
34 | [assembly: AssemblyVersion("2.5.5164.37969")]
35 |
36 |
--------------------------------------------------------------------------------
/src/Apworks.Events.Storage.MySql/key.snk:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/daxnet/Apworks/6de4b83e94c1e39b55c93590617e4491880eed39/src/Apworks.Events.Storage.MySql/key.snk
--------------------------------------------------------------------------------
/src/Apworks.ObjectContainers.Unity/Apworks.ObjectContainers.Unity.nuspec:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 | Apworks.ObjectContainers.Unity
5 | 2.5.4878.35266
6 | Apworks Unity Object Container
7 | apworks.org
8 | apworks.org
9 | false
10 | Apworks object container implementation of Microsoft Patterns & Practices Unity Application Block.
11 | Copyright © 2009-2013, apworks.org
12 |
13 |
14 |
15 |
16 |
17 |
18 |
19 |
20 |
21 |
22 |
--------------------------------------------------------------------------------
/src/Apworks.ObjectContainers.Unity/LifetimeManagers/GlobalSuppressions.cs:
--------------------------------------------------------------------------------
1 | // This file is used by Code Analysis to maintain SuppressMessage
2 | // attributes that are applied to this project.
3 | // Project-level suppressions either have no target or are given
4 | // a specific target and scoped to a namespace, type, member, etc.
5 | //
6 | // To add a suppression to this file, right-click the message in the
7 | // Error List, point to "Suppress Message(s)", and click
8 | // "In Project Suppression File".
9 | // You do not need to add suppressions to this file manually.
10 |
11 | [assembly: System.Diagnostics.CodeAnalysis.SuppressMessage("Microsoft.Design", "CA2210:AssembliesShouldHaveValidStrongNames", Justification = "Signing is not required for this project.")]
12 | [assembly: System.Diagnostics.CodeAnalysis.SuppressMessage("Microsoft.Naming", "CA2204:Literals should be spelled correctly", MessageId = "UnityWcfExtension", Scope = "member", Target = "Apworks.ObjectContainers.Unity.LifetimeManagers.UnityWcfLifetimeManager`1.#Extension", Justification = "All tokens are spelled correctly.")]
13 |
--------------------------------------------------------------------------------
/src/Apworks.ObjectContainers.Unity/LifetimeManagers/UnityOperationContextMessageInspector.cs:
--------------------------------------------------------------------------------
1 | using System.ServiceModel;
2 | using System.ServiceModel.Channels;
3 | using System.ServiceModel.Dispatcher;
4 |
5 | namespace Apworks.ObjectContainers.Unity.LifetimeManagers
6 | {
7 | ///
8 | /// Adds and removes instances of from the current operation context.
9 | ///
10 | public class UnityOperationContextMessageInspector : IDispatchMessageInspector
11 | {
12 | ///
13 | /// Initializes a new instance of the class.
14 | ///
15 | public UnityOperationContextMessageInspector()
16 | : base()
17 | {
18 | }
19 |
20 | ///
21 | /// Adds an instance of the class to the current operation context after an inbound message has been received but before the message is dispatched to the intended operation.
22 | ///
23 | /// The request message.
24 | /// The incoming channel.
25 | /// The current service instance.
26 | /// The object used to correlate state. This object is passed back in the BeforeSendReply method.
27 | public object AfterReceiveRequest(ref Message request, IClientChannel channel, InstanceContext instanceContext)
28 | {
29 | OperationContext.Current.Extensions.Add(new UnityOperationContextExtension());
30 | return null;
31 | }
32 |
33 | ///
34 | /// Removes the registered instance of the class from the current operation context after the operation has returned but before the reply message is sent.
35 | ///
36 | /// The reply message. This value is null if the operation is one way.
37 | /// The correlation object returned from the AfterReceiveRequest method.
38 | public void BeforeSendReply(ref Message reply, object correlationState)
39 | {
40 | OperationContext.Current.Extensions.Remove(UnityOperationContextExtension.Current);
41 | }
42 | }
43 | }
44 |
--------------------------------------------------------------------------------
/src/Apworks.ObjectContainers.Unity/Properties/AssemblyInfo.cs:
--------------------------------------------------------------------------------
1 | using System.Reflection;
2 | using System.Runtime.InteropServices;
3 |
4 | // General Information about an assembly is controlled through the following
5 | // set of attributes. Change these attribute values to modify the information
6 | // associated with an assembly.
7 | [assembly: AssemblyTitle("Apworks Unity Object Container")]
8 | [assembly: AssemblyDescription("Apworks object container implementation of Microsoft Patterns & Practices Unity Application Block.")]
9 | [assembly: AssemblyConfiguration("")]
10 | [assembly: AssemblyCompany("daxnet")]
11 | [assembly: AssemblyProduct("Apworks Application Development Framework")]
12 | [assembly: AssemblyCopyright("Copyright © 2009-2015, by daxnet.")]
13 | [assembly: AssemblyTrademark("")]
14 | [assembly: AssemblyCulture("")]
15 |
16 | // Setting ComVisible to false makes the types in this assembly not visible
17 | // to COM components. If you need to access a type in this assembly from
18 | // COM, set the ComVisible attribute to true on that type.
19 | [assembly: ComVisible(true)]
20 |
21 | // The following GUID is for the ID of the typelib if this project is exposed to COM
22 | [assembly: Guid("11d53103-a5e5-4d87-8869-8280722f88fe")]
23 |
24 | // Version information for an assembly consists of the following four values:
25 | //
26 | // Major Version
27 | // Minor Version
28 | // Build Number
29 | // Revision
30 | //
31 | // You can specify all the values or you can default the Build and Revision Numbers
32 | // by using the '*' as shown below:
33 | // [assembly: AssemblyVersion("1.0.*")]
34 | [assembly: AssemblyVersion("2.5.5164.37969")]
35 |
36 |
--------------------------------------------------------------------------------
/src/Apworks.ObjectContainers.Unity/key.snk:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/daxnet/Apworks/6de4b83e94c1e39b55c93590617e4491880eed39/src/Apworks.ObjectContainers.Unity/key.snk
--------------------------------------------------------------------------------
/src/Apworks.ObjectContainers.Unity/packages.config:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 |
5 |
--------------------------------------------------------------------------------
/src/Apworks.Repositories.EntityFramework/App.config:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 |
5 |
6 |
7 |
8 |
9 |
10 |
11 |
12 |
13 |
14 |
15 |
16 |
17 |
18 |
19 |
20 |
21 |
--------------------------------------------------------------------------------
/src/Apworks.Repositories.EntityFramework/Apworks.Repositories.EntityFramework.nuspec:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 | Apworks.Repositories.EntityFramework
5 | 2.5.4878.35266
6 | Apworks Entity Framework Repository
7 | apworks.org
8 | apworks.org
9 | false
10 | Apworks Entity Framework repository implementation.
11 | Copyright © 2009-2013, apworks.org
12 |
13 |
14 |
15 |
16 |
17 |
18 |
19 |
20 |
21 |
--------------------------------------------------------------------------------
/src/Apworks.Repositories.EntityFramework/Properties/AssemblyInfo.cs:
--------------------------------------------------------------------------------
1 | using System.Reflection;
2 | using System.Runtime.CompilerServices;
3 | using System.Runtime.InteropServices;
4 |
5 | // General Information about an assembly is controlled through the following
6 | // set of attributes. Change these attribute values to modify the information
7 | // associated with an assembly.
8 | [assembly: AssemblyTitle("Apworks Entity Framework Repository")]
9 | [assembly: AssemblyDescription("Apworks Entity Framework repository implementation.")]
10 | [assembly: AssemblyConfiguration("")]
11 | [assembly: AssemblyCompany("daxnet")]
12 | [assembly: AssemblyProduct("Apworks Application Development Framework")]
13 | [assembly: AssemblyCopyright("Copyright © 2009-2015, by daxnet.")]
14 | [assembly: AssemblyTrademark("")]
15 | [assembly: AssemblyCulture("")]
16 |
17 | // Setting ComVisible to false makes the types in this assembly not visible
18 | // to COM components. If you need to access a type in this assembly from
19 | // COM, set the ComVisible attribute to true on that type.
20 | [assembly: ComVisible(true)]
21 |
22 | // The following GUID is for the ID of the typelib if this project is exposed to COM
23 | [assembly: Guid("328f2d3b-abcf-429d-a8f5-a8cd93da4361")]
24 |
25 | // Version information for an assembly consists of the following four values:
26 | //
27 | // Major Version
28 | // Minor Version
29 | // Build Number
30 | // Revision
31 | //
32 | // You can specify all the values or you can default the Build and Revision Numbers
33 | // by using the '*' as shown below:
34 | // [assembly: AssemblyVersion("1.0.*")]
35 | [assembly: AssemblyVersion("2.5.5164.37969")]
36 |
37 |
--------------------------------------------------------------------------------
/src/Apworks.Repositories.EntityFramework/key.snk:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/daxnet/Apworks/6de4b83e94c1e39b55c93590617e4491880eed39/src/Apworks.Repositories.EntityFramework/key.snk
--------------------------------------------------------------------------------
/src/Apworks.Repositories.EntityFramework/packages.config:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 |
--------------------------------------------------------------------------------
/src/Apworks.Repositories.MongoDB/Apworks.Repositories.MongoDB.nuspec:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 | Apworks.Repositories.MongoDB
5 | 2.5.4878.35266
6 | Apworks MongoDB Repository
7 | apworks.org
8 | apworks.org
9 | false
10 | Apworks MongoDB repository implementation.
11 | Copyright © 2009-2013, apworks.org
12 |
13 |
14 |
15 |
16 |
17 |
18 |
19 |
20 |
21 |
--------------------------------------------------------------------------------
/src/Apworks.Repositories.MongoDB/Properties/AssemblyInfo.cs:
--------------------------------------------------------------------------------
1 | using System.Reflection;
2 | using System.Runtime.CompilerServices;
3 | using System.Runtime.InteropServices;
4 |
5 | // General Information about an assembly is controlled through the following
6 | // set of attributes. Change these attribute values to modify the information
7 | // associated with an assembly.
8 | [assembly: AssemblyTitle("Apworks MongoDB Repository")]
9 | [assembly: AssemblyDescription("Apworks MongoDB repository implementation.")]
10 | [assembly: AssemblyConfiguration("")]
11 | [assembly: AssemblyCompany("daxnet")]
12 | [assembly: AssemblyProduct("Apworks Application Development Framework")]
13 | [assembly: AssemblyCopyright("Copyright © 2009-2015, by daxnet.")]
14 | [assembly: AssemblyTrademark("")]
15 | [assembly: AssemblyCulture("")]
16 |
17 | // Setting ComVisible to false makes the types in this assembly not visible
18 | // to COM components. If you need to access a type in this assembly from
19 | // COM, set the ComVisible attribute to true on that type.
20 | [assembly: ComVisible(false)]
21 |
22 | // The following GUID is for the ID of the typelib if this project is exposed to COM
23 | [assembly: Guid("8e21dcc5-8f89-4fb4-a7b0-b40fd0e21b8a")]
24 |
25 | // Version information for an assembly consists of the following four values:
26 | //
27 | // Major Version
28 | // Minor Version
29 | // Build Number
30 | // Revision
31 | //
32 | // You can specify all the values or you can default the Build and Revision Numbers
33 | // by using the '*' as shown below:
34 | // [assembly: AssemblyVersion("1.0.*")]
35 | [assembly: AssemblyVersion("2.5.5164.37969")]
36 |
--------------------------------------------------------------------------------
/src/Apworks.Repositories.MongoDB/key.snk:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/daxnet/Apworks/6de4b83e94c1e39b55c93590617e4491880eed39/src/Apworks.Repositories.MongoDB/key.snk
--------------------------------------------------------------------------------
/src/Apworks.Repositories.MongoDB/packages.config:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 |
5 |
6 |
7 |
--------------------------------------------------------------------------------
/src/Apworks.Repositories.NHibernate/Apworks.Repositories.NHibernate.nuspec:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 | Apworks.Repositories.NHibernate
5 | 2.5.4878.35266
6 | Apworks NHibernate Repository
7 | apworks.org
8 | apworks.org
9 | false
10 | Apworks NHibernate repository implementation.
11 | Copyright © 2009-2013, apworks.org
12 |
13 |
14 |
15 |
16 |
17 |
18 |
19 |
20 |
21 |
22 |
--------------------------------------------------------------------------------
/src/Apworks.Repositories.NHibernate/Properties/AssemblyInfo.cs:
--------------------------------------------------------------------------------
1 | using System.Reflection;
2 | using System.Runtime.CompilerServices;
3 | using System.Runtime.InteropServices;
4 |
5 | // General Information about an assembly is controlled through the following
6 | // set of attributes. Change these attribute values to modify the information
7 | // associated with an assembly.
8 | [assembly: AssemblyTitle("Apworks NHibernate Repository")]
9 | [assembly: AssemblyDescription("Apworks NHibernate repository implementation.")]
10 | [assembly: AssemblyConfiguration("")]
11 | [assembly: AssemblyCompany("daxnet")]
12 | [assembly: AssemblyProduct("Apworks Application Development Framework")]
13 | [assembly: AssemblyCopyright("Copyright © 2009-2015, by daxnet.")]
14 | [assembly: AssemblyTrademark("")]
15 | [assembly: AssemblyCulture("")]
16 |
17 | // Makes all the internal types visible to the Caslte Dynamic Proxy generation.
18 | [assembly: InternalsVisibleTo(Castle.Core.Internal.InternalsVisible.ToDynamicProxyGenAssembly2)]
19 |
20 | // Setting ComVisible to false makes the types in this assembly not visible
21 | // to COM components. If you need to access a type in this assembly from
22 | // COM, set the ComVisible attribute to true on that type.
23 | [assembly: ComVisible(true)]
24 |
25 | // The following GUID is for the ID of the typelib if this project is exposed to COM
26 | [assembly: Guid("3bef4ac2-11da-4bbe-b14f-26e9dc4e36a9")]
27 |
28 | // Version information for an assembly consists of the following four values:
29 | //
30 | // Major Version
31 | // Minor Version
32 | // Build Number
33 | // Revision
34 | //
35 | // You can specify all the values or you can default the Build and Revision Numbers
36 | // by using the '*' as shown below:
37 | // [assembly: AssemblyVersion("1.0.*")]
38 | [assembly: AssemblyVersion("2.5.5164.37969")]
39 |
40 |
--------------------------------------------------------------------------------
/src/Apworks.Repositories.NHibernate/key.snk:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/daxnet/Apworks/6de4b83e94c1e39b55c93590617e4491880eed39/src/Apworks.Repositories.NHibernate/key.snk
--------------------------------------------------------------------------------
/src/Apworks.Repositories.NHibernate/packages.config:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 |
5 |
6 |
--------------------------------------------------------------------------------
/src/Apworks.Storage.General/Apworks.Storage.General.nuspec:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 | Apworks.Storage.General
5 | 2.5.4878.35266
6 | Apworks General Storage
7 | apworks.org
8 | apworks.org
9 | false
10 | The implementation of common storages built with general RDBMS, such as SQL Server or OleDB databases.
11 | Copyright © 2009-2013, apworks.org
12 |
13 |
14 |
15 |
16 |
17 |
18 |
19 |
20 |
--------------------------------------------------------------------------------
/src/Apworks.Storage.General/Builders/SqlWhereClauseBuilder.cs:
--------------------------------------------------------------------------------
1 |
2 | using Apworks.Storage.Builders;
3 |
4 | namespace Apworks.Storage.General.Builders
5 | {
6 | ///
7 | /// Represents the WHERE clause builder for SQL Server database.
8 | ///
9 | /// The type of the object that will be mapped to a single SQL Server data table.
10 | public sealed class SqlWhereClauseBuilder : WhereClauseBuilder
11 | where T : class, new()
12 | {
13 | #region Ctor
14 | ///
15 | /// Initializes a new instance of SqlWhereClauseBuilder<T> class.
16 | ///
17 | /// The storage mapping resolver instance.
18 | public SqlWhereClauseBuilder(IStorageMappingResolver mappingResolver)
19 | : base(mappingResolver)
20 | { }
21 | #endregion
22 |
23 | #region Protected Properties
24 | ///
25 | /// Gets a System.Char value which represents the leading character to be used by the
26 | /// SQL Server parameter.
27 | ///
28 | protected override char ParameterChar
29 | {
30 | get { return '@'; }
31 | }
32 | #endregion
33 | }
34 | }
35 |
--------------------------------------------------------------------------------
/src/Apworks.Storage.General/Properties/AssemblyInfo.cs:
--------------------------------------------------------------------------------
1 | using System.Reflection;
2 | using System.Runtime.InteropServices;
3 |
4 | // General Information about an assembly is controlled through the following
5 | // set of attributes. Change these attribute values to modify the information
6 | // associated with an assembly.
7 | [assembly: AssemblyTitle("Apworks General Storage")]
8 | [assembly: AssemblyDescription("The implementation of common storages built with general RDBMS, such as SQL Server or OleDB databases.")]
9 | [assembly: AssemblyConfiguration("")]
10 | [assembly: AssemblyCompany("daxnet")]
11 | [assembly: AssemblyProduct("Apworks Application Development Framework")]
12 | [assembly: AssemblyCopyright("Copyright © 2009-2015, by daxnet.")]
13 | [assembly: AssemblyTrademark("")]
14 | [assembly: AssemblyCulture("")]
15 |
16 | // Setting ComVisible to false makes the types in this assembly not visible
17 | // to COM components. If you need to access a type in this assembly from
18 | // COM, set the ComVisible attribute to true on that type.
19 | [assembly: ComVisible(true)]
20 |
21 | // The following GUID is for the ID of the typelib if this project is exposed to COM
22 | [assembly: Guid("014c33b5-85ef-4e1c-813c-e42a164bb577")]
23 |
24 | // Version information for an assembly consists of the following four values:
25 | //
26 | // Major Version
27 | // Minor Version
28 | // Build Number
29 | // Revision
30 | //
31 | // You can specify all the values or you can default the Build and Revision Numbers
32 | // by using the '*' as shown below:
33 | // [assembly: AssemblyVersion("1.0.*")]
34 | [assembly: AssemblyVersion("2.5.5164.37969")]
35 |
36 |
--------------------------------------------------------------------------------
/src/Apworks.Storage.General/key.snk:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/daxnet/Apworks/6de4b83e94c1e39b55c93590617e4491880eed39/src/Apworks.Storage.General/key.snk
--------------------------------------------------------------------------------
/src/Apworks.Storage.MySql/Apworks.Storage.MySql.nuspec:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 | Apworks.Storage.MySql
5 | 2.5.4878.35266
6 | Apworks MySQL Storage
7 | apworks.org
8 | apworks.org
9 | false
10 | The implementation of common storage built with MySQL database.
11 | Copyright © 2009-2013, apworks.org
12 |
13 |
14 |
15 |
16 |
17 |
18 |
19 |
20 |
21 |
--------------------------------------------------------------------------------
/src/Apworks.Storage.MySql/MySqlWhereClauseBuilder.cs:
--------------------------------------------------------------------------------
1 | using Apworks.Storage.Builders;
2 |
3 | namespace Apworks.Storage.MySql
4 | {
5 | ///
6 | /// Represents the where clause builder for MySql database.
7 | ///
8 | /// The type of the data object which would be mapped to
9 | /// a certain table in the relational database.
10 | internal sealed class MySqlWhereClauseBuilder : WhereClauseBuilder
11 | where TDataObject : class, new()
12 | {
13 | #region Ctor
14 | ///
15 | /// Initializes a new instance of the MySqlWhereClauseBuilder<TDataObject> class.
16 | ///
17 | /// The Apworks.Storage.IStorageMappingResolver
18 | /// instance which will be used for generating the mapped field names.
19 | public MySqlWhereClauseBuilder(IStorageMappingResolver mappingResolver)
20 | : base(mappingResolver)
21 | { }
22 | #endregion
23 |
24 | #region Protected Properties
25 | ///
26 | /// Gets a System.Char value which represents the leading character to be used by the
27 | /// database parameter.
28 | ///
29 | protected override char ParameterChar
30 | {
31 | get { return '?'; }
32 | }
33 | #endregion
34 | }
35 | }
36 |
--------------------------------------------------------------------------------
/src/Apworks.Storage.MySql/Properties/AssemblyInfo.cs:
--------------------------------------------------------------------------------
1 | using System.Reflection;
2 | using System.Runtime.InteropServices;
3 |
4 | // General Information about an assembly is controlled through the following
5 | // set of attributes. Change these attribute values to modify the information
6 | // associated with an assembly.
7 | [assembly: AssemblyTitle("Apworks MySQL Storage")]
8 | [assembly: AssemblyDescription("The implementation of common storage built with MySQL database.")]
9 | [assembly: AssemblyConfiguration("")]
10 | [assembly: AssemblyCompany("daxnet")]
11 | [assembly: AssemblyProduct("Apworks Application Development Framework")]
12 | [assembly: AssemblyCopyright("Copyright © 2009-2015, by daxnet.")]
13 | [assembly: AssemblyTrademark("")]
14 | [assembly: AssemblyCulture("")]
15 |
16 | // Setting ComVisible to false makes the types in this assembly not visible
17 | // to COM components. If you need to access a type in this assembly from
18 | // COM, set the ComVisible attribute to true on that type.
19 | [assembly: ComVisible(true)]
20 |
21 | // The following GUID is for the ID of the typelib if this project is exposed to COM
22 | [assembly: Guid("93252617-1f3e-48e7-aa04-b19369137258")]
23 |
24 | // Version information for an assembly consists of the following four values:
25 | //
26 | // Major Version
27 | // Minor Version
28 | // Build Number
29 | // Revision
30 | //
31 | // You can specify all the values or you can default the Build and Revision Numbers
32 | // by using the '*' as shown below:
33 | // [assembly: AssemblyVersion("1.0.*")]
34 | [assembly: AssemblyVersion("2.5.5164.37969")]
35 |
36 |
--------------------------------------------------------------------------------
/src/Apworks.Storage.MySql/app.config:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 |
5 |
6 |
7 |
8 |
9 |
10 |
--------------------------------------------------------------------------------
/src/Apworks.Storage.MySql/key.snk:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/daxnet/Apworks/6de4b83e94c1e39b55c93590617e4491880eed39/src/Apworks.Storage.MySql/key.snk
--------------------------------------------------------------------------------
/src/Apworks.Storage.MySql/packages.config:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 |
--------------------------------------------------------------------------------
/src/Apworks/Apworks.nuspec:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 | Apworks
5 | 2.5.4878.35266
6 | Apworks
7 | apworks.org
8 | apworks.org
9 | false
10 | Apworks Application Development Framework
11 | Copyright © 2009-2013, apworks.org
12 |
13 |
14 |
15 |
16 |
17 |
18 |
19 |
20 |
--------------------------------------------------------------------------------
/src/Apworks/Bus/BusException.cs:
--------------------------------------------------------------------------------
1 | using System;
2 | using System.Runtime.InteropServices;
3 |
4 | namespace Apworks.Bus
5 | {
6 | ///
7 | /// Represents the errors occur when performing bus operations in Apworks.
8 | ///
9 | [Serializable]
10 | [ComVisible(true)]
11 | [ClassInterface(ClassInterfaceType.None)]
12 | [ComDefaultInterface(typeof(_Exception))]
13 | public class BusException : InfrastructureException
14 | {
15 | #region Ctor
16 | ///
17 | /// Initializes a new instance of the BusException class.
18 | ///
19 | public BusException() : base() { }
20 | ///
21 | /// Initializes a new instance of the BusException class with the specified
22 | /// error message.
23 | ///
24 | /// The message that describes the error.
25 | public BusException(string message) : base(message) { }
26 | ///
27 | /// Initializes a new instance of the BusException class with the specified
28 | /// error message and the inner exception that is the cause of this exception.
29 | ///
30 | /// The message that describes the error.
31 | /// The inner exception that is the cause of this exception.
32 | public BusException(string message, Exception innerException) : base(message, innerException) { }
33 | ///
34 | /// Initializes a new instance of the BusException class with the specified
35 | /// string formatter and the arguments that are used for formatting the message which
36 | /// describes the error.
37 | ///
38 | /// The string formatter which is used for formatting the error message.
39 | /// The arguments that are used by the formatter to build the error message.
40 | public BusException(string format, params object[] args) : base(string.Format(format, args)) { }
41 | #endregion
42 | }
43 | }
44 |
--------------------------------------------------------------------------------
/src/Apworks/Bus/DispatchingException.cs:
--------------------------------------------------------------------------------
1 | using System;
2 | using System.Runtime.InteropServices;
3 |
4 | namespace Apworks.Bus
5 | {
6 | ///
7 | /// Represents the errors occur when dispatching the messages.
8 | ///
9 | [Serializable]
10 | [ComVisible(true)]
11 | [ClassInterface(ClassInterfaceType.None)]
12 | [ComDefaultInterface(typeof(_Exception))]
13 | public class DispatchingException : InfrastructureException
14 | {
15 | #region Ctor
16 | ///
17 | /// Initializes a new instance of the DispatcherException class.
18 | ///
19 | public DispatchingException() : base() { }
20 | ///
21 | /// Initializes a new instance of the DispatcherException class with the specified
22 | /// error message.
23 | ///
24 | /// The message that describes the error.
25 | public DispatchingException(string message) : base(message) { }
26 | ///
27 | /// Initializes a new instance of the DispatcherException class with the specified
28 | /// error message and the inner exception that is the cause of this exception.
29 | ///
30 | /// The message that describes the error.
31 | /// The inner exception that is the cause of this exception.
32 | public DispatchingException(string message, Exception innerException) : base(message, innerException) { }
33 | ///
34 | /// Initializes a new instance of the DispatcherException class with the specified
35 | /// string formatter and the arguments that are used for formatting the message which
36 | /// describes the error.
37 | ///
38 | /// The string formatter which is used for formatting the error message.
39 | /// The arguments that are used by the formatter to build the error message.
40 | public DispatchingException(string format, params object[] args) : base(string.Format(format, args)) { }
41 | #endregion
42 | }
43 | }
44 |
--------------------------------------------------------------------------------
/src/Apworks/Bus/ICommandBus.cs:
--------------------------------------------------------------------------------
1 | // ==================================================================================================================
2 | // ,::i BBB
3 | // BBBBBi EBBB
4 | // MBBNBBU BBB,
5 | // BBB. BBB BBB,BBBBM BBB UBBB MBB, LBBBBBO, :BBG,BBB :BBB .BBBU kBBBBBF
6 | // BBB, BBB 7BBBBS2BBBO BBB iBBBB YBBJ :BBBMYNBBB: FBBBBBB: OBB: 5BBB, BBBi ,M,
7 | // MBBY BBB. 8BBB :BBB BBB .BBUBB BB1 BBBi kBBB BBBM BBBjBBBr BBB1
8 | // BBBBBBBBBBBu BBB FBBP MBM BB. BB BBM 7BBB MBBY .BBB 7BBGkBB1 JBBBBi
9 | // PBBBFE0GkBBBB 7BBX uBBB MBBMBu .BBOBB rBBB kBBB ZBBq BBB: BBBJ . iBBB
10 | //BBBB iBBB BBBBBBBBBE EBBBB ,BBBB MBBBBBBBM BBB, iBBB .BBB2 :BBBBBBB7
11 | //vr7 777 BBBu8O5: .77r Lr7 .7EZk; L77 .Y7r irLY JNMMF:
12 | // LBBj
13 | //
14 | // Apworks Application Development Framework
15 | // Copyright (C) 2010-2015 by daxnet.
16 | // Licensed under the Apache License, Version 2.0 (the "License");
17 | // you may not use this file except in compliance with the License.
18 | // You may obtain a copy of the License at
19 | // http://www.apache.org/licenses/LICENSE-2.0
20 | // Unless required by applicable law or agreed to in writing, software
21 | // distributed under the License is distributed on an "AS IS" BASIS,
22 | // WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
23 | // See the License for the specific language governing permissions and
24 | // limitations under the License.
25 | // ==================================================================================================================
26 |
27 | using Apworks.Commands;
28 |
29 | namespace Apworks.Bus
30 | {
31 | ///
32 | /// Represents that the implemented classes are command buses.
33 | ///
34 | public interface ICommandBus : IBus
35 | {
36 | }
37 | }
38 |
--------------------------------------------------------------------------------
/src/Apworks/Bus/IEventBus.cs:
--------------------------------------------------------------------------------
1 | // ==================================================================================================================
2 | // ,::i BBB
3 | // BBBBBi EBBB
4 | // MBBNBBU BBB,
5 | // BBB. BBB BBB,BBBBM BBB UBBB MBB, LBBBBBO, :BBG,BBB :BBB .BBBU kBBBBBF
6 | // BBB, BBB 7BBBBS2BBBO BBB iBBBB YBBJ :BBBMYNBBB: FBBBBBB: OBB: 5BBB, BBBi ,M,
7 | // MBBY BBB. 8BBB :BBB BBB .BBUBB BB1 BBBi kBBB BBBM BBBjBBBr BBB1
8 | // BBBBBBBBBBBu BBB FBBP MBM BB. BB BBM 7BBB MBBY .BBB 7BBGkBB1 JBBBBi
9 | // PBBBFE0GkBBBB 7BBX uBBB MBBMBu .BBOBB rBBB kBBB ZBBq BBB: BBBJ . iBBB
10 | //BBBB iBBB BBBBBBBBBE EBBBB ,BBBB MBBBBBBBM BBB, iBBB .BBB2 :BBBBBBB7
11 | //vr7 777 BBBu8O5: .77r Lr7 .7EZk; L77 .Y7r irLY JNMMF:
12 | // LBBj
13 | //
14 | // Apworks Application Development Framework
15 | // Copyright (C) 2010-2015 by daxnet.
16 | // Licensed under the Apache License, Version 2.0 (the "License");
17 | // you may not use this file except in compliance with the License.
18 | // You may obtain a copy of the License at
19 | // http://www.apache.org/licenses/LICENSE-2.0
20 | // Unless required by applicable law or agreed to in writing, software
21 | // distributed under the License is distributed on an "AS IS" BASIS,
22 | // WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
23 | // See the License for the specific language governing permissions and
24 | // limitations under the License.
25 | // ==================================================================================================================
26 |
27 | using Apworks.Events;
28 |
29 | namespace Apworks.Bus
30 | {
31 | ///
32 | /// Represents that the implemented classes are event buses.
33 | ///
34 | public interface IEventBus : IBus
35 | {
36 | }
37 | }
38 |
--------------------------------------------------------------------------------
/src/Apworks/Bus/RegisterDispatchAttribute.cs:
--------------------------------------------------------------------------------
1 | using System;
2 |
3 | namespace Apworks.Bus
4 | {
5 | ///
6 | /// Represents that the instances of the decorated interfaces
7 | /// can be registered in a message dispatcher.
8 | ///
9 | [AttributeUsage(AttributeTargets.Interface)]
10 | public class RegisterDispatchAttribute : Attribute
11 | {
12 | }
13 | }
14 |
--------------------------------------------------------------------------------
/src/Apworks/Commands/ICommand.cs:
--------------------------------------------------------------------------------
1 | // ==================================================================================================================
2 | // ,::i BBB
3 | // BBBBBi EBBB
4 | // MBBNBBU BBB,
5 | // BBB. BBB BBB,BBBBM BBB UBBB MBB, LBBBBBO, :BBG,BBB :BBB .BBBU kBBBBBF
6 | // BBB, BBB 7BBBBS2BBBO BBB iBBBB YBBJ :BBBMYNBBB: FBBBBBB: OBB: 5BBB, BBBi ,M,
7 | // MBBY BBB. 8BBB :BBB BBB .BBUBB BB1 BBBi kBBB BBBM BBBjBBBr BBB1
8 | // BBBBBBBBBBBu BBB FBBP MBM BB. BB BBM 7BBB MBBY .BBB 7BBGkBB1 JBBBBi
9 | // PBBBFE0GkBBBB 7BBX uBBB MBBMBu .BBOBB rBBB kBBB ZBBq BBB: BBBJ . iBBB
10 | //BBBB iBBB BBBBBBBBBE EBBBB ,BBBB MBBBBBBBM BBB, iBBB .BBB2 :BBBBBBB7
11 | //vr7 777 BBBu8O5: .77r Lr7 .7EZk; L77 .Y7r irLY JNMMF:
12 | // LBBj
13 | //
14 | // Apworks Application Development Framework
15 | // Copyright (C) 2010-2015 by daxnet.
16 | // Licensed under the Apache License, Version 2.0 (the "License");
17 | // you may not use this file except in compliance with the License.
18 | // You may obtain a copy of the License at
19 | // http://www.apache.org/licenses/LICENSE-2.0
20 | // Unless required by applicable law or agreed to in writing, software
21 | // distributed under the License is distributed on an "AS IS" BASIS,
22 | // WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
23 | // See the License for the specific language governing permissions and
24 | // limitations under the License.
25 | // ==================================================================================================================
26 |
27 |
28 | namespace Apworks.Commands
29 | {
30 | ///
31 | /// Represents that the implemented classes are commands.
32 | ///
33 | public interface ICommand : IEntity
34 | {
35 |
36 | }
37 | }
38 |
--------------------------------------------------------------------------------
/src/Apworks/Commands/ICommandHandler.cs:
--------------------------------------------------------------------------------
1 | // ==================================================================================================================
2 | // ,::i BBB
3 | // BBBBBi EBBB
4 | // MBBNBBU BBB,
5 | // BBB. BBB BBB,BBBBM BBB UBBB MBB, LBBBBBO, :BBG,BBB :BBB .BBBU kBBBBBF
6 | // BBB, BBB 7BBBBS2BBBO BBB iBBBB YBBJ :BBBMYNBBB: FBBBBBB: OBB: 5BBB, BBBi ,M,
7 | // MBBY BBB. 8BBB :BBB BBB .BBUBB BB1 BBBi kBBB BBBM BBBjBBBr BBB1
8 | // BBBBBBBBBBBu BBB FBBP MBM BB. BB BBM 7BBB MBBY .BBB 7BBGkBB1 JBBBBi
9 | // PBBBFE0GkBBBB 7BBX uBBB MBBMBu .BBOBB rBBB kBBB ZBBq BBB: BBBJ . iBBB
10 | //BBBB iBBB BBBBBBBBBE EBBBB ,BBBB MBBBBBBBM BBB, iBBB .BBB2 :BBBBBBB7
11 | //vr7 777 BBBu8O5: .77r Lr7 .7EZk; L77 .Y7r irLY JNMMF:
12 | // LBBj
13 | //
14 | // Apworks Application Development Framework
15 | // Copyright (C) 2010-2015 by daxnet.
16 | // Licensed under the Apache License, Version 2.0 (the "License");
17 | // you may not use this file except in compliance with the License.
18 | // You may obtain a copy of the License at
19 | // http://www.apache.org/licenses/LICENSE-2.0
20 | // Unless required by applicable law or agreed to in writing, software
21 | // distributed under the License is distributed on an "AS IS" BASIS,
22 | // WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
23 | // See the License for the specific language governing permissions and
24 | // limitations under the License.
25 | // ==================================================================================================================
26 |
27 | using Apworks.Bus;
28 |
29 | namespace Apworks.Commands
30 | {
31 | ///
32 | /// Represents that the implemented classes are command handlers.
33 | ///
34 | /// The type of the command to be handled.
35 | [RegisterDispatch]
36 | public interface ICommandHandler : IHandler
37 | where TCommand : ICommand
38 | {
39 |
40 | }
41 | }
42 |
--------------------------------------------------------------------------------
/src/Apworks/Config/ApworksConfiguration.csd.config:
--------------------------------------------------------------------------------
1 |
2 |
10 |
11 |
12 |
13 |
14 |
15 |
23 |
24 |
25 |
--------------------------------------------------------------------------------
/src/Apworks/Config/IConfigSource.cs:
--------------------------------------------------------------------------------
1 | // ==================================================================================================================
2 | // ,::i BBB
3 | // BBBBBi EBBB
4 | // MBBNBBU BBB,
5 | // BBB. BBB BBB,BBBBM BBB UBBB MBB, LBBBBBO, :BBG,BBB :BBB .BBBU kBBBBBF
6 | // BBB, BBB 7BBBBS2BBBO BBB iBBBB YBBJ :BBBMYNBBB: FBBBBBB: OBB: 5BBB, BBBi ,M,
7 | // MBBY BBB. 8BBB :BBB BBB .BBUBB BB1 BBBi kBBB BBBM BBBjBBBr BBB1
8 | // BBBBBBBBBBBu BBB FBBP MBM BB. BB BBM 7BBB MBBY .BBB 7BBGkBB1 JBBBBi
9 | // PBBBFE0GkBBBB 7BBX uBBB MBBMBu .BBOBB rBBB kBBB ZBBq BBB: BBBJ . iBBB
10 | //BBBB iBBB BBBBBBBBBE EBBBB ,BBBB MBBBBBBBM BBB, iBBB .BBB2 :BBBBBBB7
11 | //vr7 777 BBBu8O5: .77r Lr7 .7EZk; L77 .Y7r irLY JNMMF:
12 | // LBBj
13 | //
14 | // Apworks Application Development Framework
15 | // Copyright (C) 2010-2015 by daxnet.
16 | // Licensed under the Apache License, Version 2.0 (the "License");
17 | // you may not use this file except in compliance with the License.
18 | // You may obtain a copy of the License at
19 | // http://www.apache.org/licenses/LICENSE-2.0
20 | // Unless required by applicable law or agreed to in writing, software
21 | // distributed under the License is distributed on an "AS IS" BASIS,
22 | // WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
23 | // See the License for the specific language governing permissions and
24 | // limitations under the License.
25 | // ==================================================================================================================
26 |
27 | namespace Apworks.Config
28 | {
29 | ///
30 | /// Represents that the implemented classes are configuration sources for Apworks framework.
31 | ///
32 | public interface IConfigSource
33 | {
34 | ///
35 | /// Gets the instance of class.
36 | ///
37 | ApworksConfigSection Config { get; }
38 | }
39 | }
40 |
--------------------------------------------------------------------------------
/src/Apworks/DomainException.cs:
--------------------------------------------------------------------------------
1 | using System;
2 | using System.Runtime.InteropServices;
3 |
4 | namespace Apworks
5 | {
6 | ///
7 | /// Represents errors that occur in the domain layer of Apworks framework.
8 | ///
9 | [Serializable]
10 | [ComVisible(true)]
11 | [ClassInterface(ClassInterfaceType.None)]
12 | [ComDefaultInterface(typeof(_Exception))]
13 | public class DomainException : ApworksException
14 | {
15 | #region Ctor
16 | ///
17 | /// Initializes a new instance of the DomainException class.
18 | ///
19 | public DomainException() : base() { }
20 | ///
21 | /// Initializes a new instance of the DomainException class with the specified
22 | /// error message.
23 | ///
24 | /// The message that describes the error.
25 | public DomainException(string message) : base(message) { }
26 | ///
27 | /// Initializes a new instance of the DomainException class with the specified
28 | /// error message and the inner exception that is the cause of this exception.
29 | ///
30 | /// The message that describes the error.
31 | /// The inner exception that is the cause of this exception.
32 | public DomainException(string message, Exception innerException) : base(message, innerException) { }
33 | ///
34 | /// Initializes a new instance of the DomainException class with the specified
35 | /// string formatter and the arguments that are used for formatting the message which
36 | /// describes the error.
37 | ///
38 | /// The string formatter which is used for formatting the error message.
39 | /// The arguments that are used by the formatter to build the error message.
40 | public DomainException(string format, params object[] args) : base(string.Format(format, args)) { }
41 | #endregion
42 | }
43 | }
44 |
--------------------------------------------------------------------------------
/src/Apworks/Events/IDomainEventHandler.cs:
--------------------------------------------------------------------------------
1 | // ==================================================================================================================
2 | // ,::i BBB
3 | // BBBBBi EBBB
4 | // MBBNBBU BBB,
5 | // BBB. BBB BBB,BBBBM BBB UBBB MBB, LBBBBBO, :BBG,BBB :BBB .BBBU kBBBBBF
6 | // BBB, BBB 7BBBBS2BBBO BBB iBBBB YBBJ :BBBMYNBBB: FBBBBBB: OBB: 5BBB, BBBi ,M,
7 | // MBBY BBB. 8BBB :BBB BBB .BBUBB BB1 BBBi kBBB BBBM BBBjBBBr BBB1
8 | // BBBBBBBBBBBu BBB FBBP MBM BB. BB BBM 7BBB MBBY .BBB 7BBGkBB1 JBBBBi
9 | // PBBBFE0GkBBBB 7BBX uBBB MBBMBu .BBOBB rBBB kBBB ZBBq BBB: BBBJ . iBBB
10 | //BBBB iBBB BBBBBBBBBE EBBBB ,BBBB MBBBBBBBM BBB, iBBB .BBB2 :BBBBBBB7
11 | //vr7 777 BBBu8O5: .77r Lr7 .7EZk; L77 .Y7r irLY JNMMF:
12 | // LBBj
13 | //
14 | // Apworks Application Development Framework
15 | // Copyright (C) 2010-2015 by daxnet.
16 | // Licensed under the Apache License, Version 2.0 (the "License");
17 | // you may not use this file except in compliance with the License.
18 | // You may obtain a copy of the License at
19 | // http://www.apache.org/licenses/LICENSE-2.0
20 | // Unless required by applicable law or agreed to in writing, software
21 | // distributed under the License is distributed on an "AS IS" BASIS,
22 | // WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
23 | // See the License for the specific language governing permissions and
24 | // limitations under the License.
25 | // ==================================================================================================================
26 |
27 |
28 | namespace Apworks.Events
29 | {
30 | ///
31 | /// Represents the event handler for domain events.
32 | ///
33 | /// The type of the domain event to be handled by current handler.
34 | public interface IDomainEventHandler : IEventHandler
35 | where TDomainEvent : class, IDomainEvent
36 | {
37 |
38 | }
39 | }
40 |
--------------------------------------------------------------------------------
/src/Apworks/Events/IEventHandler.cs:
--------------------------------------------------------------------------------
1 | // ==================================================================================================================
2 | // ,::i BBB
3 | // BBBBBi EBBB
4 | // MBBNBBU BBB,
5 | // BBB. BBB BBB,BBBBM BBB UBBB MBB, LBBBBBO, :BBG,BBB :BBB .BBBU kBBBBBF
6 | // BBB, BBB 7BBBBS2BBBO BBB iBBBB YBBJ :BBBMYNBBB: FBBBBBB: OBB: 5BBB, BBBi ,M,
7 | // MBBY BBB. 8BBB :BBB BBB .BBUBB BB1 BBBi kBBB BBBM BBBjBBBr BBB1
8 | // BBBBBBBBBBBu BBB FBBP MBM BB. BB BBM 7BBB MBBY .BBB 7BBGkBB1 JBBBBi
9 | // PBBBFE0GkBBBB 7BBX uBBB MBBMBu .BBOBB rBBB kBBB ZBBq BBB: BBBJ . iBBB
10 | //BBBB iBBB BBBBBBBBBE EBBBB ,BBBB MBBBBBBBM BBB, iBBB .BBB2 :BBBBBBB7
11 | //vr7 777 BBBu8O5: .77r Lr7 .7EZk; L77 .Y7r irLY JNMMF:
12 | // LBBj
13 | //
14 | // Apworks Application Development Framework
15 | // Copyright (C) 2010-2015 by daxnet.
16 | // Licensed under the Apache License, Version 2.0 (the "License");
17 | // you may not use this file except in compliance with the License.
18 | // You may obtain a copy of the License at
19 | // http://www.apache.org/licenses/LICENSE-2.0
20 | // Unless required by applicable law or agreed to in writing, software
21 | // distributed under the License is distributed on an "AS IS" BASIS,
22 | // WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
23 | // See the License for the specific language governing permissions and
24 | // limitations under the License.
25 | // ==================================================================================================================
26 |
27 | using Apworks.Bus;
28 |
29 | namespace Apworks.Events
30 | {
31 | ///
32 | /// Represents that the implemented classes are event handlers.
33 | ///
34 | /// The type of the event to be handled.
35 | [RegisterDispatch]
36 | public interface IEventHandler : IHandler
37 | where TEvent : class, IEvent
38 | {
39 | }
40 | }
41 |
--------------------------------------------------------------------------------
/src/Apworks/Events/Serialization/DomainEventBinarySerializer.cs:
--------------------------------------------------------------------------------
1 | // ==================================================================================================================
2 | // ,::i BBB
3 | // BBBBBi EBBB
4 | // MBBNBBU BBB,
5 | // BBB. BBB BBB,BBBBM BBB UBBB MBB, LBBBBBO, :BBG,BBB :BBB .BBBU kBBBBBF
6 | // BBB, BBB 7BBBBS2BBBO BBB iBBBB YBBJ :BBBMYNBBB: FBBBBBB: OBB: 5BBB, BBBi ,M,
7 | // MBBY BBB. 8BBB :BBB BBB .BBUBB BB1 BBBi kBBB BBBM BBBjBBBr BBB1
8 | // BBBBBBBBBBBu BBB FBBP MBM BB. BB BBM 7BBB MBBY .BBB 7BBGkBB1 JBBBBi
9 | // PBBBFE0GkBBBB 7BBX uBBB MBBMBu .BBOBB rBBB kBBB ZBBq BBB: BBBJ . iBBB
10 | //BBBB iBBB BBBBBBBBBE EBBBB ,BBBB MBBBBBBBM BBB, iBBB .BBB2 :BBBBBBB7
11 | //vr7 777 BBBu8O5: .77r Lr7 .7EZk; L77 .Y7r irLY JNMMF:
12 | // LBBj
13 | //
14 | // Apworks Application Development Framework
15 | // Copyright (C) 2010-2015 by daxnet.
16 | // Licensed under the Apache License, Version 2.0 (the "License");
17 | // you may not use this file except in compliance with the License.
18 | // You may obtain a copy of the License at
19 | // http://www.apache.org/licenses/LICENSE-2.0
20 | // Unless required by applicable law or agreed to in writing, software
21 | // distributed under the License is distributed on an "AS IS" BASIS,
22 | // WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
23 | // See the License for the specific language governing permissions and
24 | // limitations under the License.
25 | // ==================================================================================================================
26 |
27 | using Apworks.Serialization;
28 |
29 | namespace Apworks.Events.Serialization
30 | {
31 | ///
32 | /// Represents the serializer for domain events that serializes/deserializes the domain events
33 | /// with binary format.
34 | ///
35 | public class DomainEventBinarySerializer : ObjectBinarySerializer, IDomainEventSerializer
36 | {
37 |
38 | }
39 | }
40 |
--------------------------------------------------------------------------------
/src/Apworks/Events/Serialization/DomainEventDataContractSerializer.cs:
--------------------------------------------------------------------------------
1 | // ==================================================================================================================
2 | // ,::i BBB
3 | // BBBBBi EBBB
4 | // MBBNBBU BBB,
5 | // BBB. BBB BBB,BBBBM BBB UBBB MBB, LBBBBBO, :BBG,BBB :BBB .BBBU kBBBBBF
6 | // BBB, BBB 7BBBBS2BBBO BBB iBBBB YBBJ :BBBMYNBBB: FBBBBBB: OBB: 5BBB, BBBi ,M,
7 | // MBBY BBB. 8BBB :BBB BBB .BBUBB BB1 BBBi kBBB BBBM BBBjBBBr BBB1
8 | // BBBBBBBBBBBu BBB FBBP MBM BB. BB BBM 7BBB MBBY .BBB 7BBGkBB1 JBBBBi
9 | // PBBBFE0GkBBBB 7BBX uBBB MBBMBu .BBOBB rBBB kBBB ZBBq BBB: BBBJ . iBBB
10 | //BBBB iBBB BBBBBBBBBE EBBBB ,BBBB MBBBBBBBM BBB, iBBB .BBB2 :BBBBBBB7
11 | //vr7 777 BBBu8O5: .77r Lr7 .7EZk; L77 .Y7r irLY JNMMF:
12 | // LBBj
13 | //
14 | // Apworks Application Development Framework
15 | // Copyright (C) 2010-2015 by daxnet.
16 | // Licensed under the Apache License, Version 2.0 (the "License");
17 | // you may not use this file except in compliance with the License.
18 | // You may obtain a copy of the License at
19 | // http://www.apache.org/licenses/LICENSE-2.0
20 | // Unless required by applicable law or agreed to in writing, software
21 | // distributed under the License is distributed on an "AS IS" BASIS,
22 | // WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
23 | // See the License for the specific language governing permissions and
24 | // limitations under the License.
25 | // ==================================================================================================================
26 |
27 | using Apworks.Serialization;
28 |
29 | namespace Apworks.Events.Serialization
30 | {
31 | ///
32 | /// Represents the serializer for domain events that serializes/deserializes the domain events
33 | /// with DataContract format.
34 | ///
35 | public class DomainEventDataContractSerializer : ObjectDataContractSerializer, IDomainEventSerializer
36 | {
37 | }
38 | }
39 |
--------------------------------------------------------------------------------
/src/Apworks/Events/Serialization/DomainEventJsonSerializer.cs:
--------------------------------------------------------------------------------
1 | // ==================================================================================================================
2 | // ,::i BBB
3 | // BBBBBi EBBB
4 | // MBBNBBU BBB,
5 | // BBB. BBB BBB,BBBBM BBB UBBB MBB, LBBBBBO, :BBG,BBB :BBB .BBBU kBBBBBF
6 | // BBB, BBB 7BBBBS2BBBO BBB iBBBB YBBJ :BBBMYNBBB: FBBBBBB: OBB: 5BBB, BBBi ,M,
7 | // MBBY BBB. 8BBB :BBB BBB .BBUBB BB1 BBBi kBBB BBBM BBBjBBBr BBB1
8 | // BBBBBBBBBBBu BBB FBBP MBM BB. BB BBM 7BBB MBBY .BBB 7BBGkBB1 JBBBBi
9 | // PBBBFE0GkBBBB 7BBX uBBB MBBMBu .BBOBB rBBB kBBB ZBBq BBB: BBBJ . iBBB
10 | //BBBB iBBB BBBBBBBBBE EBBBB ,BBBB MBBBBBBBM BBB, iBBB .BBB2 :BBBBBBB7
11 | //vr7 777 BBBu8O5: .77r Lr7 .7EZk; L77 .Y7r irLY JNMMF:
12 | // LBBj
13 | //
14 | // Apworks Application Development Framework
15 | // Copyright (C) 2010-2015 by daxnet.
16 | // Licensed under the Apache License, Version 2.0 (the "License");
17 | // you may not use this file except in compliance with the License.
18 | // You may obtain a copy of the License at
19 | // http://www.apache.org/licenses/LICENSE-2.0
20 | // Unless required by applicable law or agreed to in writing, software
21 | // distributed under the License is distributed on an "AS IS" BASIS,
22 | // WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
23 | // See the License for the specific language governing permissions and
24 | // limitations under the License.
25 | // ==================================================================================================================
26 |
27 | using Apworks.Serialization;
28 |
29 | namespace Apworks.Events.Serialization
30 | {
31 | ///
32 | /// Represents the serializer for domain events that serializes/deserializes the domain events
33 | /// with Json format.
34 | ///
35 | public class DomainEventJsonSerializer : ObjectJsonSerializer, IDomainEventSerializer
36 | {
37 | }
38 | }
39 |
--------------------------------------------------------------------------------
/src/Apworks/Events/Serialization/DomainEventXmlSerializer.cs:
--------------------------------------------------------------------------------
1 | // ==================================================================================================================
2 | // ,::i BBB
3 | // BBBBBi EBBB
4 | // MBBNBBU BBB,
5 | // BBB. BBB BBB,BBBBM BBB UBBB MBB, LBBBBBO, :BBG,BBB :BBB .BBBU kBBBBBF
6 | // BBB, BBB 7BBBBS2BBBO BBB iBBBB YBBJ :BBBMYNBBB: FBBBBBB: OBB: 5BBB, BBBi ,M,
7 | // MBBY BBB. 8BBB :BBB BBB .BBUBB BB1 BBBi kBBB BBBM BBBjBBBr BBB1
8 | // BBBBBBBBBBBu BBB FBBP MBM BB. BB BBM 7BBB MBBY .BBB 7BBGkBB1 JBBBBi
9 | // PBBBFE0GkBBBB 7BBX uBBB MBBMBu .BBOBB rBBB kBBB ZBBq BBB: BBBJ . iBBB
10 | //BBBB iBBB BBBBBBBBBE EBBBB ,BBBB MBBBBBBBM BBB, iBBB .BBB2 :BBBBBBB7
11 | //vr7 777 BBBu8O5: .77r Lr7 .7EZk; L77 .Y7r irLY JNMMF:
12 | // LBBj
13 | //
14 | // Apworks Application Development Framework
15 | // Copyright (C) 2010-2015 by daxnet.
16 | // Licensed under the Apache License, Version 2.0 (the "License");
17 | // you may not use this file except in compliance with the License.
18 | // You may obtain a copy of the License at
19 | // http://www.apache.org/licenses/LICENSE-2.0
20 | // Unless required by applicable law or agreed to in writing, software
21 | // distributed under the License is distributed on an "AS IS" BASIS,
22 | // WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
23 | // See the License for the specific language governing permissions and
24 | // limitations under the License.
25 | // ==================================================================================================================
26 |
27 | using Apworks.Serialization;
28 |
29 | namespace Apworks.Events.Serialization
30 | {
31 | ///
32 | /// Represents the serializer for domain events that serializes/deserializes the domain events
33 | /// with XML format.
34 | ///
35 | public class DomainEventXmlSerializer : ObjectXmlSerializer, IDomainEventSerializer
36 | {
37 | }
38 | }
39 |
--------------------------------------------------------------------------------
/src/Apworks/Events/Serialization/IDomainEventSerializer.cs:
--------------------------------------------------------------------------------
1 | // ==================================================================================================================
2 | // ,::i BBB
3 | // BBBBBi EBBB
4 | // MBBNBBU BBB,
5 | // BBB. BBB BBB,BBBBM BBB UBBB MBB, LBBBBBO, :BBG,BBB :BBB .BBBU kBBBBBF
6 | // BBB, BBB 7BBBBS2BBBO BBB iBBBB YBBJ :BBBMYNBBB: FBBBBBB: OBB: 5BBB, BBBi ,M,
7 | // MBBY BBB. 8BBB :BBB BBB .BBUBB BB1 BBBi kBBB BBBM BBBjBBBr BBB1
8 | // BBBBBBBBBBBu BBB FBBP MBM BB. BB BBM 7BBB MBBY .BBB 7BBGkBB1 JBBBBi
9 | // PBBBFE0GkBBBB 7BBX uBBB MBBMBu .BBOBB rBBB kBBB ZBBq BBB: BBBJ . iBBB
10 | //BBBB iBBB BBBBBBBBBE EBBBB ,BBBB MBBBBBBBM BBB, iBBB .BBB2 :BBBBBBB7
11 | //vr7 777 BBBu8O5: .77r Lr7 .7EZk; L77 .Y7r irLY JNMMF:
12 | // LBBj
13 | //
14 | // Apworks Application Development Framework
15 | // Copyright (C) 2010-2015 by daxnet.
16 | // Licensed under the Apache License, Version 2.0 (the "License");
17 | // you may not use this file except in compliance with the License.
18 | // You may obtain a copy of the License at
19 | // http://www.apache.org/licenses/LICENSE-2.0
20 | // Unless required by applicable law or agreed to in writing, software
21 | // distributed under the License is distributed on an "AS IS" BASIS,
22 | // WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
23 | // See the License for the specific language governing permissions and
24 | // limitations under the License.
25 | // ==================================================================================================================
26 |
27 | using Apworks.Serialization;
28 |
29 | namespace Apworks.Events.Serialization
30 | {
31 | ///
32 | /// Represents that the implemented classes are domain event serializers.
33 | ///
34 | public interface IDomainEventSerializer : IObjectSerializer
35 | {
36 | }
37 | }
38 |
--------------------------------------------------------------------------------
/src/Apworks/Exceptions/ExceptionHandler.cs:
--------------------------------------------------------------------------------
1 | using System;
2 |
3 | namespace Apworks.Exceptions
4 | {
5 | ///
6 | /// Represents the base class of exception handlers.
7 | ///
8 | /// The type of the exception being handled.
9 | public abstract class ExceptionHandler : IExceptionHandler
10 | where TException : Exception
11 | {
12 | #region Protected Methods
13 | ///
14 | /// Performs the exception handling internally.
15 | ///
16 | /// The exception to be handled.
17 | /// True if the exception was handled successfully, otherwise, false.
18 | protected abstract bool DoHandle(TException ex);
19 | #endregion
20 |
21 | #region Public Methods
22 | ///
23 | /// Handles a specific exception.
24 | ///
25 | /// The exception to be handled.
26 | /// True if the exceptioin was successfully handled, otherwise, false.
27 | public virtual bool HandleException(Exception ex)
28 | {
29 | return DoHandle(ex as TException);
30 | }
31 | #endregion
32 | }
33 | }
34 |
--------------------------------------------------------------------------------
/src/Apworks/Exceptions/IExceptionHandler.cs:
--------------------------------------------------------------------------------
1 | // ==================================================================================================================
2 | // ,::i BBB
3 | // BBBBBi EBBB
4 | // MBBNBBU BBB,
5 | // BBB. BBB BBB,BBBBM BBB UBBB MBB, LBBBBBO, :BBG,BBB :BBB .BBBU kBBBBBF
6 | // BBB, BBB 7BBBBS2BBBO BBB iBBBB YBBJ :BBBMYNBBB: FBBBBBB: OBB: 5BBB, BBBi ,M,
7 | // MBBY BBB. 8BBB :BBB BBB .BBUBB BB1 BBBi kBBB BBBM BBBjBBBr BBB1
8 | // BBBBBBBBBBBu BBB FBBP MBM BB. BB BBM 7BBB MBBY .BBB 7BBGkBB1 JBBBBi
9 | // PBBBFE0GkBBBB 7BBX uBBB MBBMBu .BBOBB rBBB kBBB ZBBq BBB: BBBJ . iBBB
10 | //BBBB iBBB BBBBBBBBBE EBBBB ,BBBB MBBBBBBBM BBB, iBBB .BBB2 :BBBBBBB7
11 | //vr7 777 BBBu8O5: .77r Lr7 .7EZk; L77 .Y7r irLY JNMMF:
12 | // LBBj
13 | //
14 | // Apworks Application Development Framework
15 | // Copyright (C) 2010-2015 by daxnet
16 | // Licensed under the Apache License, Version 2.0 (the "License");
17 | // you may not use this file except in compliance with the License.
18 | // You may obtain a copy of the License at
19 | // http://www.apache.org/licenses/LICENSE-2.0
20 | // Unless required by applicable law or agreed to in writing, software
21 | // distributed under the License is distributed on an "AS IS" BASIS,
22 | // WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
23 | // See the License for the specific language governing permissions and
24 | // limitations under the License.
25 | // ==================================================================================================================
26 |
27 | using System;
28 |
29 | namespace Apworks.Exceptions
30 | {
31 | ///
32 | /// Represents that the implemented classes are exception handlers.
33 | ///
34 | public interface IExceptionHandler
35 | {
36 | ///
37 | /// Handles a specific exception.
38 | ///
39 | /// The exception to be handled.
40 | /// True if the exceptioin was successfully handled, otherwise, false.
41 | bool HandleException(Exception ex);
42 | }
43 | }
44 |
--------------------------------------------------------------------------------
/src/Apworks/Generators/IIdentityGenerator.cs:
--------------------------------------------------------------------------------
1 | // ==================================================================================================================
2 | // ,::i BBB
3 | // BBBBBi EBBB
4 | // MBBNBBU BBB,
5 | // BBB. BBB BBB,BBBBM BBB UBBB MBB, LBBBBBO, :BBG,BBB :BBB .BBBU kBBBBBF
6 | // BBB, BBB 7BBBBS2BBBO BBB iBBBB YBBJ :BBBMYNBBB: FBBBBBB: OBB: 5BBB, BBBi ,M,
7 | // MBBY BBB. 8BBB :BBB BBB .BBUBB BB1 BBBi kBBB BBBM BBBjBBBr BBB1
8 | // BBBBBBBBBBBu BBB FBBP MBM BB. BB BBM 7BBB MBBY .BBB 7BBGkBB1 JBBBBi
9 | // PBBBFE0GkBBBB 7BBX uBBB MBBMBu .BBOBB rBBB kBBB ZBBq BBB: BBBJ . iBBB
10 | //BBBB iBBB BBBBBBBBBE EBBBB ,BBBB MBBBBBBBM BBB, iBBB .BBB2 :BBBBBBB7
11 | //vr7 777 BBBu8O5: .77r Lr7 .7EZk; L77 .Y7r irLY JNMMF:
12 | // LBBj
13 | //
14 | // Apworks Application Development Framework
15 | // Copyright (C) 2010-2015 by daxnet.
16 | // Licensed under the Apache License, Version 2.0 (the "License");
17 | // you may not use this file except in compliance with the License.
18 | // You may obtain a copy of the License at
19 | // http://www.apache.org/licenses/LICENSE-2.0
20 | // Unless required by applicable law or agreed to in writing, software
21 | // distributed under the License is distributed on an "AS IS" BASIS,
22 | // WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
23 | // See the License for the specific language governing permissions and
24 | // limitations under the License.
25 | // ==================================================================================================================
26 |
27 |
28 | namespace Apworks.Generators
29 | {
30 | ///
31 | /// Represents that the implemented classes are identity generators.
32 | ///
33 | public interface IIdentityGenerator
34 | {
35 | ///
36 | /// Generates the identity.
37 | ///
38 | /// The generated identity instance.
39 | object Generate();
40 | }
41 | }
42 |
--------------------------------------------------------------------------------
/src/Apworks/Generators/ISequenceGenerator.cs:
--------------------------------------------------------------------------------
1 | // ==================================================================================================================
2 | // ,::i BBB
3 | // BBBBBi EBBB
4 | // MBBNBBU BBB,
5 | // BBB. BBB BBB,BBBBM BBB UBBB MBB, LBBBBBO, :BBG,BBB :BBB .BBBU kBBBBBF
6 | // BBB, BBB 7BBBBS2BBBO BBB iBBBB YBBJ :BBBMYNBBB: FBBBBBB: OBB: 5BBB, BBBi ,M,
7 | // MBBY BBB. 8BBB :BBB BBB .BBUBB BB1 BBBi kBBB BBBM BBBjBBBr BBB1
8 | // BBBBBBBBBBBu BBB FBBP MBM BB. BB BBM 7BBB MBBY .BBB 7BBGkBB1 JBBBBi
9 | // PBBBFE0GkBBBB 7BBX uBBB MBBMBu .BBOBB rBBB kBBB ZBBq BBB: BBBJ . iBBB
10 | //BBBB iBBB BBBBBBBBBE EBBBB ,BBBB MBBBBBBBM BBB, iBBB .BBB2 :BBBBBBB7
11 | //vr7 777 BBBu8O5: .77r Lr7 .7EZk; L77 .Y7r irLY JNMMF:
12 | // LBBj
13 | //
14 | // Apworks Application Development Framework
15 | // Copyright (C) 2010-2015 by daxnet.
16 | // Licensed under the Apache License, Version 2.0 (the "License");
17 | // you may not use this file except in compliance with the License.
18 | // You may obtain a copy of the License at
19 | // http://www.apache.org/licenses/LICENSE-2.0
20 | // Unless required by applicable law or agreed to in writing, software
21 | // distributed under the License is distributed on an "AS IS" BASIS,
22 | // WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
23 | // See the License for the specific language governing permissions and
24 | // limitations under the License.
25 | // ==================================================================================================================
26 |
27 | namespace Apworks.Generators
28 | {
29 | ///
30 | /// Represents that the implemented classes are sequence generators.
31 | ///
32 | public interface ISequenceGenerator
33 | {
34 | ///
35 | /// Gets the next value of the sequence.
36 | ///
37 | object Next { get; }
38 | }
39 | }
40 |
--------------------------------------------------------------------------------
/src/Apworks/IAggregateRoot.cs:
--------------------------------------------------------------------------------
1 | // ==================================================================================================================
2 | // ,::i BBB
3 | // BBBBBi EBBB
4 | // MBBNBBU BBB,
5 | // BBB. BBB BBB,BBBBM BBB UBBB MBB, LBBBBBO, :BBG,BBB :BBB .BBBU kBBBBBF
6 | // BBB, BBB 7BBBBS2BBBO BBB iBBBB YBBJ :BBBMYNBBB: FBBBBBB: OBB: 5BBB, BBBi ,M,
7 | // MBBY BBB. 8BBB :BBB BBB .BBUBB BB1 BBBi kBBB BBBM BBBjBBBr BBB1
8 | // BBBBBBBBBBBu BBB FBBP MBM BB. BB BBM 7BBB MBBY .BBB 7BBGkBB1 JBBBBi
9 | // PBBBFE0GkBBBB 7BBX uBBB MBBMBu .BBOBB rBBB kBBB ZBBq BBB: BBBJ . iBBB
10 | //BBBB iBBB BBBBBBBBBE EBBBB ,BBBB MBBBBBBBM BBB, iBBB .BBB2 :BBBBBBB7
11 | //vr7 777 BBBu8O5: .77r Lr7 .7EZk; L77 .Y7r irLY JNMMF:
12 | // LBBj
13 | //
14 | // Apworks Application Development Framework
15 | // Copyright (C) 2010-2015 by daxnet.
16 | // Licensed under the Apache License, Version 2.0 (the "License");
17 | // you may not use this file except in compliance with the License.
18 | // You may obtain a copy of the License at
19 | // http://www.apache.org/licenses/LICENSE-2.0
20 | // Unless required by applicable law or agreed to in writing, software
21 | // distributed under the License is distributed on an "AS IS" BASIS,
22 | // WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
23 | // See the License for the specific language governing permissions and
24 | // limitations under the License.
25 | // ==================================================================================================================
26 |
27 |
28 | namespace Apworks
29 | {
30 | using System;
31 |
32 | ///
33 | /// Represents that the implemented classes are aggregate roots.
34 | ///
35 | /// The type of the key of the aggregate root.
36 | public interface IAggregateRoot : IEntity
37 | {
38 |
39 | }
40 |
41 | ///
42 | /// Represents that the implemented classes are aggregate roots.
43 | ///
44 | public interface IAggregateRoot : IAggregateRoot, IEntity
45 | {
46 |
47 | }
48 | }
49 |
--------------------------------------------------------------------------------
/src/Apworks/IHandler.cs:
--------------------------------------------------------------------------------
1 | // ==================================================================================================================
2 | // ,::i BBB
3 | // BBBBBi EBBB
4 | // MBBNBBU BBB,
5 | // BBB. BBB BBB,BBBBM BBB UBBB MBB, LBBBBBO, :BBG,BBB :BBB .BBBU kBBBBBF
6 | // BBB, BBB 7BBBBS2BBBO BBB iBBBB YBBJ :BBBMYNBBB: FBBBBBB: OBB: 5BBB, BBBi ,M,
7 | // MBBY BBB. 8BBB :BBB BBB .BBUBB BB1 BBBi kBBB BBBM BBBjBBBr BBB1
8 | // BBBBBBBBBBBu BBB FBBP MBM BB. BB BBM 7BBB MBBY .BBB 7BBGkBB1 JBBBBi
9 | // PBBBFE0GkBBBB 7BBX uBBB MBBMBu .BBOBB rBBB kBBB ZBBq BBB: BBBJ . iBBB
10 | //BBBB iBBB BBBBBBBBBE EBBBB ,BBBB MBBBBBBBM BBB, iBBB .BBB2 :BBBBBBB7
11 | //vr7 777 BBBu8O5: .77r Lr7 .7EZk; L77 .Y7r irLY JNMMF:
12 | // LBBj
13 | //
14 | // Apworks Application Development Framework
15 | // Copyright (C) 2010-2015 by daxnet.
16 | // Licensed under the Apache License, Version 2.0 (the "License");
17 | // you may not use this file except in compliance with the License.
18 | // You may obtain a copy of the License at
19 | // http://www.apache.org/licenses/LICENSE-2.0
20 | // Unless required by applicable law or agreed to in writing, software
21 | // distributed under the License is distributed on an "AS IS" BASIS,
22 | // WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
23 | // See the License for the specific language governing permissions and
24 | // limitations under the License.
25 | // ==================================================================================================================
26 |
27 |
28 | namespace Apworks
29 | {
30 | ///
31 | /// Represents that the implemented classes are message handlers.
32 | ///
33 | /// The type of the message to be handled.
34 | public interface IHandler
35 | {
36 | ///
37 | /// Handles the specified message.
38 | ///
39 | /// The message to be handled.
40 | void Handle(T message);
41 | }
42 | }
43 |
--------------------------------------------------------------------------------
/src/Apworks/IServiceRegister.cs:
--------------------------------------------------------------------------------
1 | using System;
2 | using System.Collections.Generic;
3 | using System.Linq;
4 | using System.Text;
5 |
6 | namespace Apworks
7 | {
8 | //public enum LifetimeStyle
9 | //{
10 | // Transient,
11 | // Singleton,
12 | // PerWebRequest,
13 | // PerWcfRequest,
14 | // PerWcfSession
15 | //}
16 | ///
17 | /// Represents the service register (not finished yet).
18 | ///
19 | public interface IServiceRegister
20 | {
21 | #region Commented
22 |
23 | //IServiceRegister RegisterServiceType();
24 | //IServiceRegister RegisterServiceType(string name);
25 | //IServiceRegister RegisterServiceType(LifetimeStyle lifetimeStyle);
26 | //IServiceRegister RegisterServiceType(string name, LifetimeStyle lifetimeStyle);
27 | //IServiceRegister RegisterServiceType(Type from, Type to);
28 | //IServiceRegister RegisterServiceType(Type from, Type to, string name);
29 | //IServiceRegister RegisterServiceType(Type from, Type to, LifetimeStyle lifetimeStyle);
30 | //IServiceRegister RegisterServiceType(Type from, Type to, string name, LifetimeStyle lifetimeStyle);
31 | #endregion
32 | }
33 | }
34 |
--------------------------------------------------------------------------------
/src/Apworks/InfrastructureException.cs:
--------------------------------------------------------------------------------
1 | using System;
2 | using System.Runtime.InteropServices;
3 |
4 | namespace Apworks
5 | {
6 | ///
7 | /// Represents errors that occur in the infrastructure layer of Apworks framework.
8 | ///
9 | [Serializable]
10 | [ComVisible(true)]
11 | [ClassInterface(ClassInterfaceType.None)]
12 | [ComDefaultInterface(typeof(_Exception))]
13 | public class InfrastructureException : ApworksException
14 | {
15 | #region Ctor
16 | ///
17 | /// Initializes a new instance of the InfrastructureException class.
18 | ///
19 | public InfrastructureException() : base() { }
20 | ///
21 | /// Initializes a new instance of the InfrastructureException class with the specified
22 | /// error message.
23 | ///
24 | /// The message that describes the error.
25 | public InfrastructureException(string message) : base(message) { }
26 | ///
27 | /// Initializes a new instance of the InfrastructureException class with the specified
28 | /// error message and the inner exception that is the cause of this exception.
29 | ///
30 | /// The message that describes the error.
31 | /// The inner exception that is the cause of this exception.
32 | public InfrastructureException(string message, Exception innerException) : base(message, innerException) { }
33 | ///
34 | /// Initializes a new instance of the InfrastructureException class with the specified
35 | /// string formatter and the arguments that are used for formatting the message which
36 | /// describes the error.
37 | ///
38 | /// The string formatter which is used for formatting the error message.
39 | /// The arguments that are used by the formatter to build the error message.
40 | public InfrastructureException(string format, params object[] args) : base(string.Format(format, args)) { }
41 | #endregion
42 | }
43 | }
44 |
--------------------------------------------------------------------------------
/src/Apworks/Properties/AssemblyInfo.cs:
--------------------------------------------------------------------------------
1 | using System;
2 | using System.Reflection;
3 | using System.Runtime.InteropServices;
4 |
5 | // General Information about an assembly is controlled through the following
6 | // set of attributes. Change these attribute values to modify the information
7 | // associated with an assembly.
8 | [assembly: AssemblyTitle("Apworks")]
9 | [assembly: AssemblyDescription("Apworks Application Development Framework")]
10 | [assembly: AssemblyConfiguration("")]
11 | [assembly: AssemblyCompany("daxnet")]
12 | [assembly: AssemblyProduct("Apworks Application Development Framework")]
13 | [assembly: AssemblyCopyright("Copyright © 2009-2015, by daxnet.")]
14 | [assembly: AssemblyTrademark("")]
15 | [assembly: AssemblyCulture("")]
16 |
17 | // Setting ComVisible to false makes the types in this assembly not visible
18 | // to COM components. If you need to access a type in this assembly from
19 | // COM, set the ComVisible attribute to true on that type.
20 | [assembly: ComVisible(true)]
21 | // Makes the Apworks framework base library CLS compliant.
22 | [assembly: CLSCompliant(true)]
23 |
24 | // The following GUID is for the ID of the typelib if this project is exposed to COM
25 | [assembly: Guid("4851f079-8d60-4d0a-9293-e911047c9c57")]
26 |
27 | // Version information for an assembly consists of the following four values:
28 | //
29 | // Major Version
30 | // Minor Version
31 | // Build Number
32 | // Revision
33 | //
34 | // You can specify all the values or you can default the Build and Revision Numbers
35 | // by using the '*' as shown below:
36 | // [assembly: AssemblyVersion("1.0.*")]
37 | [assembly: AssemblyVersion("2.5.5164.37969")]
38 |
39 |
--------------------------------------------------------------------------------
/src/Apworks/Queries/IQueryObject.cs:
--------------------------------------------------------------------------------
1 | // ==================================================================================================================
2 | // ,::i BBB
3 | // BBBBBi EBBB
4 | // MBBNBBU BBB,
5 | // BBB. BBB BBB,BBBBM BBB UBBB MBB, LBBBBBO, :BBG,BBB :BBB .BBBU kBBBBBF
6 | // BBB, BBB 7BBBBS2BBBO BBB iBBBB YBBJ :BBBMYNBBB: FBBBBBB: OBB: 5BBB, BBBi ,M,
7 | // MBBY BBB. 8BBB :BBB BBB .BBUBB BB1 BBBi kBBB BBBM BBBjBBBr BBB1
8 | // BBBBBBBBBBBu BBB FBBP MBM BB. BB BBM 7BBB MBBY .BBB 7BBGkBB1 JBBBBi
9 | // PBBBFE0GkBBBB 7BBX uBBB MBBMBu .BBOBB rBBB kBBB ZBBq BBB: BBBJ . iBBB
10 | //BBBB iBBB BBBBBBBBBE EBBBB ,BBBB MBBBBBBBM BBB, iBBB .BBB2 :BBBBBBB7
11 | //vr7 777 BBBu8O5: .77r Lr7 .7EZk; L77 .Y7r irLY JNMMF:
12 | // LBBj
13 | //
14 | // Apworks Application Development Framework
15 | // Copyright (C) 2010-2011 apworks.codeplex.com.
16 | // Licensed under the Apache License, Version 2.0 (the "License");
17 | // you may not use this file except in compliance with the License.
18 | // You may obtain a copy of the License at
19 | // http://www.apache.org/licenses/LICENSE-2.0
20 | // Unless required by applicable law or agreed to in writing, software
21 | // distributed under the License is distributed on an "AS IS" BASIS,
22 | // WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
23 | // See the License for the specific language governing permissions and
24 | // limitations under the License.
25 | // ==================================================================================================================
26 | using System;
27 |
28 | namespace Apworks.Queries
29 | {
30 | ///
31 | /// Represents that the implemented classes are query objects. For more information about
32 | /// the Query Object architectural pattern, please refer to http://martinfowler.com/eaaCatalog/queryObject.html.
33 | ///
34 | [Obsolete(@"This interface is obsolete, query facilities will be provided in other products,
35 | or users should use their own mechanism to handle query object storages.")]
36 | public interface IQueryObject
37 | {
38 |
39 | }
40 | }
41 |
--------------------------------------------------------------------------------
/src/Apworks/Queries/Storage/IQueryObjectStorage.cs:
--------------------------------------------------------------------------------
1 | // ==================================================================================================================
2 | // ,::i BBB
3 | // BBBBBi EBBB
4 | // MBBNBBU BBB,
5 | // BBB. BBB BBB,BBBBM BBB UBBB MBB, LBBBBBO, :BBG,BBB :BBB .BBBU kBBBBBF
6 | // BBB, BBB 7BBBBS2BBBO BBB iBBBB YBBJ :BBBMYNBBB: FBBBBBB: OBB: 5BBB, BBBi ,M,
7 | // MBBY BBB. 8BBB :BBB BBB .BBUBB BB1 BBBi kBBB BBBM BBBjBBBr BBB1
8 | // BBBBBBBBBBBu BBB FBBP MBM BB. BB BBM 7BBB MBBY .BBB 7BBGkBB1 JBBBBi
9 | // PBBBFE0GkBBBB 7BBX uBBB MBBMBu .BBOBB rBBB kBBB ZBBq BBB: BBBJ . iBBB
10 | //BBBB iBBB BBBBBBBBBE EBBBB ,BBBB MBBBBBBBM BBB, iBBB .BBB2 :BBBBBBB7
11 | //vr7 777 BBBu8O5: .77r Lr7 .7EZk; L77 .Y7r irLY JNMMF:
12 | // LBBj
13 | //
14 | // Apworks Application Development Framework
15 | // Copyright (C) 2010-2011 apworks.codeplex.com.
16 | // Licensed under the Apache License, Version 2.0 (the "License");
17 | // you may not use this file except in compliance with the License.
18 | // You may obtain a copy of the License at
19 | // http://www.apache.org/licenses/LICENSE-2.0
20 | // Unless required by applicable law or agreed to in writing, software
21 | // distributed under the License is distributed on an "AS IS" BASIS,
22 | // WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
23 | // See the License for the specific language governing permissions and
24 | // limitations under the License.
25 | // ==================================================================================================================
26 |
27 | using System;
28 | using Apworks.Storage;
29 |
30 | namespace Apworks.Queries.Storage
31 | {
32 | ///
33 | /// Represents that the implemented classes are query object storages.
34 | ///
35 | [Obsolete(@"This interface is obsolete, query facilities will be provided in other products,
36 | or users should use their own mechanism to handle query object storages.")]
37 | public interface IQueryObjectStorage : IStorage
38 | {
39 |
40 | }
41 | }
42 |
--------------------------------------------------------------------------------
/src/Apworks/Snapshots/Serialization/ISnapshotSerializer.cs:
--------------------------------------------------------------------------------
1 | // ==================================================================================================================
2 | // ,::i BBB
3 | // BBBBBi EBBB
4 | // MBBNBBU BBB,
5 | // BBB. BBB BBB,BBBBM BBB UBBB MBB, LBBBBBO, :BBG,BBB :BBB .BBBU kBBBBBF
6 | // BBB, BBB 7BBBBS2BBBO BBB iBBBB YBBJ :BBBMYNBBB: FBBBBBB: OBB: 5BBB, BBBi ,M,
7 | // MBBY BBB. 8BBB :BBB BBB .BBUBB BB1 BBBi kBBB BBBM BBBjBBBr BBB1
8 | // BBBBBBBBBBBu BBB FBBP MBM BB. BB BBM 7BBB MBBY .BBB 7BBGkBB1 JBBBBi
9 | // PBBBFE0GkBBBB 7BBX uBBB MBBMBu .BBOBB rBBB kBBB ZBBq BBB: BBBJ . iBBB
10 | //BBBB iBBB BBBBBBBBBE EBBBB ,BBBB MBBBBBBBM BBB, iBBB .BBB2 :BBBBBBB7
11 | //vr7 777 BBBu8O5: .77r Lr7 .7EZk; L77 .Y7r irLY JNMMF:
12 | // LBBj
13 | //
14 | // Apworks Application Development Framework
15 | // Copyright (C) 2010-2015 by daxnet.
16 | // Licensed under the Apache License, Version 2.0 (the "License");
17 | // you may not use this file except in compliance with the License.
18 | // You may obtain a copy of the License at
19 | // http://www.apache.org/licenses/LICENSE-2.0
20 | // Unless required by applicable law or agreed to in writing, software
21 | // distributed under the License is distributed on an "AS IS" BASIS,
22 | // WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
23 | // See the License for the specific language governing permissions and
24 | // limitations under the License.
25 | // ==================================================================================================================
26 |
27 | using Apworks.Serialization;
28 |
29 | namespace Apworks.Snapshots.Serialization
30 | {
31 | ///
32 | /// Represents that the implemented classes are serializers for snapshots.
33 | ///
34 | public interface ISnapshotSerializer : IObjectSerializer
35 | {
36 | }
37 | }
38 |
--------------------------------------------------------------------------------
/src/Apworks/Snapshots/Serialization/SnapshotBinarySerializer.cs:
--------------------------------------------------------------------------------
1 | // ==================================================================================================================
2 | // ,::i BBB
3 | // BBBBBi EBBB
4 | // MBBNBBU BBB,
5 | // BBB. BBB BBB,BBBBM BBB UBBB MBB, LBBBBBO, :BBG,BBB :BBB .BBBU kBBBBBF
6 | // BBB, BBB 7BBBBS2BBBO BBB iBBBB YBBJ :BBBMYNBBB: FBBBBBB: OBB: 5BBB, BBBi ,M,
7 | // MBBY BBB. 8BBB :BBB BBB .BBUBB BB1 BBBi kBBB BBBM BBBjBBBr BBB1
8 | // BBBBBBBBBBBu BBB FBBP MBM BB. BB BBM 7BBB MBBY .BBB 7BBGkBB1 JBBBBi
9 | // PBBBFE0GkBBBB 7BBX uBBB MBBMBu .BBOBB rBBB kBBB ZBBq BBB: BBBJ . iBBB
10 | //BBBB iBBB BBBBBBBBBE EBBBB ,BBBB MBBBBBBBM BBB, iBBB .BBB2 :BBBBBBB7
11 | //vr7 777 BBBu8O5: .77r Lr7 .7EZk; L77 .Y7r irLY JNMMF:
12 | // LBBj
13 | //
14 | // Apworks Application Development Framework
15 | // Copyright (C) 2010-2015 by daxnet.
16 | // Licensed under the Apache License, Version 2.0 (the "License");
17 | // you may not use this file except in compliance with the License.
18 | // You may obtain a copy of the License at
19 | // http://www.apache.org/licenses/LICENSE-2.0
20 | // Unless required by applicable law or agreed to in writing, software
21 | // distributed under the License is distributed on an "AS IS" BASIS,
22 | // WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
23 | // See the License for the specific language governing permissions and
24 | // limitations under the License.
25 | // ==================================================================================================================
26 |
27 | using Apworks.Serialization;
28 |
29 | namespace Apworks.Snapshots.Serialization
30 | {
31 | ///
32 | /// Represents the binary snapshot serializer.
33 | ///
34 | public class SnapshotBinarySerializer : ObjectBinarySerializer, ISnapshotSerializer
35 | {
36 | }
37 | }
38 |
--------------------------------------------------------------------------------
/src/Apworks/Snapshots/Serialization/SnapshotDataContractSerializer.cs:
--------------------------------------------------------------------------------
1 | // ==================================================================================================================
2 | // ,::i BBB
3 | // BBBBBi EBBB
4 | // MBBNBBU BBB,
5 | // BBB. BBB BBB,BBBBM BBB UBBB MBB, LBBBBBO, :BBG,BBB :BBB .BBBU kBBBBBF
6 | // BBB, BBB 7BBBBS2BBBO BBB iBBBB YBBJ :BBBMYNBBB: FBBBBBB: OBB: 5BBB, BBBi ,M,
7 | // MBBY BBB. 8BBB :BBB BBB .BBUBB BB1 BBBi kBBB BBBM BBBjBBBr BBB1
8 | // BBBBBBBBBBBu BBB FBBP MBM BB. BB BBM 7BBB MBBY .BBB 7BBGkBB1 JBBBBi
9 | // PBBBFE0GkBBBB 7BBX uBBB MBBMBu .BBOBB rBBB kBBB ZBBq BBB: BBBJ . iBBB
10 | //BBBB iBBB BBBBBBBBBE EBBBB ,BBBB MBBBBBBBM BBB, iBBB .BBB2 :BBBBBBB7
11 | //vr7 777 BBBu8O5: .77r Lr7 .7EZk; L77 .Y7r irLY JNMMF:
12 | // LBBj
13 | //
14 | // Apworks Application Development Framework
15 | // Copyright (C) 2010-2015 by daxnet.
16 | // Licensed under the Apache License, Version 2.0 (the "License");
17 | // you may not use this file except in compliance with the License.
18 | // You may obtain a copy of the License at
19 | // http://www.apache.org/licenses/LICENSE-2.0
20 | // Unless required by applicable law or agreed to in writing, software
21 | // distributed under the License is distributed on an "AS IS" BASIS,
22 | // WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
23 | // See the License for the specific language governing permissions and
24 | // limitations under the License.
25 | // ==================================================================================================================
26 |
27 | using Apworks.Serialization;
28 |
29 | namespace Apworks.Snapshots.Serialization
30 | {
31 | ///
32 | /// Represents the data contract snapshot serializer.
33 | ///
34 | public class SnapshotDataContractSerializer : ObjectDataContractSerializer, ISnapshotSerializer
35 | {
36 | }
37 | }
38 |
--------------------------------------------------------------------------------
/src/Apworks/Snapshots/Serialization/SnapshotJsonSerializer.cs:
--------------------------------------------------------------------------------
1 | // ==================================================================================================================
2 | // ,::i BBB
3 | // BBBBBi EBBB
4 | // MBBNBBU BBB,
5 | // BBB. BBB BBB,BBBBM BBB UBBB MBB, LBBBBBO, :BBG,BBB :BBB .BBBU kBBBBBF
6 | // BBB, BBB 7BBBBS2BBBO BBB iBBBB YBBJ :BBBMYNBBB: FBBBBBB: OBB: 5BBB, BBBi ,M,
7 | // MBBY BBB. 8BBB :BBB BBB .BBUBB BB1 BBBi kBBB BBBM BBBjBBBr BBB1
8 | // BBBBBBBBBBBu BBB FBBP MBM BB. BB BBM 7BBB MBBY .BBB 7BBGkBB1 JBBBBi
9 | // PBBBFE0GkBBBB 7BBX uBBB MBBMBu .BBOBB rBBB kBBB ZBBq BBB: BBBJ . iBBB
10 | //BBBB iBBB BBBBBBBBBE EBBBB ,BBBB MBBBBBBBM BBB, iBBB .BBB2 :BBBBBBB7
11 | //vr7 777 BBBu8O5: .77r Lr7 .7EZk; L77 .Y7r irLY JNMMF:
12 | // LBBj
13 | //
14 | // Apworks Application Development Framework
15 | // Copyright (C) 2010-2015 by daxnet.
16 | // Licensed under the Apache License, Version 2.0 (the "License");
17 | // you may not use this file except in compliance with the License.
18 | // You may obtain a copy of the License at
19 | // http://www.apache.org/licenses/LICENSE-2.0
20 | // Unless required by applicable law or agreed to in writing, software
21 | // distributed under the License is distributed on an "AS IS" BASIS,
22 | // WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
23 | // See the License for the specific language governing permissions and
24 | // limitations under the License.
25 | // ==================================================================================================================
26 |
27 | using Apworks.Serialization;
28 |
29 | namespace Apworks.Snapshots.Serialization
30 | {
31 | ///
32 | /// Represents the Json snapshot serializer.
33 | ///
34 | public class SnapshotJsonSerializer : ObjectJsonSerializer, ISnapshotSerializer
35 | {
36 | }
37 | }
38 |
--------------------------------------------------------------------------------
/src/Apworks/Snapshots/Serialization/SnapshotXmlSerializer.cs:
--------------------------------------------------------------------------------
1 | // ==================================================================================================================
2 | // ,::i BBB
3 | // BBBBBi EBBB
4 | // MBBNBBU BBB,
5 | // BBB. BBB BBB,BBBBM BBB UBBB MBB, LBBBBBO, :BBG,BBB :BBB .BBBU kBBBBBF
6 | // BBB, BBB 7BBBBS2BBBO BBB iBBBB YBBJ :BBBMYNBBB: FBBBBBB: OBB: 5BBB, BBBi ,M,
7 | // MBBY BBB. 8BBB :BBB BBB .BBUBB BB1 BBBi kBBB BBBM BBBjBBBr BBB1
8 | // BBBBBBBBBBBu BBB FBBP MBM BB. BB BBM 7BBB MBBY .BBB 7BBGkBB1 JBBBBi
9 | // PBBBFE0GkBBBB 7BBX uBBB MBBMBu .BBOBB rBBB kBBB ZBBq BBB: BBBJ . iBBB
10 | //BBBB iBBB BBBBBBBBBE EBBBB ,BBBB MBBBBBBBM BBB, iBBB .BBB2 :BBBBBBB7
11 | //vr7 777 BBBu8O5: .77r Lr7 .7EZk; L77 .Y7r irLY JNMMF:
12 | // LBBj
13 | //
14 | // Apworks Application Development Framework
15 | // Copyright (C) 2010-2015 by daxnet.
16 | // Licensed under the Apache License, Version 2.0 (the "License");
17 | // you may not use this file except in compliance with the License.
18 | // You may obtain a copy of the License at
19 | // http://www.apache.org/licenses/LICENSE-2.0
20 | // Unless required by applicable law or agreed to in writing, software
21 | // distributed under the License is distributed on an "AS IS" BASIS,
22 | // WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
23 | // See the License for the specific language governing permissions and
24 | // limitations under the License.
25 | // ==================================================================================================================
26 |
27 | using Apworks.Serialization;
28 |
29 | namespace Apworks.Snapshots.Serialization
30 | {
31 | ///
32 | /// Represents the XML snapshot serializer.
33 | ///
34 | public class SnapshotXmlSerializer : ObjectXmlSerializer, ISnapshotSerializer
35 | {
36 | }
37 | }
38 |
--------------------------------------------------------------------------------
/src/Apworks/Specifications/ParameterRebinder.cs:
--------------------------------------------------------------------------------
1 | using System.Collections.Generic;
2 | using System.Linq.Expressions;
3 |
4 | namespace Apworks.Specifications
5 | {
6 | ///
7 | /// Represents the parameter rebinder used for rebinding the parameters
8 | /// for the given expressions. This is part of the solution which solves
9 | /// the expression parameter problem when going to Entity Framework by using
10 | /// Apworks specifications. For more information about this solution please
11 | /// refer to http://blogs.msdn.com/b/meek/archive/2008/05/02/linq-to-entities-combining-predicates.aspx.
12 | ///
13 | internal class ParameterRebinder : ExpressionVisitor
14 | {
15 | #region Private Fields
16 | private readonly Dictionary map;
17 | #endregion
18 |
19 | #region Ctor
20 | internal ParameterRebinder(Dictionary map)
21 | {
22 | this.map = map ?? new Dictionary();
23 | }
24 | #endregion
25 |
26 | #region Internal Static Methods
27 | internal static Expression ReplaceParameters(Dictionary map, Expression exp)
28 | {
29 | return new ParameterRebinder(map).Visit(exp);
30 | }
31 | #endregion
32 |
33 | #region Protected Methods
34 | protected override Expression VisitParameter(ParameterExpression p)
35 | {
36 | ParameterExpression replacement;
37 | if (map.TryGetValue(p, out replacement))
38 | {
39 | p = replacement;
40 | }
41 | return base.VisitParameter(p);
42 | }
43 | #endregion
44 | }
45 | }
46 |
--------------------------------------------------------------------------------
/src/Apworks/Storage/SortOrder.cs:
--------------------------------------------------------------------------------
1 | // ==================================================================================================================
2 | // ,::i BBB
3 | // BBBBBi EBBB
4 | // MBBNBBU BBB,
5 | // BBB. BBB BBB,BBBBM BBB UBBB MBB, LBBBBBO, :BBG,BBB :BBB .BBBU kBBBBBF
6 | // BBB, BBB 7BBBBS2BBBO BBB iBBBB YBBJ :BBBMYNBBB: FBBBBBB: OBB: 5BBB, BBBi ,M,
7 | // MBBY BBB. 8BBB :BBB BBB .BBUBB BB1 BBBi kBBB BBBM BBBjBBBr BBB1
8 | // BBBBBBBBBBBu BBB FBBP MBM BB. BB BBM 7BBB MBBY .BBB 7BBGkBB1 JBBBBi
9 | // PBBBFE0GkBBBB 7BBX uBBB MBBMBu .BBOBB rBBB kBBB ZBBq BBB: BBBJ . iBBB
10 | //BBBB iBBB BBBBBBBBBE EBBBB ,BBBB MBBBBBBBM BBB, iBBB .BBB2 :BBBBBBB7
11 | //vr7 777 BBBu8O5: .77r Lr7 .7EZk; L77 .Y7r irLY JNMMF:
12 | // LBBj
13 | //
14 | // Apworks Application Development Framework
15 | // Copyright (C) 2010-2015 by daxnet.
16 | // Licensed under the Apache License, Version 2.0 (the "License");
17 | // you may not use this file except in compliance with the License.
18 | // You may obtain a copy of the License at
19 | // http://www.apache.org/licenses/LICENSE-2.0
20 | // Unless required by applicable law or agreed to in writing, software
21 | // distributed under the License is distributed on an "AS IS" BASIS,
22 | // WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
23 | // See the License for the specific language governing permissions and
24 | // limitations under the License.
25 | // ==================================================================================================================
26 |
27 | namespace Apworks.Storage
28 | {
29 | ///
30 | /// Represents the sorting style.
31 | ///
32 | public enum SortOrder
33 | {
34 | ///
35 | /// Indicates that the sorting style is not specified.
36 | ///
37 | Unspecified = -1,
38 | ///
39 | /// Indicates an ascending sorting.
40 | ///
41 | Ascending = 0,
42 | ///
43 | /// Indicates a descending sorting.
44 | ///
45 | Descending = 1
46 | }
47 | }
48 |
--------------------------------------------------------------------------------
/src/Apworks/Storage/StorageMappingSchema.xsd:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 |
5 |
6 | Represents the schema for storage mapping.
7 |
8 |
9 |
10 |
11 |
12 |
13 |
14 |
15 |
16 |
17 |
18 |
19 |
20 |
21 |
22 |
23 |
24 |
25 |
26 |
27 |
28 |
29 |
30 |
31 |
32 |
33 |
34 |
35 |
36 |
37 |
38 |
39 |
40 |
41 |
42 |
43 |
44 |
45 |
46 |
--------------------------------------------------------------------------------
/src/Apworks/Transactions/ITransactionCoordinator.cs:
--------------------------------------------------------------------------------
1 | // ==================================================================================================================
2 | // ,::i BBB
3 | // BBBBBi EBBB
4 | // MBBNBBU BBB,
5 | // BBB. BBB BBB,BBBBM BBB UBBB MBB, LBBBBBO, :BBG,BBB :BBB .BBBU kBBBBBF
6 | // BBB, BBB 7BBBBS2BBBO BBB iBBBB YBBJ :BBBMYNBBB: FBBBBBB: OBB: 5BBB, BBBi ,M,
7 | // MBBY BBB. 8BBB :BBB BBB .BBUBB BB1 BBBi kBBB BBBM BBBjBBBr BBB1
8 | // BBBBBBBBBBBu BBB FBBP MBM BB. BB BBM 7BBB MBBY .BBB 7BBGkBB1 JBBBBi
9 | // PBBBFE0GkBBBB 7BBX uBBB MBBMBu .BBOBB rBBB kBBB ZBBq BBB: BBBJ . iBBB
10 | //BBBB iBBB BBBBBBBBBE EBBBB ,BBBB MBBBBBBBM BBB, iBBB .BBB2 :BBBBBBB7
11 | //vr7 777 BBBu8O5: .77r Lr7 .7EZk; L77 .Y7r irLY JNMMF:
12 | // LBBj
13 | //
14 | // Apworks Application Development Framework
15 | // Copyright (C) 2010-2015 by daxnet.
16 | // Licensed under the Apache License, Version 2.0 (the "License");
17 | // you may not use this file except in compliance with the License.
18 | // You may obtain a copy of the License at
19 | // http://www.apache.org/licenses/LICENSE-2.0
20 | // Unless required by applicable law or agreed to in writing, software
21 | // distributed under the License is distributed on an "AS IS" BASIS,
22 | // WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
23 | // See the License for the specific language governing permissions and
24 | // limitations under the License.
25 | // ==================================================================================================================
26 |
27 | using System;
28 |
29 | namespace Apworks.Transactions
30 | {
31 | ///
32 | /// Represents that the implemented classes are transaction coordinators.
33 | ///
34 | public interface ITransactionCoordinator : IUnitOfWork, IDisposable
35 | {
36 | }
37 | }
38 |
--------------------------------------------------------------------------------
/src/Apworks/key.snk:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/daxnet/Apworks/6de4b83e94c1e39b55c93590617e4491880eed39/src/Apworks/key.snk
--------------------------------------------------------------------------------
/src/Apworks/packages.config:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 |
--------------------------------------------------------------------------------