package com.atlassian.bitbucket.internal.mirroring.mirror.user;

import com.atlassian.bitbucket.internal.mirroring.user.ApplicationUserWithPermissions;
import com.atlassian.bitbucket.internal.mirroring.user.ApplicationUserWithPermissionsVisitor;
import com.atlassian.bitbucket.user.ApplicationUser;
import com.atlassian.bitbucket.user.DetailedUser;
import com.atlassian.bitbucket.user.ServiceUser;

import javax.annotation.Nonnull;

public abstract class ApplicationUserWithPermissionsVisitorAdapter<T> implements ApplicationUserWithPermissionsVisitor<T> {
    @Override
    public T visit(@Nonnull ApplicationUserWithPermissions user) {
        return defaultValue();
    }

    @Override
    public T visit(@Nonnull DetailedUser user) {
        return defaultValue();
    }

    @Override
    public T visit(@Nonnull ServiceUser user) {
        return defaultValue();
    }

    @Override
    public T visit(@Nonnull ApplicationUser user) {
        return defaultValue();
    }

    protected abstract T defaultValue();
}
