我想用指针列表做类似的事情
有没有人有例子?
List<Map> listOfMaps = [{"name":"Map1"},{"name":"Map2"}];
List<Point> listofPointers = [........];
谢谢
答案 0 :(得分:1)
我想你想要像
这样的东西List<Point> points = [
new Point(10,10),
new Point(20,20) ];
答案 1 :(得分:0)
List<Point> MatrixofPointer = new List<Point>(8);
MatrixofPointer[0] = new Point(-1,-1);
MatrixofPointer[1] = new Point( 0,-1);
MatrixofPointer[2] = new Point( 1,-1);
MatrixofPointer[3] = new Point(-1, 0);
MatrixofPointer[4] = new Point( 1, 0);
MatrixofPointer[5] = new Point(-1, 1);
MatrixofPointer[6] = new Point( 1, 0);
MatrixofPointer[7] = new Point( 1, 1);
但短版本会很好