📋
XDWorld_WebGL_Manual
  • 소개
    • XDWorld API
    • 시작하기
    • About EGIS
    • Release Note
      • 2.1x 버전 업데이트
      • 2.x 버전 업데이트
      • 1.6x 버전 업데이트
      • 1.5x 버전 업데이트
      • 1.4x 버전 업데이트
      • 1.3x 버전 업데이트
      • 이전 버전 업데이트
    • Tutorial
      • 카메라 설정
      • POI 생성하기
      • 폴리곤 생성하기
      • 라인 생성하기
      • 모델 추가하기
      • 레이어 설정
      • 배경 지도 설정
      • 거리 측정
      • 면적 측정
      • 높이 측정
      • 반경 측정
  • API
    • Module
    • Core
      • Collection
      • JSAABBox3D
      • JSColor
      • JSLine3D
      • JSSize2D
      • JSSize3D
      • JSVector2D
      • JSVector3D
      • JSVec2Array
      • JSVec3Array
      • JSDateTime
    • Analysis
      • JSAnalysis
      • JSAnalysisGridShadow
      • JSEarthquake
      • JSEditTerrain
      • JSFlood
      • JSGridAnal
      • JSSightAnalysis
      • JSSlope
      • JSTransparency
      • JSSolarManager
    • Camera
      • JSCamera
    • Layer
      • JSLayer
      • JSLayerList
      • JSImageryProvider
    • Map
      • JSMap
      • JSTerrain
      • JSIndexMap
    • Object
      • JSObject
      • JSAntenna
      • JSArrow
      • JSBarGraph
      • JSBarGraph3D
      • JSBillboard
      • JSColorGrid
      • JSColorGrid3D
      • JSColorPolygon
      • JSFigure
      • JSFlow
      • JSFlowPolygon
      • JSGhostSymbol
      • JSGhostSymbolMap
      • JSHTMLObject
      • JSIcon
      • JSInstanceObject
      • JSLineString
      • JSMultiCube
      • JSMultiPoint
      • JSPipe
      • JSPoint
      • JSPointGraph
      • JSPolygon
      • JSPolygonStyle
      • JSPolyLineStyle
      • JSReal3D
      • JSSurfaceGraph
      • JSSymbol
      • JSTimeSeriesObject
      • JSTraceTarget
      • JSTyphoon
      • JSVideoObject
      • JSViewFrustum
    • Option
      • JSControl
      • JSNavigationControl
      • JSOption
    • ETC
      • JSMath
      • JSProj
      • ~~JSProjection~~
      • SOPObject
      • EVENT
      • Type List
      • Tag List
Powered by GitBook
On this page
  • Function
  • createbyJson(option) → string
  • getBoundary() → JSAABBox3D
  • getCenter() → JSVector3D
  • getExtent() → number
  • getId() → string
  • getLength(terrain) → number
  • SetDashType(dash) → boolean
  • setPartCoordinates(coordinates, parts)
  • setUnionMode(type)
  • Getter / Setter
  • getDescription(), setDescription(desc) → string
  • getName(), setName(name) → string
  • getVisible(), setVisible(visible) → boolean
  • getCoordinates(), setCoordinates(coordinates) → Collection
  • getStyle(), setStyle(style) → JSPolyLineStyle
  • Type Definitions

Was this helpful?

  1. API
  2. Object

JSLineString

지도 내 선 객체를 생성 및 설정하기 위한 API 입니다.

PreviousJSInstanceObjectNextJSMultiCube

Last updated 11 months ago

Was this helpful?

Module.createLineString() API를 생성합니다.

var object = Module.createLineString("ID");

Function

createbyJson(option) → string

선 객체를 생성합니다.

Name
Type
Description

option

속성 정보.

  • Return

    • "success": 생성 성공.

    • 이 외 오류 원인을 포함한 에러 메시지

  • Sample

    • function createLine 참조.

getBoundary() →

선 객체를 포함하는 박스 영역을 반환합니다.

  • Return

    • : 반환 성공.

    • null: 반환 실패.

var boundary = object.getBoundary();
var boundary_min = boundary.min;
var boundary_max = boundary.max;

선 객체를 중심 좌표(경도, 위도, 고도)를 반환합니다.

  • Return

    • null: 반환 실패.

var vCenter = object.getCenter();
var dCenterLon = vCenter.Longitude;
var dCenterLat = vCenter.Latitude;
var dCenterAlt = vCenter.Altitude;

getExtent() → number

선 객체를 포함하는 박스 영역을 min, max간 거리를 반환합니다..

  • Return

    • number: 거리 반환.

var bExtends = object.getExtent();

getId() → string

객체의 고유 명칭을 반환 합니다.

  • Return

    • string: 객체 설명 문자열이 성공적으로 반환.

    • null: 객체가 null인 경우.

var strKey = object.getId();

getLength(terrain) → number

선 객체의 총 길이를 반환합니다.

Name
Type
Description

terrain

boolean

지형 곡면률 설정 유무. true: 지형 곡면률 고려한 길이 계산. false: 입력된 좌표에 대한 길이 계산.

  • Return

    • number(0 이상): 반환 성공.

    • number(-1.0): 반환 실패.

var length = object.getLength();

SetDashType(dash) → boolean

선 간격을 설정합니다.

Name
Type
Description

dash

number

점선 간격.

  • Return

    • true: 설정 성공.

    • false: 설정 실패.

setPartCoordinates(coordinates, parts)

선 객체를 생성합니다.

입력 변수값(coordinates)은 3개 이상 입력되어야 합니다.

입력 변수값(parts)은 1개 이상 입력되어야 합니다.

Name
Type
Description

coordinates

좌표 목록(경도, 위도, 고도).

parts

직선을 구성하는 coordinates 개수 목록.

  • Sample

    • function createBufferPolygon 참조.

setUnionMode(type)

선 객체 가시화 옵션을 설정합니다.

선 생성 시 지형 결합 유무를 설정합니다.

Name
Type
Description

type

boolean

true: 지형 결합 가시화(RTT). false: 일반 가시화.

  • Sample

    • function createObjectToPathPosition 참조.

Getter / Setter

getDescription(), setDescription(desc) → string

객체에 대한 설명을 설정합니다.

Name
Type
Description

desc

string

설명 문자열.

  • Return

    • string: 객체 설명 문자열이 성공적으로 반환.

    • null: 객체가 null인 경우.

var strDesc = object.getDescription();
// ... or ...
object.setDescription("First Object.");

getName(), setName(name) → string

객체 이름을 설정합니다.

Name
Type
Description

name

string

객체 이름.

  • Return

    • string: 객체 이름을 성공적을 반환

    • null: 객체가 null인 경우.

var objName = object.getName();
// ... or ...
object.setName("MyObject");

getVisible(), setVisible(visible) → boolean

객체의 가시화 유무를 설정합니다.

Name
Type
Description

visible

boolean

true: 객체 가시화. false: 객체 비가시화.

  • Return

    • true: 객체 가시화 상태.

    • false: 객체 비가시화 상태.

var objName = object.getName();
// ... or ...
object.setVisible(true);

선 객체를 구성하는 좌표 목록을 설정합니다.

입력 변수값(coordinates)은 3개 이상 입력되어야 합니다.

Name
Type
Description

coordinates

좌표 목록(경도, 위도, 고도).

  • Return

  • Sample

    • function createPathLine 참조.

var coorList = object.getCoordinates();

색상, 두께, 투명도 등을 설정합니다.

Name
Type
Description

style

선 스타일.

  • Return

  • Sample

    • function createBufferPolygon 참조.

var objectStyle = polyLine.getStyle();

Type Definitions

JSLineString.CreateOptions

직선 객체 생성 옵션.

Name
Type
Attributes
Default
Description

coordinates

좌표 목록 옵션.

type

number

optional

0

라인 가시화 타입.

skip

number

optional

1

애니메이션 디테일 옵션.

width

number

optional

1

라인 굵기 옵션.

dash

number

optional

0

점선 간격 옵션.

speed

number

optional

0

애니메이션 속도 옵션.

union

boolean

optional

false

true: 지형 결합 가시화(RTT). false: 일반 가시화.

depth

boolean

optional

true

true: 일반 가시화. false: 깊이감 미표현 가시화.

color

optional

JSColor(200, 255, 255, 255)

라인 가시화 색상.

getCenter() →

: 반환 성공.

getCoordinates(), setCoordinates(coordinates) →

: 선을 구성하는 좌표 목록.

getStyle(), setStyle(style) →

선 객체를 으로 설정된 스타일로 설정합니다.

: 설정 성공.

Sandbox_Line
JSAABBox3D
JSAABBox3D
JSVector3D
JSVector3D
Sandbox_Line Buffering
Sandbox_Path Analysis
Collection
Collection
Sandbox_Path Analysis
JSPolyLineStyle
JSPolyLineStyle
JSPolyLineStyle
Sandbox_Line Buffering
JSVec3Array
Collection
Collection
JSPolyLineStyle
JSColor
JSLineString.CreateOptions
coordinates Type