onbon.bx06.area
Class SensorBxArea

java.lang.Object
  extended by onbon.bx06.area.BxArea
      extended by onbon.bx06.area.SensorBxArea
Direct Known Subclasses:
HumidityBxArea, NoiseBxArea, TemperatureBxArea

public abstract class SensorBxArea
extends BxArea

湿度区域。

Author:
ONBON

Nested Class Summary
static class SensorBxArea.AlarmType
           
static class SensorBxArea.PolarType
          极性类型
 
Field Summary
static byte NUMBER_NOLIMIT
           
 
Constructor Summary
SensorBxArea(int x, int y, int width, int height, Bx6GScreenProfile screenProfile)
          建构子。
SensorBxArea(onbon.bx06.message.area.SensorArea area, Bx6GScreenProfile screenProfile)
          建构子。
 
Method Summary
 void addThreshold(SensorBxArea.AlarmType alarmType, int value, Color normal, Color alarm)
          增加警報界線。
 void clearThresholds()
          清除警報界線。
 byte[] generate(ProgramDataBxFile dataFile)
          产生区域的位元组资讯。
 int getCorrection()
          取得修正值。
 SensorBxArea.PolarType getCorrectionPolar()
          取得修正极性。
protected abstract  onbon.bx06.message.file.FontData getFontData()
           
 byte getNumberFloat()
           
 byte getNumberInt()
           
protected abstract  byte getSensorMode()
           
protected abstract  byte getSensorType()
           
protected abstract  byte getSensorUnit()
           
 String getStaticText()
          取得静态文字。
 int getTransparency()
          取得透明度。
 boolean isBackgroundFlag()
           
 boolean isFractionalPart()
          取得湿度是否显示小数位。
 boolean isSensorUnitFlag()
           
 void maskByBackground()
          显示被背景遮罩的部分。
 void overlayWithBackground()
          与背景重叠显示。
 void setBackgroundFlag(boolean backgroundFlag)
           
 void setCorrection(int correction)
          设定修正值。
 void setCorrectionPolar(SensorBxArea.PolarType correctionPolar)
          设定修正极性。
 void setFractionalPart(boolean fractionalPart)
          设定湿度是否显示小数位。
 void setNumberFloat(byte numberFloat)
           
 void setNumberInt(byte numberInt)
           
 void setSensorUnitFlag(boolean sensorUnitFlag)
           
 void setStaticText(String staticText)
          设定静态文字。
 void setTransparency(int transparency)
          设定透明度。
1.
 String toString()
           
 
Methods inherited from class onbon.bx06.area.BxArea
getFont, getFrameMoveStep, getFrameSetting, getFrameSpeed, getFrameStyle, getHeight, getScreenProfile, getWidth, getX, getY, isFrameShow, loadFrameImage, loadFrameImage, preview, preview, previewScreen, setAreaFrame, setFont, setFrameMoveStep, setFrameShow, setFrameSpeed, setFrameStyle, setHeight, setWidth, setX, setY, validate
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
 

Field Detail

NUMBER_NOLIMIT

public static final byte NUMBER_NOLIMIT
See Also:
Constant Field Values
Constructor Detail

SensorBxArea

public SensorBxArea(int x,
                    int y,
                    int width,
                    int height,
                    Bx6GScreenProfile screenProfile)
建构子。

Parameters:
x - X 座标。
y - Y 座标。
width - 区域宽度。
height - 区域高度。
screenProfile - 屏幕规格。

SensorBxArea

public SensorBxArea(onbon.bx06.message.area.SensorArea area,
                    Bx6GScreenProfile screenProfile)
建构子。

Parameters:
area - 区域
screenProfile - 屏幕规格。
Method Detail

isBackgroundFlag

public boolean isBackgroundFlag()

setBackgroundFlag

public void setBackgroundFlag(boolean backgroundFlag)

getTransparency

public int getTransparency()
取得透明度。

Returns:
透明度。

setTransparency

public void setTransparency(int transparency)
设定透明度。
1. 当该值大于等于 0(不透明) 小于等于100(全透明) 时,以该背景区域为基准。

Parameters:
transparency - 透明度。

overlayWithBackground

public void overlayWithBackground()
与背景重叠显示。


maskByBackground

public void maskByBackground()
显示被背景遮罩的部分。


isSensorUnitFlag

public boolean isSensorUnitFlag()

setSensorUnitFlag

public void setSensorUnitFlag(boolean sensorUnitFlag)

isFractionalPart

public boolean isFractionalPart()
取得湿度是否显示小数位。

Returns:
是否显示小数位。

setFractionalPart

public void setFractionalPart(boolean fractionalPart)
设定湿度是否显示小数位。

Parameters:
fractionalPart - 是否显示小数位。

getNumberInt

public byte getNumberInt()

setNumberInt

public void setNumberInt(byte numberInt)

getNumberFloat

public byte getNumberFloat()

setNumberFloat

public void setNumberFloat(byte numberFloat)

getCorrectionPolar

public SensorBxArea.PolarType getCorrectionPolar()
取得修正极性。

Returns:
修正极性。

setCorrectionPolar

public void setCorrectionPolar(SensorBxArea.PolarType correctionPolar)
设定修正极性。

Parameters:
correctionPolar - 修正极性。

getCorrection

public int getCorrection()
取得修正值。

Returns:
修正值。

setCorrection

public void setCorrection(int correction)
设定修正值。

Parameters:
correction - 修正值。

getStaticText

public String getStaticText()
取得静态文字。

Returns:
静态文字。

setStaticText

public void setStaticText(String staticText)
设定静态文字。

Parameters:
staticText - 静态文字。

addThreshold

public void addThreshold(SensorBxArea.AlarmType alarmType,
                         int value,
                         Color normal,
                         Color alarm)
增加警報界線。

Parameters:
alarmType - 警報種類。
value - 值。
normal - 正常訊息顏色。
alarm - 警報訊息顏色。

clearThresholds

public void clearThresholds()
清除警報界線。


getSensorMode

protected abstract byte getSensorMode()

getSensorType

protected abstract byte getSensorType()

getSensorUnit

protected abstract byte getSensorUnit()

getFontData

protected abstract onbon.bx06.message.file.FontData getFontData()

generate

public byte[] generate(ProgramDataBxFile dataFile)
                throws Bx6GException
Description copied from class: BxArea
产生区域的位元组资讯。

Specified by:
generate in class BxArea
Parameters:
dataFile - 资料。
Returns:
区域位元组资讯。
Throws:
Bx6GException - 产生区域位元组资讯时发生错误。

toString

public String toString()
Overrides:
toString in class BxArea


Copyright © 2020 onbon. All rights reserved.