- final double per_sequence_evalue,
- final double per_sequence_score ) {
- this( id, from, to, number, total_count, per_sequence_evalue, per_sequence_score, 0, 0 );
+ final double per_domain_evalue,
+ final double per_domain_score ) {
+ if ( ( from >= to ) || ( from < 0 ) ) {
+ throw new IllegalArgumentException( "attempt to create protein domain from " + from + " to " + to );
+ }
+ if ( ForesterUtil.isEmpty( id ) ) {
+ throw new IllegalArgumentException( "attempt to create protein domain with null or empty id" );
+ }
+ if ( ( number > total_count ) || ( number < 0 ) ) {
+ throw new IllegalArgumentException( "attempt to create protein domain number " + number + " out of "
+ + total_count );
+ }
+ if ( per_domain_evalue < 0.0 ) {
+ throw new IllegalArgumentException( "attempt to create protein domain with negative E-value" );
+ }
+ _id = obtainIdAsShort( id );
+ _from = from;
+ _to = to;
+ _number = number;
+ _total_count = total_count;
+ _per_domain_evalue = per_domain_evalue;
+ _per_domain_score = per_domain_score;
+ _hmm_len = -1;
+ _hmm_from= -1;
+ _hmm_to= -1;