public void delete(int index,int direction)
    {
        //删除节点中的index位置的key
        int[] newKeyList = new int[size-1];
        for (int i = 0; i < size-1; i++)
        {
            if (i<index)
            {
                newKeyList[i] = keyList[i];
            }
            else if(i>index){
                newKeyList[i] = keyList[i+1];
            }
        }
        
        if (direction==1)
        {
            index++;
        }
        //删除key，对应的右子树的指针删除
        BTreeNode[] newSubNodeLis = new BTreeNode[size];
        for (int i = 0; i < size; i++)
        {
            if (i<index)
            {
                newSubNodeLis[i] = subTreeNodeList[i];
            }
            else if(i>index){
                newSubNodeLis[i] = subTreeNodeList[i+1];
            }
        }
        
        subTreeNodeList=newSubNodeLis;
        keyList=newKeyList;
    }