本文整理汇总了Java中org.bouncycastle.util.Arrays.areEqual方法的典型用法代码示例。如果您正苦于以下问题:Java Arrays.areEqual方法的具体用法?Java Arrays.areEqual怎么用?Java Arrays.areEqual使用的例子?那么, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在类org.bouncycastle.util.Arrays
的用法示例。
在下文中一共展示了Arrays.areEqual方法的15个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的Java代码示例。
示例1: equals
import org.bouncycastle.util.Arrays; //导入方法依赖的package包/类
public boolean equals(
Object o)
{
if (!(o instanceof DHValidationParameters))
{
return false;
}
DHValidationParameters other = (DHValidationParameters)o;
if (other.counter != this.counter)
{
return false;
}
return Arrays.areEqual(this.seed, other.seed);
}
示例2: equals
import org.bouncycastle.util.Arrays; //导入方法依赖的package包/类
public boolean equals(
Object o)
{
if (!(o instanceof DSAValidationParameters))
{
return false;
}
DSAValidationParameters other = (DSAValidationParameters)o;
if (other.counter != this.counter)
{
return false;
}
return Arrays.areEqual(this.seed, other.seed);
}
示例3: equals
import org.bouncycastle.util.Arrays; //导入方法依赖的package包/类
public boolean equals(
Object o)
{
if (o == this)
{
return true;
}
if (!(o instanceof CertId))
{
return false;
}
CertId cId = (CertId)o;
return Arrays.areEqual(id, cId.id);
}
示例4: isIPConstrained
import org.bouncycastle.util.Arrays; //导入方法依赖的package包/类
/**
* Checks if the IP address <code>ip</code> is constrained by
* <code>constraint</code>.
*
* @param ip The IP address.
* @param constraint The constraint. This is an IP address concatenated with
* its subnetmask.
* @return <code>true</code> if constrained, <code>false</code>
* otherwise.
*/
private boolean isIPConstrained(byte ip[], byte[] constraint)
{
int ipLength = ip.length;
if (ipLength != (constraint.length / 2))
{
return false;
}
byte[] subnetMask = new byte[ipLength];
System.arraycopy(constraint, ipLength, subnetMask, 0, ipLength);
byte[] permittedSubnetAddress = new byte[ipLength];
byte[] ipSubnetAddress = new byte[ipLength];
// the resulting IP address by applying the subnet mask
for (int i = 0; i < ipLength; i++)
{
permittedSubnetAddress[i] = (byte)(constraint[i] & subnetMask[i]);
ipSubnetAddress[i] = (byte)(ip[i] & subnetMask[i]);
}
return Arrays.areEqual(permittedSubnetAddress, ipSubnetAddress);
}
示例5: asn1Equals
import org.bouncycastle.util.Arrays; //导入方法依赖的package包/类
boolean asn1Equals(
ASN1Primitive o)
{
if (!(o instanceof ASN1OctetString))
{
return false;
}
ASN1OctetString other = (ASN1OctetString)o;
return Arrays.areEqual(string, other.string);
}
示例6: asn1Equals
import org.bouncycastle.util.Arrays; //导入方法依赖的package包/类
protected boolean asn1Equals(
DERObject o)
{
if (!(o instanceof DERBitString))
{
return false;
}
DERBitString other = (DERBitString)o;
return this.padBits == other.padBits
&& Arrays.areEqual(this.data, other.data);
}
示例7: asn1Equals
import org.bouncycastle.util.Arrays; //导入方法依赖的package包/类
boolean asn1Equals(
DERObject o)
{
if (!(o instanceof DERInteger))
{
return false;
}
DERInteger other = (DERInteger)o;
return Arrays.areEqual(bytes, other.bytes);
}
示例8: asn1Equals
import org.bouncycastle.util.Arrays; //导入方法依赖的package包/类
boolean asn1Equals(
ASN1Primitive o)
{
if (!(o instanceof DERNumericString))
{
return false;
}
DERNumericString s = (DERNumericString)o;
return Arrays.areEqual(string, s.string);
}
示例9: asn1Equals
import org.bouncycastle.util.Arrays; //导入方法依赖的package包/类
boolean asn1Equals(
ASN1Primitive o)
{
if (!(o instanceof DERPrintableString))
{
return false;
}
DERPrintableString s = (DERPrintableString)o;
return Arrays.areEqual(string, s.string);
}
示例10: equals
import org.bouncycastle.util.Arrays; //导入方法依赖的package包/类
public boolean equals(Object obj)
{
if (this == obj)
{
return true;
}
if (obj == null)
{
return false;
}
if (getClass() != obj.getClass())
{
return false;
}
SparseTernaryPolynomial other = (SparseTernaryPolynomial)obj;
if (N != other.N)
{
return false;
}
if (!Arrays.areEqual(negOnes, other.negOnes))
{
return false;
}
if (!Arrays.areEqual(ones, other.ones))
{
return false;
}
return true;
}
示例11: asn1Equals
import org.bouncycastle.util.Arrays; //导入方法依赖的package包/类
boolean asn1Equals(
ASN1Primitive o)
{
if (!(o instanceof DERT61UTF8String))
{
return false;
}
return Arrays.areEqual(string, ((DERT61UTF8String)o).string);
}
示例12: equals
import org.bouncycastle.util.Arrays; //导入方法依赖的package包/类
public boolean equals(Object obj)
{
if (obj instanceof LongPolynomial2)
{
return Arrays.areEqual(coeffs, ((LongPolynomial2)obj).coeffs);
}
else
{
return false;
}
}
示例13: asn1Equals
import org.bouncycastle.util.Arrays; //导入方法依赖的package包/类
boolean asn1Equals(ASN1Primitive o)
{
if (!(o instanceof DERUTF8String))
{
return false;
}
DERUTF8String s = (DERUTF8String)o;
return Arrays.areEqual(string, s.string);
}
示例14: asn1Equals
import org.bouncycastle.util.Arrays; //导入方法依赖的package包/类
boolean asn1Equals(
ASN1Primitive o)
{
if (!(o instanceof DERInteger))
{
return false;
}
DERInteger other = (DERInteger)o;
return Arrays.areEqual(bytes, other.bytes);
}
示例15: equals
import org.bouncycastle.util.Arrays; //导入方法依赖的package包/类
public boolean equals(Object obj)
{
if (obj instanceof IntegerPolynomial)
{
return Arrays.areEqual(coeffs, ((IntegerPolynomial)obj).coeffs);
}
else
{
return false;
}
}