Skip to content

fix(operations): interface hierarchy #335

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 1 commit into from
Jul 7, 2018
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Original file line number Diff line number Diff line change
Expand Up @@ -7,15 +7,16 @@

namespace JsonApiDotNetCore.Services.Operations.Processors
{
public interface ICreateOpProcessor<T> : IOpProcessor
public interface ICreateOpProcessor<T> : ICreateOpProcessor<T, int>
where T : class, IIdentifiable<int>
{ }

public interface ICreateOpProcessor<T, TId> : IOpProcessor
where T : class, IIdentifiable<TId>
{ }

public class CreateOpProcessor<T> : CreateOpProcessor<T, int>
public class CreateOpProcessor<T>
: CreateOpProcessor<T, int>, ICreateOpProcessor<T>
where T : class, IIdentifiable<int>
{
public CreateOpProcessor(
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,7 @@ namespace JsonApiDotNetCore.Services.Operations.Processors
/// Handles all "<see cref="OperationCode.get"/>" operations
/// </summary>
/// <typeparam name="T">The resource type</typeparam>
public interface IGetOpProcessor<T> : IOpProcessor
public interface IGetOpProcessor<T> : IGetOpProcessor<T, int>
where T : class, IIdentifiable<int>
{ }

Expand All @@ -27,7 +27,7 @@ public interface IGetOpProcessor<T, TId> : IOpProcessor
{ }

/// <inheritdoc />
public class GetOpProcessor<T> : GetOpProcessor<T, int>
public class GetOpProcessor<T> : GetOpProcessor<T, int>, IGetOpProcessor<T>
where T : class, IIdentifiable<int>
{
/// <inheritdoc />
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -7,15 +7,15 @@

namespace JsonApiDotNetCore.Services.Operations.Processors
{
public interface IRemoveOpProcessor<T> : IOpProcessor
public interface IRemoveOpProcessor<T> : IRemoveOpProcessor<T, int>
where T : class, IIdentifiable<int>
{ }

public interface IRemoveOpProcessor<T, TId> : IOpProcessor
where T : class, IIdentifiable<TId>
{ }

public class RemoveOpProcessor<T> : RemoveOpProcessor<T, int>
public class RemoveOpProcessor<T> : RemoveOpProcessor<T, int>, IRemoveOpProcessor<T>
where T : class, IIdentifiable<int>
{
public RemoveOpProcessor(
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -7,15 +7,15 @@

namespace JsonApiDotNetCore.Services.Operations.Processors
{
public interface IUpdateOpProcessor<T> : IOpProcessor
public interface IUpdateOpProcessor<T> : IUpdateOpProcessor<T, int>
where T : class, IIdentifiable<int>
{ }

public interface IUpdateOpProcessor<T, TId> : IOpProcessor
where T : class, IIdentifiable<TId>
{ }

public class UpdateOpProcessor<T> : UpdateOpProcessor<T, int>
public class UpdateOpProcessor<T> : UpdateOpProcessor<T, int>, IUpdateOpProcessor<T>
where T : class, IIdentifiable<int>
{
public UpdateOpProcessor(
Expand Down