Is SList class an ADT? As per the definition given in lecture, ADT is, 



With reference to this definition, I would like to call SList class an ADT following 6 invariants:


Multiple users of SList class should be consistent in usage with same SList instance. For example multiple users may insert items in same shopping list. 
No runtime exceptions while using SList class when list is empty. 
SList size member variable is always correct.
SList is never circularly linked list. 
SList never returns SListNode, instead it return only an item.
Methods of the SlistNode class can be modified in future without any affect to SList class users. I guess this is nothing but encapsulation.


The below two classes will be part of a package and be used by classes from other packages:

class SListNode{
    Object item;
    SListNode next;
    public SListNode(){
        this.item = null;
        this.next = null;
    }
    public SListNode(Object item, SListNode next){
        this.item = item;
        this.next = next;
    }
    public SListNode(Object item){
        this(item,null);
    }
    public void insertAfter(Object item){
        this.next = new SListNode(item,this.next);
    }
    public SListNode nth(int position){
        if(position ==1){
            return this;
        }else if((position &lt; 1) || (this.next == null)){ /* error checking */
            return null;
        }else{
            SListNode tempNode = this.next.nth(position-1);
            return tempNode;
        }
    }

}




public class SList {
    private SListNode head; // First node in list.
    private int size; // Number of items in list.
    public SList() { // Here’s how to represent an empty list.
        head = null;
        size = 0;
    }
    public void insertFront(Object item) {
        head = new SListNode(item, head);
        size++;
    }
    public void insertEnd(Object item){
        SListNode lastNode = this.head;
        while(lastNode.next != null){
            lastNode = lastNode.next;
        }
        lastNode.next = new SListNode(item,lastNode.next);
        size++;
    }
    public void insertAt(Object item, int position){
        if (position == 1){
            insertFront(item);
            size++;
        }else if(position &lt; 1){
            System.exit(1);
        }else{
            SListNode currentNode = this.head.nth(position);
            if(currentNode != null){
                currentNode.insertAfter(item);
                size++;
            }else{
                System.exit(1); //position value exceeds 
            }
        }
    }
    public Object nth(int position){
        if(position &lt; 1){
            return null;
        }else{
            SListNode tempNode = this.head.nth(position);
            if(tempNode != null){
                return tempNode.item;
            }
            else{
                return null; 
            }
        }
    }

    public boolean isEmpty(){
        return (size==0);
    }
}


My question:
With reference to SList class as shown above, Can you please confirm if my interpretation of definition of ADT is correct? 
If the interpretation is wrong, What code changes would you like to see, to call SList as an ADT?

Note: I am yet to learn exception-handling, interfaces, inheritance, polymorphism and composition in class.
Bug:

public void insertEnd(Object item){
    SListNode lastNode = this.head;
    while(lastNode.next != null){
        lastNode = lastNode.next;
    }
    lastNode.next = new SListNode(item,lastNode.next);
    size++;
}


Make a new list, add to end. this.head is null, so lastNode.next is a NullPointerException.

Bug:

public void insertAt(Object item, int position){
    if (position == 1){
        insertFront(item);
        size++;
    }else if(position &lt; 1){
        System.exit(1);
    }else{
        SListNode currentNode = this.head.nth(position);
        if(currentNode != null){
            currentNode.insertAfter(item);
            size++;
        }else{
            System.exit(1); //position value exceeds 
        }
    }
}


Make new list, insertAt("hello", 1), insertAt("world", 2). The application shuts down.

Please test your code before putting it up for review. You'll get higher grades too, especially if you show your tests to your professor or whoever is teaching you.