Skip to content

Commit

Permalink
Add PermissionPort
Browse files Browse the repository at this point in the history
  • Loading branch information
ofux committed Aug 30, 2024
1 parent 259e134 commit 1a485a0
Showing 1 changed file with 24 additions and 0 deletions.
Original file line number Diff line number Diff line change
@@ -0,0 +1,24 @@
package onlydust.com.marketplace.kernel.port.output;

import onlydust.com.marketplace.kernel.model.ProgramId;
import onlydust.com.marketplace.kernel.model.ProjectId;
import onlydust.com.marketplace.kernel.model.SponsorId;
import onlydust.com.marketplace.kernel.model.UserId;

public interface PermissionPort {
boolean isUserProjectLead(ProjectId projectId, UserId projectLeadId);

boolean isUserContributor(String contributionId, Long githubUserId);

boolean isRepoLinkedToProject(ProjectId projectId, Long githubRepoId);

boolean hasUserAccessToProject(ProjectId projectId, UserId userId);

boolean hasUserAccessToProject(String projectSlug, UserId userId);

boolean isUserSponsorLead(UserId userId, SponsorId sponsorId);

boolean isUserSponsorLeadOfProgram(UserId userId, ProgramId programId);

boolean isUserProgramLead(UserId userId, ProgramId programId);
}

0 comments on commit 1a485a0

Please sign in to comment.