Stack that does Push, Pop and Median in O(1)
minHeap.add(item);
        maxHeap.add(item);



Adding to a PriorityQueue is not \$O(1)\$.  It is \$O(\log{n})\$.  

Same thing for removal.  


    public int median(){
        return (minHeap.peek() + maxHeap.peek())/2;

    }



This is not a median.  The smallest and largest elements are totally irrelevant to a median.  In 4, 5, 6, then 5 is the median.  In -4000, 5, 6000, then 5 is still the median.  The only time you take an average to get a median is if there are an even number of elements in the set.  E.g. in 2, 4, 6, 8, then \$(4+6)/2 = 5\$ is the median.  Note that it is only the middle items in the set that matter.