Class CfpParameters.Builder
- java.lang.Object
-
- com.chemaxon.descriptors.fingerprints.cfp.CfpParameters.Builder
-
- All Implemented Interfaces:
ParameterBuilder<CfpParameters>
- Enclosing class:
- CfpParameters
public static class CfpParameters.Builder extends Object implements ParameterBuilder<CfpParameters>
Builder class for the immutable parameter object.
-
-
Constructor Summary
Constructors Constructor Description Builder()
Constructor with default settings.Builder(CfpParameters parameters)
Constructor based on a parameter object.
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description CfpParameters.Builder
bitsPerPattern(int bitsPerPattern)
Set bits per pattern.CfpParameters.Builder
bondCount(int bondCount)
Set bond count to consider.CfpParameters
build()
Constructs an immutable instance of T.CfpParameters.Builder
length(int length)
Set fingerprint length, the bit count of the folded binary fingerprint representation.CfpParameters.Builder
rings(boolean rings)
Set rings parameter.
-
-
-
Constructor Detail
-
Builder
public Builder()
Constructor with default settings.
-
Builder
public Builder(CfpParameters parameters)
Constructor based on a parameter object.- Parameters:
parameters
- Parameter object
-
-
Method Detail
-
bondCount
public CfpParameters.Builder bondCount(int bondCount)
Set bond count to consider.The maximum length of consecutive bonds in the linear paths that are considered during the fragmentation of the molecule.
- Parameters:
bondCount
- Bond count parameter to set. Use zero to consider no bonds, just atoms- Returns:
- Reference to this builder
- Throws:
IllegalArgumentException
- when the set diameter is a negative number
-
length
public CfpParameters.Builder length(int length)
Set fingerprint length, the bit count of the folded binary fingerprint representation.- Parameters:
length
- new length- Returns:
- Reference to this builder
- Throws:
IllegalArgumentException
- when the set length is not a positive number, or not multiply of 32
-
bitsPerPattern
public CfpParameters.Builder bitsPerPattern(int bitsPerPattern)
Set bits per pattern.The number of bits used to code each pattern in the hashed binary vector representation.
- Parameters:
bitsPerPattern
- Bits per pattern parameter- Returns:
- Reference to this builder
- Throws:
IllegalArgumentException
- when parameter's value is less than one
-
rings
public CfpParameters.Builder rings(boolean rings)
Set rings parameter.When
true
fingerprint bits are calculated for individual rings up to a certain size limit.- Parameters:
rings
- Rings parameter- Returns:
- Reference to this builder
-
build
public CfpParameters build()
Description copied from interface:ParameterBuilder
Constructs an immutable instance of T.- Specified by:
build
in interfaceParameterBuilder<CfpParameters>
- Returns:
- An immutable instance of T
-
-