All Downloads are FREE. Search and download functionalities are using the official Maven repository.

org.snapscript.agent.event.SyntaxErrorEvent Maven / Gradle / Ivy

There is a newer version: 1.4.6
Show newest version
package org.snapscript.agent.event;

public class SyntaxErrorEvent implements ProcessEvent {

   private final String description;
   private final String resource;
   private final String process;
   private final int line;
   
   private SyntaxErrorEvent(Builder builder) {
      this.description = builder.description;
      this.process = builder.process;
      this.resource = builder.resource;
      this.line = builder.line;
   }
   
   @Override
   public String getProcess() {
      return process;
   }
   
   public String getDescription(){
      return description;
   }
      
   public String getResource() {
      return resource;
   }

   public int getLine() {
      return line;
   }
   
   public static class Builder {
      
      private String description;
      private String resource;
      private String process;
      private int line;
      
      public Builder(String process) {
         this.process = process;
      }

      public Builder withDescription(String description) {
         this.description = description;
         return this;
      }

      public Builder withResource(String resource) {
         this.resource = resource;
         return this;
      }

      public Builder withProcess(String process) {
         this.process = process;
         return this;
      }

      public Builder withLine(int line) {
         this.line = line;
         return this;
      }
      
      public SyntaxErrorEvent build(){
         return new SyntaxErrorEvent(this);
      }
      
      
   }
}




© 2015 - 2025 Weber Informatics LLC | Privacy Policy