code: double _norm(int metric) {
  		if (metric < 0 || _isNan())
  			return NumberUtils.NaN();
  
  		switch (metric) {
  		case 0: // L-infinite
  			return Math.abs(x) >= Math.abs(y) ? Math.abs(x) : Math.abs(y);
  
  		case 1: // L1 or Manhattan metric
  			return Math.abs(x) + Math.abs(y);
  
  		case 2: // L2 or Euclidean metric
  			return Math.sqrt(x * x + y * y);
  
  		default:
  			return Math
  					.pow(Math.pow(x, (double) metric)
  							+ Math.pow(y, (double) metric),
  							1.0 / (double) metric);
  		}
  	}
docs: for predefined metrics, use the DistanceMetricEnum defined in WKSPoint.h