Class Dimension for java on android

前端 未结 3 1453
别那么骄傲
别那么骄傲 2020-12-10 16:16

What is the equivalent form of class java.awt.Dimension for android?

3条回答
  •  隐瞒了意图╮
    2020-12-10 17:10

    You could use Pair which is Android's generic tuple class. (You would need to replace getWidth() and getHeight() with first and second, though.) In other places of the Android API the Android team seems to use ad-hoc classes for this purpose, for instance Camera.Size.

提交回复
热议问题