public class Insets extends Object implements Cloneable, Serializable
Insets对象是一个容器的边界表示法。它指定了一个容器在其每个边缘必须离开的空间。该空间可以是一个边界,一个空白的空间,或一个标题。
LayoutManager,
Container,
Serialized Form
| Modifier and Type | Field and Description |
|---|---|
int |
bottom
从底部插入。
|
int |
left
从左。
|
int |
right
从右侧的插图。
|
int |
top
从上面的插图。
|
| Constructor and Description |
|---|
Insets(int top, int left, int bottom, int right)
创建具有指定上,左,下初始化一个新的
Insets对象,右插图。
|
public int top
clone()
public int left
clone()
public int bottom
clone()
public int right
clone()
public Insets(int top,
int left,
int bottom,
int right)
Insets对象,右插图。
top -从顶部插入。
left -从左。
bottom -从底部插入。
right从正确的插图。
public void set(int top,
int left,
int bottom,
int right)
top -从顶部插入。
left -从左。
bottom -从底部插入。
right从正确的插图。
public boolean equals(Object obj)
top,
left,
bottom的
Insets两实例都是平等的,都是平等的,
right。
equals 方法重写,继承类
Object
obj -参考对象的比较。
true如果两个相等;否则
false。
Object.hashCode(),
HashMap
public int hashCode()
hashCode 方法重写,继承类
Object
Object.equals(java.lang.Object),
System.identityHashCode(java.lang.Object)
public String toString()
Insets。此方法仅用于调试目的,返回的字符串的内容和格式可能会在实现过程中有所不同。返回的字符串是空的但可能不
null。
Submit a bug or feature
For further API reference and developer documentation, see Java SE Documentation. That documentation contains more detailed, developer-targeted descriptions, with conceptual overviews, definitions of terms, workarounds, and working code examples.
Copyright © 1993, 2014, Oracle and/or its affiliates. All rights reserved.