//
//  RegistereNga.swift
//  Sailassist
//
//  Created by 三浦薫巳 on 2024/05/16.
//

import Foundation
import CoreLocation
import SwiftUI

let ngaAreaMax = 30
let ngaAreaPointMax = 50

enum EditNgaType {
    case nonEdit
    case addPoint
    case movePoint
    case deletePoint
    case registered
}

struct RegisteredNga {
    var areaId = UUID()
    var isLock: Bool = false
    var isRunning: Bool = false
    var passingCnt: Int = 0         //1以上で通過中
    var name: String = ""           //Area名称
    var datetime: String = ""       //時刻（UTC ISO8601準拠）
    var color = Color.green.description          //ライン色（ARGB）
    var width: Int = 1              //ライン幅
    var isUpdate: Bool = false
    var points: [CLLocationCoordinate2D] = []

    init?(areaName: String ) {
        self.name = areaName
    }
}
