package com.l7tech.gateway.common.stepdebug;

import com.l7tech.gateway.common.admin.Administrative;
import com.l7tech.gateway.common.security.rbac.MethodStereotype;
import com.l7tech.gateway.common.security.rbac.Secured;
import com.l7tech.objectmodel.EntityType;
import com.l7tech.objectmodel.Goid;
import com.l7tech.util.Option;
import java.util.Collection;
import org.jetbrains.annotations.NotNull;
import org.jetbrains.annotations.Nullable;
import org.springframework.transaction.annotation.Transactional;

@Secured
@Administrative
public interface DebugAdmin {
   @Secured(types = EntityType.POLICY, stereotype = MethodStereotype.ENTITY_OPERATION, otherOperation = "debugger", relevantArg = 0)
   @NotNull
   DebugResult initializeDebug(@NotNull Goid var1);

   @Secured(stereotype = MethodStereotype.UNCHECKED_WIDE_OPEN)
   @NotNull
   Option<String> startDebug(@NotNull String var1);

   @Secured(stereotype = MethodStereotype.UNCHECKED_WIDE_OPEN)
   void stopDebug(@NotNull String var1);

   @Secured(stereotype = MethodStereotype.UNCHECKED_WIDE_OPEN)
   void stepOver(@NotNull String var1, @NotNull Collection<Integer> var2);

   @Secured(stereotype = MethodStereotype.UNCHECKED_WIDE_OPEN)
   void stepInto(@NotNull String var1);

   @Secured(stereotype = MethodStereotype.UNCHECKED_WIDE_OPEN)
   void stepOut(@NotNull String var1, @NotNull Collection<Integer> var2);

   @Secured(stereotype = MethodStereotype.UNCHECKED_WIDE_OPEN)
   void resume(@NotNull String var1);

   @Secured(stereotype = MethodStereotype.UNCHECKED_WIDE_OPEN)
   void terminateDebug(@NotNull String var1);

   @Secured(stereotype = MethodStereotype.UNCHECKED_WIDE_OPEN)
   void toggleBreakpoint(@NotNull String var1, @NotNull Collection<Integer> var2);

   @Secured(stereotype = MethodStereotype.UNCHECKED_WIDE_OPEN)
   void removeAllBreakpoints(@NotNull String var1);

   @Secured(stereotype = MethodStereotype.UNCHECKED_WIDE_OPEN)
   @Transactional(readOnly = true)
   @Nullable
   DebugResult waitForUpdates(@NotNull String var1, long var2);

   @Secured(stereotype = MethodStereotype.UNCHECKED_WIDE_OPEN)
   void addUserContextVariable(@NotNull String var1, @NotNull String var2);

   @Secured(stereotype = MethodStereotype.UNCHECKED_WIDE_OPEN)
   void removeUserContextVariable(@NotNull String var1, @NotNull String var2);
}
