private int GetDirection(TransferType type) { if (type.IsExternalBuy()) { return(1); } if (type.IsExternalSell()) { return(-1); } return(0); }