C# 클래스 EricVoglBattleship.Score1D

Keeps track of the number of ship position possibilities in one dimension
파일 보기 프로젝트 열기: solium/hacklympics

공개 메소드들

메소드 설명
Apply ( List ships, int index, int length ) : void

Applies possibilities in 1D

Clear ( ) : void

Sets the score to zero

Initialize ( List ships, int index, int length ) : void

Initializes possibilities in 1D

Recalculate ( ) : void

Forces a recalculation of the total score

Score1D ( ) : System.Collections.Generic

Creates a new Score1D object

Sink ( int size ) : void

Update possible positions knowning ship sank

메소드 상세

Apply() 공개 메소드

Applies possibilities in 1D
public Apply ( List ships, int index, int length ) : void
ships List Ships alive
index int index in length
length int length
리턴 void

Clear() 공개 메소드

Sets the score to zero
public Clear ( ) : void
리턴 void

Initialize() 공개 메소드

Initializes possibilities in 1D
public Initialize ( List ships, int index, int length ) : void
ships List Ships alive
index int index in length
length int length
리턴 void

Recalculate() 공개 메소드

Forces a recalculation of the total score
public Recalculate ( ) : void
리턴 void

Score1D() 공개 메소드

Creates a new Score1D object
public Score1D ( ) : System.Collections.Generic
리턴 System.Collections.Generic

Sink() 공개 메소드

Update possible positions knowning ship sank
public Sink ( int size ) : void
size int Size of ship that sank
리턴 void