# Class ProteinStructure

java.lang.Object
org.jmol.modelsetbio.ProteinStructure

All Implemented Interfaces:
  `Structure`

Direct Known Subclasses:
  `Annotation, Helix, Sheet`

public abstract class ProteinStructure extends Object implements Structure

## Field Summary

Fields
Modifier and Type
Field
Description
`AlphaPolymer`
`apolymer`
`protected P3`
`axisA`
`protected P3`
`axisB`
`protected V3`
`axisUnitVector`
`int`
`monomerIndexFirst`
`int`
`nRes`
`protected V3`
`vectorProjection`

## Constructor Summary

Constructors
Modifier
Constructor
Description
`protected`
`ProteinStructure()`

## Method Summary

Modifier and Type
Method
Description
`void`
`calcAxis()`
`Monomer`
`findMonomer(BS bsAtoms, boolean isFirst)`
`P3`
`getAxisEndPoint()`
`P3`
`getAxisStartPoint()`
`int`
`getIndex(Monomer monomer)`
`P3[]`
`getSegments()`
`protected void`
`incrementID()`
`boolean`
`isWithin(int monomerIndex)`
`void`
`setAtomBits(BS bs)`
`void`
`setAtomBitsAndClear(BS bs, BS bsOut)`
`protected void`
`setupPS(AlphaPolymer apolymer, STR type, int monomerIndex, int monomerCount)`
`String`
`toString()`

### Methods inherited from class Object

`clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait`

## Field Details

### nRes

public int nRes

### apolymer

public AlphaPolymer apolymer

### monomerIndexFirst

public int monomerIndexFirst

### axisA

protected P3 axisA

### axisB

protected P3 axisB

### axisUnitVector

protected V3 axisUnitVector

### vectorProjection

protected V3 vectorProjection

## Constructor Details

### ProteinStructure

protected ProteinStructure()

## Method Details

### incrementID

protected void incrementID()

### setupPS

protected void setupPS(AlphaPolymer apolymer, STR type, int monomerIndex, int monomerCount)

Parameters:
  `apolymer` -
  `type` -
  `monomerIndex` -
  `monomerCount` -

### calcAxis

public void calcAxis()

### isWithin

public boolean isWithin(int monomerIndex)

### getIndex

public int getIndex(Monomer monomer)

### getSegments

public P3[] getSegments()

Returns:
  points for rocket segment rendering

### getAxisStartPoint

public P3 getAxisStartPoint()

### getAxisEndPoint

public P3 getAxisEndPoint()

### setAtomBits

public void setAtomBits(BS bs)

Specified by:
  `setAtomBits` in interface `Structure`

### setAtomBitsAndClear

public void setAtomBitsAndClear(BS bs, BS bsOut)

Specified by:
  `setAtomBitsAndClear` in interface `Structure`

### findMonomer

public Monomer findMonomer(BS bsAtoms, boolean isFirst)

### toString

public String toString()

Overrides:
  `toString` in class `Object`