diff --git "a/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/Collection_array.playground/Contents.swift" "b/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/Collection_array.playground/Contents.swift" new file mode 100644 index 0000000..e6632cb --- /dev/null +++ "b/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/Collection_array.playground/Contents.swift" @@ -0,0 +1,30 @@ +//: Playground - noun: a place where people can play + +import UIKit + +//배열의 선언 +var meetingRoom:Array = ["A","B","P","S","E"] +var groups:[Int] = [10, 8, 8, 6] + +meetingRoom += ["R"] + +//배열의 추가1 +var currentSpeed = 20 +var speedHistory:[Int] = [] +speedHistory += [currentSpeed] +let gps = 114.1 +let gps2 = 220.2 + +//배열의 추가2 +speedHistory.append(Int(gps)) + +//배열의 추가3 +speedHistory.insert(Int(gps2), at: 0) + +speedHistory[0] +speedHistory.first + +//배열의 복제. 바로 되지 않고 둘 중 하나의 값이 변경이 될 때 복제된다 +let historyBackup = speedHistory +speedHistory += [130] +historyBackup diff --git "a/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/Collection_array.playground/contents.xcplayground" "b/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/Collection_array.playground/contents.xcplayground" new file mode 100644 index 0000000..5da2641 --- /dev/null +++ "b/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/Collection_array.playground/contents.xcplayground" @@ -0,0 +1,4 @@ + + + + \ No newline at end of file diff --git "a/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/Collection_array.playground/playground.xcworkspace/contents.xcworkspacedata" "b/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/Collection_array.playground/playground.xcworkspace/contents.xcworkspacedata" new file mode 100644 index 0000000..919434a --- /dev/null +++ "b/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/Collection_array.playground/playground.xcworkspace/contents.xcworkspacedata" @@ -0,0 +1,7 @@ + + + + + diff --git "a/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/Collection_dictionary.playground/Contents.swift" "b/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/Collection_dictionary.playground/Contents.swift" new file mode 100644 index 0000000..5dac720 --- /dev/null +++ "b/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/Collection_dictionary.playground/Contents.swift" @@ -0,0 +1,40 @@ +//: Playground - noun: a place where people can play + +import UIKit + +//Dictionary. [key:value] +var roomCapacity:[String:Int] = ["A":10, "B":20, "P":8, "S":10, "E":30] + +//딕셔너리의 추가 +roomCapacity["R"] = 40 +roomCapacity["A"] + +//let roomNames = roomCapacity.keys +//let capacity = roomCapacity.values + +//딕셔너리에서 값을 배열로 가지고 오는 방법 +let roomNames = [String](roomCapacity.keys) +let capacity = [Int](roomCapacity.values) + +//set. 순서를 가지지 않는 컬렉션. 집합연산이 필요한 경우. intersection, Subtract, Union, symmetricDifference +let subway2:Set = ["사당", "방배", "서초", "교대", "강남", "삼성", "신도림", "신림"] +let subway3:Set = ["사당", "블라", "몰리", "서초", "강남", "모름", "가라", "거나나"] + +let transfer = subway2.intersection(subway3) + +//영웅들로 구성된 파티를 만들어, 상대방의 파티와 싸우는 게임을 만드려고 합니다. 기존 파티 heros에 새로운 영웅 newHero를 파티의 맨 앞에 영입하는 완성하세요. heros에 새로운 항목을 추가할 수 있도록 만든 뒤, newHero를 맨 앞에 추가하면 됩니다. +var heros = ["프린스", "마녀", "해골 군대", "고블린 통"] +let newHero = "흑룡" + +heros.insert(newHero, at: 0) + +print(heros) + +//상대방의 영웅 파티가 나타났습니다. 상대방과 겨룰 때에는 서로 겹치는 영웅들끼리만 대전을 할 수 있습니다. 내가 가진 영웅 heros과 상대의 영웅 oppHeros끼리 겹치는 영웅으로 이루어진 Set인 intersectHeros를 구하세요. +let heros2:Set = ["프린스", "마녀", "해골 군대", "고블린 통"] +let oppHeros2:Set = ["자이언트 해골", "고블린 통", "대형석궁", "프린스"] + +// 상대와 겹치는 영웅들로 이뤄진 set을 완성하세요 +let intersectHeros = heros2.intersection(oppHeros2) + +print(intersectHeros) diff --git "a/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/Collection_dictionary.playground/contents.xcplayground" "b/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/Collection_dictionary.playground/contents.xcplayground" new file mode 100644 index 0000000..5da2641 --- /dev/null +++ "b/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/Collection_dictionary.playground/contents.xcplayground" @@ -0,0 +1,4 @@ + + + + \ No newline at end of file diff --git "a/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/Collection_dictionary.playground/playground.xcworkspace/contents.xcworkspacedata" "b/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/Collection_dictionary.playground/playground.xcworkspace/contents.xcworkspacedata" new file mode 100644 index 0000000..919434a --- /dev/null +++ "b/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/Collection_dictionary.playground/playground.xcworkspace/contents.xcworkspacedata" @@ -0,0 +1,7 @@ + + + + + diff --git "a/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/ControlFlow.playground/Contents.swift" "b/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/ControlFlow.playground/Contents.swift" new file mode 100644 index 0000000..879e1f9 --- /dev/null +++ "b/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/ControlFlow.playground/Contents.swift" @@ -0,0 +1,55 @@ +//: Playground - noun: a place where people can play + +import UIKit + +//for문과 if문 +let subway2:Set = ["사당", "방배", "서초", "교대", "강남", "삼성", "신도림", "신림"] +let subway3:Set = ["사당", "블라", "몰리", "서초", "강남", "모름", "가라", "거나나"] +let transfer = subway2.intersection(subway3) + +if transfer.count > 0 { + print("환승역은 \(transfer)입니다") +} else { + print("환승역은 없습니다") +} + +for station in subway3 { + print("이번 역은 \(station)입니다") +} + +//switch문 +//딕셔너리를 for문으로 돌릴 때, 튜플로 받아 올 수 있다. +var roomCapacity:[String:Int] = ["A":10, "B":20, "P":8, "S":10, "E":30, "G":40, "C":4] + +for (roomName, capacity) in roomCapacity { + let roomDescription:String + switch capacity { + case 4: + roomDescription = "\(roomName)은 스터디룸이며 정원은 \(capacity)명입니다." + case 5...10: + roomDescription = "\(roomName)은 팀세미나룸이며 정원은 \(capacity)명입니다." + case 11...30: + roomDescription = "\(roomName)은 그룹세미나룸이며 정원은 \(capacity)명입니다." + case _ where capacity > 30: + roomDescription = "\(roomName)의 정원은 \(capacity)이며 별도의 신청이 필요합니다." + default: + roomDescription = "\(roomName)의 정보를 다시 확인해주세요." + } +} + + +//그마트에서는 아이템 수량에 따라 계산 카운터를 안내하는 차세대 카트를 도입하려고 합니다. 카트에 담긴 맥주 수량에 따라3병 이하는 소량 계산대로 보내고, 4병부터 50병까지는 일반 계산대로 보내고, 51병 부터 100병까지의 구매는 매니저에게 연락하고, 100병 이상은 경찰에 신고하는 switch문을 완성해 주세요. + +typealias ShopingItem = (name:String, amount:Int) +let cart = ShopingItem("beer", 1) + +switch cart { +case ("beer", 0...3) : //맥주 3병 이하 + print("Guide to small item counter") +case ("beer", 51...100) : //맥주 51병이상 100병 까지 + print("Call manager") +case ("beer", let amount) where amount > 100 : //맥주 100병 초과 + print("Call police") +default: //나머지(맥주 4병 이상 50병 이하) + print("Make wait in line") +} diff --git "a/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/ControlFlow.playground/contents.xcplayground" "b/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/ControlFlow.playground/contents.xcplayground" new file mode 100644 index 0000000..5da2641 --- /dev/null +++ "b/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/ControlFlow.playground/contents.xcplayground" @@ -0,0 +1,4 @@ + + + + \ No newline at end of file diff --git "a/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/ControlFlow.playground/playground.xcworkspace/contents.xcworkspacedata" "b/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/ControlFlow.playground/playground.xcworkspace/contents.xcworkspacedata" new file mode 100644 index 0000000..919434a --- /dev/null +++ "b/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/ControlFlow.playground/playground.xcworkspace/contents.xcworkspacedata" @@ -0,0 +1,7 @@ + + + + + diff --git "a/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/Enum associated value.playground/Contents.swift" "b/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/Enum associated value.playground/Contents.swift" new file mode 100644 index 0000000..aa09ce4 --- /dev/null +++ "b/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/Enum associated value.playground/Contents.swift" @@ -0,0 +1,119 @@ +//: Playground - noun: a place where people can play + +import UIKit + +/*TaskType이라는 이너머레이션에 Associated Value를 설정 + Task 구조체 안에 선언한 doBasicTask( )라는 메소드 + Task의 타입 값에 따라 switch 문을 통해 각각 다른 작업을 수행 + .Call 이면 전화 번호를 number 상수로 + .Report이면 receiver와 time이라는 값 + .Meet과 .Support의 경우 적당한 상수값 + */ + +struct Task { + var title:String + var time:Int? + + var owner:Employee + //var participant:Employee? + + var type:TaskType + enum TaskType { + case Call(number:String) + case Report(to:Employee, when:String) + case Meet(with:Employee, location:String) + case Support(who:Employee, duration:Int) + + var typeTitle:String { + get { + let titleString:String + switch self { + case .Call: + titleString = "Call" + case .Report: + titleString = "Report" + case .Meet: + titleString = "Meet" + case .Support: + titleString = "Support" + } + return titleString + } + } + } + + init(type:TaskType, owner:Employee) { + self.type = type + self.title = type.typeTitle + self.owner = owner + self.time = nil + //self.participant = nil + } + + func doBasicTask() -> String { + let taskDescription:String + switch type { + case .Call(let number): + taskDescription = "\(owner.name!) make a call to \(number)" + case .Report(let reciever, let time): + taskDescription = "\(owner.name!) report to \(reciever.name!) at \(time)" + case .Meet(let participant, let location): + taskDescription = "\(owner.name!) meet \(participant.name!) at \(location)" + case .Support(let taskOwner, let duration): + taskDescription = "\(owner.name!) support \(taskOwner.name!) for \(duration) days" + default: + taskDescription = "Need more information" + } + return taskDescription + } +} + +class Employee { + var name:String? + var phoneNumber:String? + var boss:Employee? + + init (name:String) { + self.name = name + } + + init(name:String, phone:String) { + self.name = name + self.phoneNumber = phone + } + + func report() { + if let myBoss = boss { + print("\(name!) reported to \(myBoss).") + } else { + print("\(name!) don't have a boss.") + } + } + + func callTaskToBoss() -> Task? { + if let myBoss = boss, let callTo = myBoss.phoneNumber { + let callTask = Task(type: .Call(number: callTo), owner:self) + return callTask + } + return nil + } +} +var todayTask:[Task] = [] + +let me:Employee = Employee(name: "Alex", phone:"010-3398-8792") +let toby = Employee(name: "Toby") +toby.phoneNumber = "010-3392-8765" +me.boss = toby + +var reportTask = Task(type:.Report(to:toby, when:"afternoon"), owner:me) +reportTask.doBasicTask() +todayTask += [reportTask] + +if let callTask = me.callTaskToBoss() { + todayTask += [callTask] + callTask.doBasicTask() +} + +todayTask[1].time = 15*60 + +print("Today task = \(todayTask)") diff --git "a/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/Enum associated value.playground/contents.xcplayground" "b/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/Enum associated value.playground/contents.xcplayground" new file mode 100644 index 0000000..5da2641 --- /dev/null +++ "b/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/Enum associated value.playground/contents.xcplayground" @@ -0,0 +1,4 @@ + + + + \ No newline at end of file diff --git "a/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/Enum associated value.playground/playground.xcworkspace/contents.xcworkspacedata" "b/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/Enum associated value.playground/playground.xcworkspace/contents.xcworkspacedata" new file mode 100644 index 0000000..919434a --- /dev/null +++ "b/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/Enum associated value.playground/playground.xcworkspace/contents.xcworkspacedata" @@ -0,0 +1,7 @@ + + + + + diff --git "a/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/Enum associated value.playground/timeline.xctimeline" "b/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/Enum associated value.playground/timeline.xctimeline" new file mode 100644 index 0000000..1993bf2 --- /dev/null +++ "b/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/Enum associated value.playground/timeline.xctimeline" @@ -0,0 +1,28 @@ + + + + + + + + + + + + + diff --git "a/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/Enumeration.playground/Contents.swift" "b/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/Enumeration.playground/Contents.swift" new file mode 100644 index 0000000..f1084d6 --- /dev/null +++ "b/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/Enumeration.playground/Contents.swift" @@ -0,0 +1,88 @@ +//: Playground - noun: a place where people can play + +import UIKit + +struct Task { + var title:String + var time:Int? + + var owner:Employee + var participant:Employee? + + /*연관성 있는 값들의 그룹을 만들어 Type-Safe 하게 사용하는 것이다. + + 여러 다른 언어에서 일련의 값에 일대일 대응되는 Enum을 정의해서 사용 + + Task의 상태 값을 나타내기 위해 0, 1, 2등의 정수값을 사용 + 보다 직관적으로 0은 READY, 1은 COUNTING, 2는 PAUSED, 3은 DONE과 같이 Enum으로 정의해서 사용하는 방식 + Swift에서 Enumeration은 더욱 강력한 기능을 가진다 + + 1st class type + 매개변수나 리턴타입으로 사용 + 메소드를 가진다거나 프로토콜을 준수 + */ + var type:TaskType + enum TaskType { + case Call + case Report + case Meet + case Support + + var titleString:String { + get { + let titleString:String + switch self { + case .Call: + titleString = "Call" + case .Report: + titleString = "Report" + case .Meet: + titleString = "Meet" + case .Support: + titleString = "Support" + } + return titleString + } + } + } +} + +class Employee { + var name:String? + var phoneNumber:String? + var boss:Employee? +} + +let me:Employee = Employee() +me.name = "Alex" +me.phoneNumber = "010-3398-9879" + +let toby = Employee() +toby.name = "Toby" +toby.phoneNumber = "010-3392-8765" + +//열거형의 사용 +var callTask = Task(title: "Call to Toby", time: 10*60, owner:me, participant:toby, type:.Call) +var reportTask = Task(title: "report to Boss", time: nil, owner:me, participant:nil, type:Task.TaskType.Report) + +var todayTask:[Task] = [] +todayTask += [callTask, reportTask] +todayTask[1].time = 15*60 + +callTask.title = "Call to Toby" + +print("Today task = \(todayTask)") + + +//자동차는 저마다 사용하는 연료의 종류가 다릅니다. 자동차를 크게 휘발유를 쓰는 차, 경유를 쓰는 차, 가스를 쓰는 차로 이렇게 3가지로 분류할 수 있습니다. 연료를 다음과 같이 Fuel이라는 enum으로 추상화 했을 때, 경유를 쓰는 자동차 mini01, 휘발유를 쓰는 자동차 mini02를 enum으로 표현해 보세요 +enum Fuel { + case Gasoline // 휘발유 + case Diesel // 경유 + case LPG // 가스 +} + +// 빈 칸을 enum을 써서 채워보세요 +let mini01Fuel = Fuel.Diesel +let mini02Fuel = Fuel.Gasoline + +print("mini01은 연료로 \(mini01Fuel)을 쓰고, mini02는 연료로 \(mini02Fuel)을 씁니다") diff --git "a/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/Enumeration.playground/contents.xcplayground" "b/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/Enumeration.playground/contents.xcplayground" new file mode 100644 index 0000000..5da2641 --- /dev/null +++ "b/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/Enumeration.playground/contents.xcplayground" @@ -0,0 +1,4 @@ + + + + \ No newline at end of file diff --git "a/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/Enumeration.playground/playground.xcworkspace/contents.xcworkspacedata" "b/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/Enumeration.playground/playground.xcworkspace/contents.xcworkspacedata" new file mode 100644 index 0000000..919434a --- /dev/null +++ "b/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/Enumeration.playground/playground.xcworkspace/contents.xcworkspacedata" @@ -0,0 +1,7 @@ + + + + + diff --git "a/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/Enumeration.playground/timeline.xctimeline" "b/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/Enumeration.playground/timeline.xctimeline" new file mode 100644 index 0000000..bf46b29 --- /dev/null +++ "b/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/Enumeration.playground/timeline.xctimeline" @@ -0,0 +1,16 @@ + + + + + + + + + diff --git "a/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/Function.playground/Contents.swift" "b/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/Function.playground/Contents.swift" new file mode 100644 index 0000000..3176309 --- /dev/null +++ "b/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/Function.playground/Contents.swift" @@ -0,0 +1,54 @@ + //: Playground - noun: a place where people can play + +import UIKit + +var title = "Tutorial for swift" +var ratings:[Double]? = nil +var supportUrl:String! = nil + +supportUrl = "www.DJ.com" +ratings = [2.0, 3.5, 4.5, 5.0, 3.5] + +//함수 +func ratingRecord (history:[Double]) -> (average:Double, min:Double, max:Double) { + var sum = 0.0, min = history[0], max = history[0] + + for value in history { + if min > value {min = value} + if max < value {max = value} + sum += value + } + let average = sum / Double(history.count) + return (average, min, max) +} + +var bookDescription:String = "\(title)" +if let theRating = ratings { + let record = ratingRecord(history: theRating) + bookDescription += " has \(theRating.count) ratings, \r\naverage is \(record.average), from \(record.min) to \(record.max)" +} + +bookDescription += "\r\nsupport webpage : \(supportUrl)" + +print(bookDescription) + + +//Time타입의 인자를 2개 받아, 둘을 더 한 시간을 리턴하는 함수를 만들어주세요. 시간을 나타내는 타입 Time은 typealias로 정의되어 있습니다. +typealias Time = (minute:Int, second:Int) + +let lunch = (16, 37) +let walk = (18, 48) + +// 함수의 인자와 리턴 타입을 명시해주세요 +func addTime (time1:Time, time2:Time) -> Time { + let secondSum = time1.second + time2.second + let second = secondSum % 60 + let minute = time1.minute + time2.minute + (secondSum / 60) + + // minute과 second를 이용해서 적절한 값을 리턴해주세요 + return Time(minute, second) +} + +//atNoon의 값은 (35, 25) 이어야 합니다. +let atNoon = addTime(time1:lunch, time2:walk) +print(atNoon) diff --git "a/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/Function.playground/contents.xcplayground" "b/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/Function.playground/contents.xcplayground" new file mode 100644 index 0000000..5da2641 --- /dev/null +++ "b/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/Function.playground/contents.xcplayground" @@ -0,0 +1,4 @@ + + + + \ No newline at end of file diff --git "a/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/Function.playground/playground.xcworkspace/contents.xcworkspacedata" "b/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/Function.playground/playground.xcworkspace/contents.xcworkspacedata" new file mode 100644 index 0000000..919434a --- /dev/null +++ "b/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/Function.playground/playground.xcworkspace/contents.xcworkspacedata" @@ -0,0 +1,7 @@ + + + + + diff --git "a/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/FunctionType.playground/Contents.swift" "b/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/FunctionType.playground/Contents.swift" new file mode 100644 index 0000000..6f4da1d --- /dev/null +++ "b/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/FunctionType.playground/Contents.swift" @@ -0,0 +1,43 @@ +//: Playground - noun: a place where people can play + +import UIKit + +/*함수는 1등 시민 + 함수는 어디든 갈 수 있는 권리가 있다 + 변수에 할당 + 매개변수로 사용 + 리턴타입으로 사용 + + 우리가 알고 있는 타입들 + String, Double, Int 같은 기본 타입들 + Array, Dictionary, Set 같은 컬렉션 타입 + UIView, UILabel, UItableView 같은 코코아 클래스 타입 + + +  함수타입 + () -> Void 또는 (Int, Int) -> Int 같은 함수타입 + */ + +func addVAT (source:Double) -> Double { + return source * 1.1 +} + +func couponDiscount (source:Double) -> Double { + return source * 0.9 +} + +//함수타입의 변수 선언 +var additional:(Double) -> Double + +let transaction1023 = 300.5 +//함수를 변수에 할당 +additional = addVAT + +let price1023 = additional(transaction1023) + +//함수를 매개변수로 받는 함수 +func finalPrice (source:Double, additional:(Double) -> Double) -> Double { + let price = additional(source) + return price +} + +let price1024 = finalPrice(source: 350.0, additional: couponDiscount) diff --git "a/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/FunctionType.playground/contents.xcplayground" "b/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/FunctionType.playground/contents.xcplayground" new file mode 100644 index 0000000..5da2641 --- /dev/null +++ "b/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/FunctionType.playground/contents.xcplayground" @@ -0,0 +1,4 @@ + + + + \ No newline at end of file diff --git "a/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/KBOHallOfFame_customCell/KBOHallOfFame.xcodeproj/project.pbxproj" "b/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/KBOHallOfFame_customCell/KBOHallOfFame.xcodeproj/project.pbxproj" new file mode 100644 index 0000000..bf1a0dc --- /dev/null +++ "b/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/KBOHallOfFame_customCell/KBOHallOfFame.xcodeproj/project.pbxproj" @@ -0,0 +1,333 @@ +// !$*UTF8*$! +{ + archiveVersion = 1; + classes = { + }; + objectVersion = 48; + objects = { + +/* Begin PBXBuildFile section */ + 2C042DF31F9C635D00979B56 /* AppDelegate.swift in Sources */ = {isa = PBXBuildFile; fileRef = 2C042DF21F9C635D00979B56 /* AppDelegate.swift */; }; + 2C042DF51F9C635D00979B56 /* ViewController.swift in Sources */ = {isa = PBXBuildFile; fileRef = 2C042DF41F9C635D00979B56 /* ViewController.swift */; }; + 2C042DF81F9C635D00979B56 /* Main.storyboard in Resources */ = {isa = PBXBuildFile; fileRef = 2C042DF61F9C635D00979B56 /* Main.storyboard */; }; + 2C042DFA1F9C635D00979B56 /* Assets.xcassets in Resources */ = {isa = PBXBuildFile; fileRef = 2C042DF91F9C635D00979B56 /* Assets.xcassets */; }; + 2C042DFD1F9C635D00979B56 /* LaunchScreen.storyboard in Resources */ = {isa = PBXBuildFile; fileRef = 2C042DFB1F9C635D00979B56 /* LaunchScreen.storyboard */; }; + 2C042E051F9C64FF00979B56 /* KBOTableViewController.swift in Sources */ = {isa = PBXBuildFile; fileRef = 2C042E041F9C64FF00979B56 /* KBOTableViewController.swift */; }; + 2C042E111FA819F900979B56 /* HitterTableViewCell.swift in Sources */ = {isa = PBXBuildFile; fileRef = 2C042E101FA819F900979B56 /* HitterTableViewCell.swift */; }; +/* End PBXBuildFile section */ + +/* Begin PBXFileReference section */ + 2C042DEF1F9C635D00979B56 /* KBOHallOfFame.app */ = {isa = PBXFileReference; explicitFileType = wrapper.application; includeInIndex = 0; path = KBOHallOfFame.app; sourceTree = BUILT_PRODUCTS_DIR; }; + 2C042DF21F9C635D00979B56 /* AppDelegate.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = AppDelegate.swift; sourceTree = ""; }; + 2C042DF41F9C635D00979B56 /* ViewController.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = ViewController.swift; sourceTree = ""; }; + 2C042DF71F9C635D00979B56 /* Base */ = {isa = PBXFileReference; lastKnownFileType = file.storyboard; name = Base; path = Base.lproj/Main.storyboard; sourceTree = ""; }; + 2C042DF91F9C635D00979B56 /* Assets.xcassets */ = {isa = PBXFileReference; lastKnownFileType = folder.assetcatalog; path = Assets.xcassets; sourceTree = ""; }; + 2C042DFC1F9C635D00979B56 /* Base */ = {isa = PBXFileReference; lastKnownFileType = file.storyboard; name = Base; path = Base.lproj/LaunchScreen.storyboard; sourceTree = ""; }; + 2C042DFE1F9C635D00979B56 /* Info.plist */ = {isa = PBXFileReference; lastKnownFileType = text.plist.xml; path = Info.plist; sourceTree = ""; }; + 2C042E041F9C64FF00979B56 /* KBOTableViewController.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = KBOTableViewController.swift; sourceTree = ""; }; + 2C042E101FA819F900979B56 /* HitterTableViewCell.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = HitterTableViewCell.swift; sourceTree = ""; }; +/* End PBXFileReference section */ + +/* Begin PBXFrameworksBuildPhase section */ + 2C042DEC1F9C635D00979B56 /* Frameworks */ = { + isa = PBXFrameworksBuildPhase; + buildActionMask = 2147483647; + files = ( + ); + runOnlyForDeploymentPostprocessing = 0; + }; +/* End PBXFrameworksBuildPhase section */ + +/* Begin PBXGroup section */ + 2C042DE61F9C635D00979B56 = { + isa = PBXGroup; + children = ( + 2C042DF11F9C635D00979B56 /* KBOHallOfFame */, + 2C042DF01F9C635D00979B56 /* Products */, + ); + sourceTree = ""; + }; + 2C042DF01F9C635D00979B56 /* Products */ = { + isa = PBXGroup; + children = ( + 2C042DEF1F9C635D00979B56 /* KBOHallOfFame.app */, + ); + name = Products; + sourceTree = ""; + }; + 2C042DF11F9C635D00979B56 /* KBOHallOfFame */ = { + isa = PBXGroup; + children = ( + 2C042DF21F9C635D00979B56 /* AppDelegate.swift */, + 2C042DF41F9C635D00979B56 /* ViewController.swift */, + 2C042DF61F9C635D00979B56 /* Main.storyboard */, + 2C042E101FA819F900979B56 /* HitterTableViewCell.swift */, + 2C042E041F9C64FF00979B56 /* KBOTableViewController.swift */, + 2C042DF91F9C635D00979B56 /* Assets.xcassets */, + 2C042DFB1F9C635D00979B56 /* LaunchScreen.storyboard */, + 2C042DFE1F9C635D00979B56 /* Info.plist */, + ); + path = KBOHallOfFame; + sourceTree = ""; + }; +/* End PBXGroup section */ + +/* Begin PBXNativeTarget section */ + 2C042DEE1F9C635D00979B56 /* KBOHallOfFame */ = { + isa = PBXNativeTarget; + buildConfigurationList = 2C042E011F9C635D00979B56 /* Build configuration list for PBXNativeTarget "KBOHallOfFame" */; + buildPhases = ( + 2C042DEB1F9C635D00979B56 /* Sources */, + 2C042DEC1F9C635D00979B56 /* Frameworks */, + 2C042DED1F9C635D00979B56 /* Resources */, + ); + buildRules = ( + ); + dependencies = ( + ); + name = KBOHallOfFame; + productName = KBOHallOfFame; + productReference = 2C042DEF1F9C635D00979B56 /* KBOHallOfFame.app */; + productType = "com.apple.product-type.application"; + }; +/* End PBXNativeTarget section */ + +/* Begin PBXProject section */ + 2C042DE71F9C635D00979B56 /* Project object */ = { + isa = PBXProject; + attributes = { + LastSwiftUpdateCheck = 0900; + LastUpgradeCheck = 0900; + ORGANIZATIONNAME = LingoStar; + TargetAttributes = { + 2C042DEE1F9C635D00979B56 = { + CreatedOnToolsVersion = 9.0; + ProvisioningStyle = Automatic; + }; + }; + }; + buildConfigurationList = 2C042DEA1F9C635D00979B56 /* Build configuration list for PBXProject "KBOHallOfFame" */; + compatibilityVersion = "Xcode 8.0"; + developmentRegion = en; + hasScannedForEncodings = 0; + knownRegions = ( + en, + Base, + ); + mainGroup = 2C042DE61F9C635D00979B56; + productRefGroup = 2C042DF01F9C635D00979B56 /* Products */; + projectDirPath = ""; + projectRoot = ""; + targets = ( + 2C042DEE1F9C635D00979B56 /* KBOHallOfFame */, + ); + }; +/* End PBXProject section */ + +/* Begin PBXResourcesBuildPhase section */ + 2C042DED1F9C635D00979B56 /* Resources */ = { + isa = PBXResourcesBuildPhase; + buildActionMask = 2147483647; + files = ( + 2C042DFD1F9C635D00979B56 /* LaunchScreen.storyboard in Resources */, + 2C042DFA1F9C635D00979B56 /* Assets.xcassets in Resources */, + 2C042DF81F9C635D00979B56 /* Main.storyboard in Resources */, + ); + runOnlyForDeploymentPostprocessing = 0; + }; +/* End PBXResourcesBuildPhase section */ + +/* Begin PBXSourcesBuildPhase section */ + 2C042DEB1F9C635D00979B56 /* Sources */ = { + isa = PBXSourcesBuildPhase; + buildActionMask = 2147483647; + files = ( + 2C042E051F9C64FF00979B56 /* KBOTableViewController.swift in Sources */, + 2C042DF51F9C635D00979B56 /* ViewController.swift in Sources */, + 2C042DF31F9C635D00979B56 /* AppDelegate.swift in Sources */, + 2C042E111FA819F900979B56 /* HitterTableViewCell.swift in Sources */, + ); + runOnlyForDeploymentPostprocessing = 0; + }; +/* End PBXSourcesBuildPhase section */ + +/* Begin PBXVariantGroup section */ + 2C042DF61F9C635D00979B56 /* Main.storyboard */ = { + isa = PBXVariantGroup; + children = ( + 2C042DF71F9C635D00979B56 /* Base */, + ); + name = Main.storyboard; + sourceTree = ""; + }; + 2C042DFB1F9C635D00979B56 /* LaunchScreen.storyboard */ = { + isa = PBXVariantGroup; + children = ( + 2C042DFC1F9C635D00979B56 /* Base */, + ); + name = LaunchScreen.storyboard; + sourceTree = ""; + }; +/* End PBXVariantGroup section */ + +/* Begin XCBuildConfiguration section */ + 2C042DFF1F9C635D00979B56 /* Debug */ = { + isa = XCBuildConfiguration; + buildSettings = { + ALWAYS_SEARCH_USER_PATHS = NO; + CLANG_ANALYZER_NONNULL = YES; + CLANG_ANALYZER_NUMBER_OBJECT_CONVERSION = YES_AGGRESSIVE; + CLANG_CXX_LANGUAGE_STANDARD = "gnu++14"; + CLANG_CXX_LIBRARY = "libc++"; + CLANG_ENABLE_MODULES = YES; + CLANG_ENABLE_OBJC_ARC = YES; + CLANG_WARN_BLOCK_CAPTURE_AUTORELEASING = YES; + CLANG_WARN_BOOL_CONVERSION = YES; + CLANG_WARN_COMMA = YES; + CLANG_WARN_CONSTANT_CONVERSION = YES; + CLANG_WARN_DIRECT_OBJC_ISA_USAGE = YES_ERROR; + CLANG_WARN_DOCUMENTATION_COMMENTS = YES; + CLANG_WARN_EMPTY_BODY = YES; + CLANG_WARN_ENUM_CONVERSION = YES; + CLANG_WARN_INFINITE_RECURSION = YES; + CLANG_WARN_INT_CONVERSION = YES; + CLANG_WARN_NON_LITERAL_NULL_CONVERSION = YES; + CLANG_WARN_OBJC_LITERAL_CONVERSION = YES; + CLANG_WARN_OBJC_ROOT_CLASS = YES_ERROR; + CLANG_WARN_RANGE_LOOP_ANALYSIS = YES; + CLANG_WARN_STRICT_PROTOTYPES = YES; + CLANG_WARN_SUSPICIOUS_MOVE = YES; + CLANG_WARN_UNGUARDED_AVAILABILITY = YES_AGGRESSIVE; + CLANG_WARN_UNREACHABLE_CODE = YES; + CLANG_WARN__DUPLICATE_METHOD_MATCH = YES; + CODE_SIGN_IDENTITY = "iPhone Developer"; + COPY_PHASE_STRIP = NO; + DEBUG_INFORMATION_FORMAT = dwarf; + ENABLE_STRICT_OBJC_MSGSEND = YES; + ENABLE_TESTABILITY = YES; + GCC_C_LANGUAGE_STANDARD = gnu11; + GCC_DYNAMIC_NO_PIC = NO; + GCC_NO_COMMON_BLOCKS = YES; + GCC_OPTIMIZATION_LEVEL = 0; + GCC_PREPROCESSOR_DEFINITIONS = ( + "DEBUG=1", + "$(inherited)", + ); + GCC_WARN_64_TO_32_BIT_CONVERSION = YES; + GCC_WARN_ABOUT_RETURN_TYPE = YES_ERROR; + GCC_WARN_UNDECLARED_SELECTOR = YES; + GCC_WARN_UNINITIALIZED_AUTOS = YES_AGGRESSIVE; + GCC_WARN_UNUSED_FUNCTION = YES; + GCC_WARN_UNUSED_VARIABLE = YES; + IPHONEOS_DEPLOYMENT_TARGET = 11.0; + MTL_ENABLE_DEBUG_INFO = YES; + ONLY_ACTIVE_ARCH = YES; + SDKROOT = iphoneos; + SWIFT_ACTIVE_COMPILATION_CONDITIONS = DEBUG; + SWIFT_OPTIMIZATION_LEVEL = "-Onone"; + }; + name = Debug; + }; + 2C042E001F9C635D00979B56 /* Release */ = { + isa = XCBuildConfiguration; + buildSettings = { + ALWAYS_SEARCH_USER_PATHS = NO; + CLANG_ANALYZER_NONNULL = YES; + CLANG_ANALYZER_NUMBER_OBJECT_CONVERSION = YES_AGGRESSIVE; + CLANG_CXX_LANGUAGE_STANDARD = "gnu++14"; + CLANG_CXX_LIBRARY = "libc++"; + CLANG_ENABLE_MODULES = YES; + CLANG_ENABLE_OBJC_ARC = YES; + CLANG_WARN_BLOCK_CAPTURE_AUTORELEASING = YES; + CLANG_WARN_BOOL_CONVERSION = YES; + CLANG_WARN_COMMA = YES; + CLANG_WARN_CONSTANT_CONVERSION = YES; + CLANG_WARN_DIRECT_OBJC_ISA_USAGE = YES_ERROR; + CLANG_WARN_DOCUMENTATION_COMMENTS = YES; + CLANG_WARN_EMPTY_BODY = YES; + CLANG_WARN_ENUM_CONVERSION = YES; + CLANG_WARN_INFINITE_RECURSION = YES; + CLANG_WARN_INT_CONVERSION = YES; + CLANG_WARN_NON_LITERAL_NULL_CONVERSION = YES; + CLANG_WARN_OBJC_LITERAL_CONVERSION = YES; + CLANG_WARN_OBJC_ROOT_CLASS = YES_ERROR; + CLANG_WARN_RANGE_LOOP_ANALYSIS = YES; + CLANG_WARN_STRICT_PROTOTYPES = YES; + CLANG_WARN_SUSPICIOUS_MOVE = YES; + CLANG_WARN_UNGUARDED_AVAILABILITY = YES_AGGRESSIVE; + CLANG_WARN_UNREACHABLE_CODE = YES; + CLANG_WARN__DUPLICATE_METHOD_MATCH = YES; + CODE_SIGN_IDENTITY = "iPhone Developer"; + COPY_PHASE_STRIP = NO; + DEBUG_INFORMATION_FORMAT = "dwarf-with-dsym"; + ENABLE_NS_ASSERTIONS = NO; + ENABLE_STRICT_OBJC_MSGSEND = YES; + GCC_C_LANGUAGE_STANDARD = gnu11; + GCC_NO_COMMON_BLOCKS = YES; + GCC_WARN_64_TO_32_BIT_CONVERSION = YES; + GCC_WARN_ABOUT_RETURN_TYPE = YES_ERROR; + GCC_WARN_UNDECLARED_SELECTOR = YES; + GCC_WARN_UNINITIALIZED_AUTOS = YES_AGGRESSIVE; + GCC_WARN_UNUSED_FUNCTION = YES; + GCC_WARN_UNUSED_VARIABLE = YES; + IPHONEOS_DEPLOYMENT_TARGET = 11.0; + MTL_ENABLE_DEBUG_INFO = NO; + SDKROOT = iphoneos; + SWIFT_OPTIMIZATION_LEVEL = "-Owholemodule"; + VALIDATE_PRODUCT = YES; + }; + name = Release; + }; + 2C042E021F9C635D00979B56 /* Debug */ = { + isa = XCBuildConfiguration; + buildSettings = { + ASSETCATALOG_COMPILER_APPICON_NAME = AppIcon; + CODE_SIGN_STYLE = Automatic; + INFOPLIST_FILE = KBOHallOfFame/Info.plist; + LD_RUNPATH_SEARCH_PATHS = "$(inherited) @executable_path/Frameworks"; + PRODUCT_BUNDLE_IDENTIFIER = com.codershigh.KBOHallOfFame; + PRODUCT_NAME = "$(TARGET_NAME)"; + SWIFT_VERSION = 4.0; + TARGETED_DEVICE_FAMILY = "1,2"; + }; + name = Debug; + }; + 2C042E031F9C635D00979B56 /* Release */ = { + isa = XCBuildConfiguration; + buildSettings = { + ASSETCATALOG_COMPILER_APPICON_NAME = AppIcon; + CODE_SIGN_STYLE = Automatic; + INFOPLIST_FILE = KBOHallOfFame/Info.plist; + LD_RUNPATH_SEARCH_PATHS = "$(inherited) @executable_path/Frameworks"; + PRODUCT_BUNDLE_IDENTIFIER = com.codershigh.KBOHallOfFame; + PRODUCT_NAME = "$(TARGET_NAME)"; + SWIFT_VERSION = 4.0; + TARGETED_DEVICE_FAMILY = "1,2"; + }; + name = Release; + }; +/* End XCBuildConfiguration section */ + +/* Begin XCConfigurationList section */ + 2C042DEA1F9C635D00979B56 /* Build configuration list for PBXProject "KBOHallOfFame" */ = { + isa = XCConfigurationList; + buildConfigurations = ( + 2C042DFF1F9C635D00979B56 /* Debug */, + 2C042E001F9C635D00979B56 /* Release */, + ); + defaultConfigurationIsVisible = 0; + defaultConfigurationName = Release; + }; + 2C042E011F9C635D00979B56 /* Build configuration list for PBXNativeTarget "KBOHallOfFame" */ = { + isa = XCConfigurationList; + buildConfigurations = ( + 2C042E021F9C635D00979B56 /* Debug */, + 2C042E031F9C635D00979B56 /* Release */, + ); + defaultConfigurationIsVisible = 0; + defaultConfigurationName = Release; + }; +/* End XCConfigurationList section */ + }; + rootObject = 2C042DE71F9C635D00979B56 /* Project object */; +} diff --git "a/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/KBOHallOfFame_customCell/KBOHallOfFame.xcodeproj/project.xcworkspace/contents.xcworkspacedata" "b/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/KBOHallOfFame_customCell/KBOHallOfFame.xcodeproj/project.xcworkspace/contents.xcworkspacedata" new file mode 100644 index 0000000..9ef4953 --- /dev/null +++ "b/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/KBOHallOfFame_customCell/KBOHallOfFame.xcodeproj/project.xcworkspace/contents.xcworkspacedata" @@ -0,0 +1,7 @@ + + + + + diff --git "a/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/KBOHallOfFame_customCell/KBOHallOfFame/AppDelegate.swift" "b/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/KBOHallOfFame_customCell/KBOHallOfFame/AppDelegate.swift" new file mode 100644 index 0000000..f60b22e --- /dev/null +++ "b/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/KBOHallOfFame_customCell/KBOHallOfFame/AppDelegate.swift" @@ -0,0 +1,46 @@ +// +// AppDelegate.swift +// KBOHallOfFame +// +// Created by LingoStar on 2017. 10. 22.. +// Copyright © 2017년 LingoStar. All rights reserved. +// + +import UIKit + +@UIApplicationMain +class AppDelegate: UIResponder, UIApplicationDelegate { + + var window: UIWindow? + + + func application(_ application: UIApplication, didFinishLaunchingWithOptions launchOptions: [UIApplicationLaunchOptionsKey: Any]?) -> Bool { + // Override point for customization after application launch. + return true + } + + func applicationWillResignActive(_ application: UIApplication) { + // Sent when the application is about to move from active to inactive state. This can occur for certain types of temporary interruptions (such as an incoming phone call or SMS message) or when the user quits the application and it begins the transition to the background state. + // Use this method to pause ongoing tasks, disable timers, and invalidate graphics rendering callbacks. Games should use this method to pause the game. + } + + func applicationDidEnterBackground(_ application: UIApplication) { + // Use this method to release shared resources, save user data, invalidate timers, and store enough application state information to restore your application to its current state in case it is terminated later. + // If your application supports background execution, this method is called instead of applicationWillTerminate: when the user quits. + } + + func applicationWillEnterForeground(_ application: UIApplication) { + // Called as part of the transition from the background to the active state; here you can undo many of the changes made on entering the background. + } + + func applicationDidBecomeActive(_ application: UIApplication) { + // Restart any tasks that were paused (or not yet started) while the application was inactive. If the application was previously in the background, optionally refresh the user interface. + } + + func applicationWillTerminate(_ application: UIApplication) { + // Called when the application is about to terminate. Save data if appropriate. See also applicationDidEnterBackground:. + } + + +} + diff --git "a/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/KBOHallOfFame_customCell/KBOHallOfFame/Assets.xcassets/AppIcon.appiconset/Contents.json" "b/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/KBOHallOfFame_customCell/KBOHallOfFame/Assets.xcassets/AppIcon.appiconset/Contents.json" new file mode 100644 index 0000000..d8db8d6 --- /dev/null +++ "b/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/KBOHallOfFame_customCell/KBOHallOfFame/Assets.xcassets/AppIcon.appiconset/Contents.json" @@ -0,0 +1,98 @@ +{ + "images" : [ + { + "idiom" : "iphone", + "size" : "20x20", + "scale" : "2x" + }, + { + "idiom" : "iphone", + "size" : "20x20", + "scale" : "3x" + }, + { + "idiom" : "iphone", + "size" : "29x29", + "scale" : "2x" + }, + { + "idiom" : "iphone", + "size" : "29x29", + "scale" : "3x" + }, + { + "idiom" : "iphone", + "size" : "40x40", + "scale" : "2x" + }, + { + "idiom" : "iphone", + "size" : "40x40", + "scale" : "3x" + }, + { + "idiom" : "iphone", + "size" : "60x60", + "scale" : "2x" + }, + { + "idiom" : "iphone", + "size" : "60x60", + "scale" : "3x" + }, + { + "idiom" : "ipad", + "size" : "20x20", + "scale" : "1x" + }, + { + "idiom" : "ipad", + "size" : "20x20", + "scale" : "2x" + }, + { + "idiom" : "ipad", + "size" : "29x29", + "scale" : "1x" + }, + { + "idiom" : "ipad", + "size" : "29x29", + "scale" : "2x" + }, + { + "idiom" : "ipad", + "size" : "40x40", + "scale" : "1x" + }, + { + "idiom" : "ipad", + "size" : "40x40", + "scale" : "2x" + }, + { + "idiom" : "ipad", + "size" : "76x76", + "scale" : "1x" + }, + { + "idiom" : "ipad", + "size" : "76x76", + "scale" : "2x" + }, + { + "idiom" : "ipad", + "size" : "83.5x83.5", + "scale" : "2x" + }, + { + "idiom" : "ios-marketing", + "size" : "1024x1024", + "scale" : "1x" + } + ], + "info" : { + "version" : 1, + "author" : "xcode" + } +} \ No newline at end of file diff --git "a/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/KBOHallOfFame_customCell/KBOHallOfFame/Assets.xcassets/Contents.json" "b/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/KBOHallOfFame_customCell/KBOHallOfFame/Assets.xcassets/Contents.json" new file mode 100644 index 0000000..da4a164 --- /dev/null +++ "b/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/KBOHallOfFame_customCell/KBOHallOfFame/Assets.xcassets/Contents.json" @@ -0,0 +1,6 @@ +{ + "info" : { + "version" : 1, + "author" : "xcode" + } +} \ No newline at end of file diff --git "a/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/KBOHallOfFame_customCell/KBOHallOfFame/Assets.xcassets/haetae_tigers.imageset/Contents.json" "b/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/KBOHallOfFame_customCell/KBOHallOfFame/Assets.xcassets/haetae_tigers.imageset/Contents.json" new file mode 100644 index 0000000..3a3a0d0 --- /dev/null +++ "b/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/KBOHallOfFame_customCell/KBOHallOfFame/Assets.xcassets/haetae_tigers.imageset/Contents.json" @@ -0,0 +1,21 @@ +{ + "images" : [ + { + "idiom" : "universal", + "scale" : "1x" + }, + { + "idiom" : "universal", + "filename" : "haetae_tigers.png", + "scale" : "2x" + }, + { + "idiom" : "universal", + "scale" : "3x" + } + ], + "info" : { + "version" : 1, + "author" : "xcode" + } +} \ No newline at end of file diff --git "a/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/KBOHallOfFame_customCell/KBOHallOfFame/Assets.xcassets/haetae_tigers.imageset/haetae_tigers.png" "b/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/KBOHallOfFame_customCell/KBOHallOfFame/Assets.xcassets/haetae_tigers.imageset/haetae_tigers.png" new file mode 100644 index 0000000..b4df90b Binary files /dev/null and "b/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/KBOHallOfFame_customCell/KBOHallOfFame/Assets.xcassets/haetae_tigers.imageset/haetae_tigers.png" differ diff --git "a/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/KBOHallOfFame_customCell/KBOHallOfFame/Assets.xcassets/leejongbum.imageset/Contents.json" "b/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/KBOHallOfFame_customCell/KBOHallOfFame/Assets.xcassets/leejongbum.imageset/Contents.json" new file mode 100644 index 0000000..e62c8ba --- /dev/null +++ "b/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/KBOHallOfFame_customCell/KBOHallOfFame/Assets.xcassets/leejongbum.imageset/Contents.json" @@ -0,0 +1,21 @@ +{ + "images" : [ + { + "idiom" : "universal", + "scale" : "1x" + }, + { + "idiom" : "universal", + "filename" : "leejongbum.png", + "scale" : "2x" + }, + { + "idiom" : "universal", + "scale" : "3x" + } + ], + "info" : { + "version" : 1, + "author" : "xcode" + } +} \ No newline at end of file diff --git "a/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/KBOHallOfFame_customCell/KBOHallOfFame/Assets.xcassets/leejongbum.imageset/leejongbum.png" "b/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/KBOHallOfFame_customCell/KBOHallOfFame/Assets.xcassets/leejongbum.imageset/leejongbum.png" new file mode 100644 index 0000000..2406941 Binary files /dev/null and "b/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/KBOHallOfFame_customCell/KBOHallOfFame/Assets.xcassets/leejongbum.imageset/leejongbum.png" differ diff --git "a/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/KBOHallOfFame_customCell/KBOHallOfFame/Base.lproj/LaunchScreen.storyboard" "b/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/KBOHallOfFame_customCell/KBOHallOfFame/Base.lproj/LaunchScreen.storyboard" new file mode 100644 index 0000000..f83f6fd --- /dev/null +++ "b/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/KBOHallOfFame_customCell/KBOHallOfFame/Base.lproj/LaunchScreen.storyboard" @@ -0,0 +1,25 @@ + + + + + + + + + + + + + + + + + + + + + + + + + diff --git "a/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/KBOHallOfFame_customCell/KBOHallOfFame/Base.lproj/Main.storyboard" "b/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/KBOHallOfFame_customCell/KBOHallOfFame/Base.lproj/Main.storyboard" new file mode 100644 index 0000000..e442a22 --- /dev/null +++ "b/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/KBOHallOfFame_customCell/KBOHallOfFame/Base.lproj/Main.storyboard" @@ -0,0 +1,144 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + diff --git "a/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/KBOHallOfFame_customCell/KBOHallOfFame/HitterTableViewCell.swift" "b/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/KBOHallOfFame_customCell/KBOHallOfFame/HitterTableViewCell.swift" new file mode 100644 index 0000000..a123451 --- /dev/null +++ "b/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/KBOHallOfFame_customCell/KBOHallOfFame/HitterTableViewCell.swift" @@ -0,0 +1,42 @@ +// +// HitterTableViewCell.swift +// KBOHallOfFame +// +// Created by LingoStar on 2017. 10. 31.. +// Copyright © 2017년 LingoStar. All rights reserved. +// + +import UIKit + +class HitterTableViewCell: UITableViewCell { + + var hitter:Hitter? { didSet { + self.profileImageView?.image = hitter!.profileImage + self.nameLabel?.text = hitter!.name + self.emblemImageView?.image = hitter!.team.emblem + self.averageLabel.text = String(hitter!.average) + }} + + + @IBOutlet weak var profileImageView: UIImageView? + @IBOutlet weak var nameLabel: UILabel? + @IBOutlet weak var averageLabel: UILabel! + + @IBOutlet weak var yearLabel: UILabel? + @IBOutlet weak var emblemImageView: UIImageView? + @IBOutlet weak var teamNameLabel: UILabel? + + override func awakeFromNib() { + super.awakeFromNib() + // Initialization code + } + + + + override func setSelected(_ selected: Bool, animated: Bool) { + super.setSelected(selected, animated: animated) + + // Configure the view for the selected state + } + +} diff --git "a/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/KBOHallOfFame_customCell/KBOHallOfFame/Info.plist" "b/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/KBOHallOfFame_customCell/KBOHallOfFame/Info.plist" new file mode 100644 index 0000000..16be3b6 --- /dev/null +++ "b/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/KBOHallOfFame_customCell/KBOHallOfFame/Info.plist" @@ -0,0 +1,45 @@ + + + + + CFBundleDevelopmentRegion + $(DEVELOPMENT_LANGUAGE) + CFBundleExecutable + $(EXECUTABLE_NAME) + CFBundleIdentifier + $(PRODUCT_BUNDLE_IDENTIFIER) + CFBundleInfoDictionaryVersion + 6.0 + CFBundleName + $(PRODUCT_NAME) + CFBundlePackageType + APPL + CFBundleShortVersionString + 1.0 + CFBundleVersion + 1 + LSRequiresIPhoneOS + + UILaunchStoryboardName + LaunchScreen + UIMainStoryboardFile + Main + UIRequiredDeviceCapabilities + + armv7 + + UISupportedInterfaceOrientations + + UIInterfaceOrientationPortrait + UIInterfaceOrientationLandscapeLeft + UIInterfaceOrientationLandscapeRight + + UISupportedInterfaceOrientations~ipad + + UIInterfaceOrientationPortrait + UIInterfaceOrientationPortraitUpsideDown + UIInterfaceOrientationLandscapeLeft + UIInterfaceOrientationLandscapeRight + + + diff --git "a/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/KBOHallOfFame_customCell/KBOHallOfFame/KBOTableViewController.swift" "b/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/KBOHallOfFame_customCell/KBOHallOfFame/KBOTableViewController.swift" new file mode 100644 index 0000000..3d58c5d --- /dev/null +++ "b/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/KBOHallOfFame_customCell/KBOHallOfFame/KBOTableViewController.swift" @@ -0,0 +1,160 @@ +// +// KBOTableViewController.swift +// KBOHallOfFame +// +// Created by LingoStar on 2017. 10. 22.. +// Copyright © 2017년 LingoStar. All rights reserved. +// + +import UIKit + +struct Hitter { + let name:String + let team:Team + let average:Double + let year:Int + var profileImageName:String? + + var profileImage:UIImage? { get{ + if let _profileImage = self.profileImageName { + return UIImage(named:_profileImage)! + } else { + return nil + } + + }} +} + +enum Team { + case Haetae + case MBC + case Samsung + case Nexen + case NC + case LG + case Lotte + + var emblem:UIImage? { get{ //Enum은 Stored Property를 가질 수 없지만 Computed Property는 가질 수 있다. + switch self { + case .Haetae: + return UIImage(named:"haetae_tigers")! + default: + return nil + } + }} +} + +class KBOTableViewController: UITableViewController { + + @IBOutlet weak var averageField: UILabel! + + func dummyData() -> [Hitter] { + let baek_1982 = Hitter(name: "백인천", team:.MBC, average: 0.412, year: 1982, profileImageName:nil) + let lee_1994 = Hitter(name: "이종범", team:.Haetae, average: 0.393, year: 1994, profileImageName:"leejongbum") + let jang_1987 = Hitter(name: "장효조", team:.Samsung, average: 0.387, year: 1987, profileImageName:nil) + let tames_2015 = Hitter(name: "테임즈", team:.NC, average: 0.381, year: 2015, profileImageName:nil) + let jang_1985 = Hitter(name: "장효조", team:.Samsung, average: 0.373, year: 1985, profileImageName:nil) + let ma_1999 = Hitter(name: "마해영", team:.Lotte, average: 0.372, year: 1999, profileImageName:nil) + let park_2009 = Hitter(name: "박용택", team:.LG, average: 0.372, year: 2009, profileImageName:nil) + let hong_2009 = Hitter(name: "홍성흔", team:.Lotte, average: 0.371, year: 2009, profileImageName:nil) + let seo_2014 = Hitter(name: "서건창", team:.Nexen, average: 0.370, year: 2014, profileImageName:nil) + let jang_1983 = Hitter(name: "장효조", team:.Samsung, average: 0.369, year: 1983, profileImageName:nil) + + return [baek_1982, lee_1994, jang_1987, tames_2015, jang_1985, ma_1999, park_2009, hong_2009, seo_2014, jang_1983] + } + + var kboHallOfFame:[Hitter] = [] + + override func viewDidLoad() { + super.viewDidLoad() + + kboHallOfFame = dummyData().sorted(by: {$0.year > $1.year}) + + let average = kboHallOfFame.reduce(0, {$0 + $1.average}) / Double(kboHallOfFame.count) + averageField.text = "타율평균 : " + String(average) + // Uncomment the following line to preserve selection between presentations + // self.clearsSelectionOnViewWillAppear = false + + // Uncomment the following line to display an Edit button in the navigation bar for this view controller. + // self.navigationItem.rightBarButtonItem = self.editButtonItem + + //self.tableView.register(HitterTableViewCell.self, forCellReuseIdentifier: "KBOCell") + } + + override func didReceiveMemoryWarning() { + super.didReceiveMemoryWarning() + // Dispose of any resources that can be recreated. + } + + // MARK: - Table view data source + + override func numberOfSections(in tableView: UITableView) -> Int { + // #warning Incomplete implementation, return the number of sections + return 1 + } + + override func tableView(_ tableView: UITableView, numberOfRowsInSection section: Int) -> Int { + // #warning Incomplete implementation, return the number of rows + return kboHallOfFame.count + } + + + override func tableView(_ tableView: UITableView, cellForRowAt indexPath: IndexPath) -> UITableViewCell { + let cell = tableView.dequeueReusableCell(withIdentifier: "KBOCell", for: indexPath) as! HitterTableViewCell + let currentHitter = kboHallOfFame[indexPath.row] + // Configure the cell... + //cell.textLabel?.text = hitter.name + " " + String(describing: hitter.team) + + //cell.detailTextLabel?.text = String(hitter.average) + " ( " + String(hitter.year) + " )" + cell.hitter = currentHitter + + return cell + } + + + /* + // Override to support conditional editing of the table view. + override func tableView(_ tableView: UITableView, canEditRowAt indexPath: IndexPath) -> Bool { + // Return false if you do not want the specified item to be editable. + return true + } + */ + + /* + // Override to support editing the table view. + override func tableView(_ tableView: UITableView, commit editingStyle: UITableViewCellEditingStyle, forRowAt indexPath: IndexPath) { + if editingStyle == .delete { + // Delete the row from the data source + tableView.deleteRows(at: [indexPath], with: .fade) + } else if editingStyle == .insert { + // Create a new instance of the appropriate class, insert it into the array, and add a new row to the table view + } + } + */ + + /* + // Override to support rearranging the table view. + override func tableView(_ tableView: UITableView, moveRowAt fromIndexPath: IndexPath, to: IndexPath) { + + } + */ + + /* + // Override to support conditional rearranging of the table view. + override func tableView(_ tableView: UITableView, canMoveRowAt indexPath: IndexPath) -> Bool { + // Return false if you do not want the item to be re-orderable. + return true + } + */ + + /* + // MARK: - Navigation + + // In a storyboard-based application, you will often want to do a little preparation before navigation + override func prepare(for segue: UIStoryboardSegue, sender: Any?) { + // Get the new view controller using segue.destinationViewController. + // Pass the selected object to the new view controller. + } + */ + +} diff --git "a/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/KBOHallOfFame_customCell/KBOHallOfFame/ViewController.swift" "b/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/KBOHallOfFame_customCell/KBOHallOfFame/ViewController.swift" new file mode 100644 index 0000000..c90c441 --- /dev/null +++ "b/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/KBOHallOfFame_customCell/KBOHallOfFame/ViewController.swift" @@ -0,0 +1,25 @@ +// +// ViewController.swift +// KBOHallOfFame +// +// Created by LingoStar on 2017. 10. 22.. +// Copyright © 2017년 LingoStar. All rights reserved. +// + +import UIKit + +class ViewController: UIViewController { + + override func viewDidLoad() { + super.viewDidLoad() + // Do any additional setup after loading the view, typically from a nib. + } + + override func didReceiveMemoryWarning() { + super.didReceiveMemoryWarning() + // Dispose of any resources that can be recreated. + } + + +} + diff --git "a/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/MoneyConverter/MoneyConverter.xcodeproj/project.pbxproj" "b/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/MoneyConverter/MoneyConverter.xcodeproj/project.pbxproj" new file mode 100644 index 0000000..60ea893 --- /dev/null +++ "b/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/MoneyConverter/MoneyConverter.xcodeproj/project.pbxproj" @@ -0,0 +1,561 @@ +// !$*UTF8*$! +{ + archiveVersion = 1; + classes = { + }; + objectVersion = 48; + objects = { + +/* Begin PBXBuildFile section */ + AE5100051F9DD9D0003F7477 /* Money.swift in Sources */ = {isa = PBXBuildFile; fileRef = AE5100041F9DD9D0003F7477 /* Money.swift */; }; + AE51FFD71F9DD116003F7477 /* AppDelegate.swift in Sources */ = {isa = PBXBuildFile; fileRef = AE51FFD61F9DD116003F7477 /* AppDelegate.swift */; }; + AE51FFD91F9DD116003F7477 /* ViewController.swift in Sources */ = {isa = PBXBuildFile; fileRef = AE51FFD81F9DD116003F7477 /* ViewController.swift */; }; + AE51FFDC1F9DD116003F7477 /* Main.storyboard in Resources */ = {isa = PBXBuildFile; fileRef = AE51FFDA1F9DD116003F7477 /* Main.storyboard */; }; + AE51FFDE1F9DD116003F7477 /* Assets.xcassets in Resources */ = {isa = PBXBuildFile; fileRef = AE51FFDD1F9DD116003F7477 /* Assets.xcassets */; }; + AE51FFE11F9DD116003F7477 /* LaunchScreen.storyboard in Resources */ = {isa = PBXBuildFile; fileRef = AE51FFDF1F9DD116003F7477 /* LaunchScreen.storyboard */; }; + AE51FFEC1F9DD117003F7477 /* MoneyConverterTests.swift in Sources */ = {isa = PBXBuildFile; fileRef = AE51FFEB1F9DD117003F7477 /* MoneyConverterTests.swift */; }; + AE51FFF71F9DD117003F7477 /* MoneyConverterUITests.swift in Sources */ = {isa = PBXBuildFile; fileRef = AE51FFF61F9DD117003F7477 /* MoneyConverterUITests.swift */; }; +/* End PBXBuildFile section */ + +/* Begin PBXContainerItemProxy section */ + AE51FFE81F9DD117003F7477 /* PBXContainerItemProxy */ = { + isa = PBXContainerItemProxy; + containerPortal = AE51FFCB1F9DD116003F7477 /* Project object */; + proxyType = 1; + remoteGlobalIDString = AE51FFD21F9DD116003F7477; + remoteInfo = MoneyConverter; + }; + AE51FFF31F9DD117003F7477 /* PBXContainerItemProxy */ = { + isa = PBXContainerItemProxy; + containerPortal = AE51FFCB1F9DD116003F7477 /* Project object */; + proxyType = 1; + remoteGlobalIDString = AE51FFD21F9DD116003F7477; + remoteInfo = MoneyConverter; + }; +/* End PBXContainerItemProxy section */ + +/* Begin PBXFileReference section */ + AE5100041F9DD9D0003F7477 /* Money.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = Money.swift; sourceTree = ""; }; + AE51FFD31F9DD116003F7477 /* MoneyConverter.app */ = {isa = PBXFileReference; explicitFileType = wrapper.application; includeInIndex = 0; path = MoneyConverter.app; sourceTree = BUILT_PRODUCTS_DIR; }; + AE51FFD61F9DD116003F7477 /* AppDelegate.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = AppDelegate.swift; sourceTree = ""; }; + AE51FFD81F9DD116003F7477 /* ViewController.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = ViewController.swift; sourceTree = ""; }; + AE51FFDB1F9DD116003F7477 /* Base */ = {isa = PBXFileReference; lastKnownFileType = file.storyboard; name = Base; path = Base.lproj/Main.storyboard; sourceTree = ""; }; + AE51FFDD1F9DD116003F7477 /* Assets.xcassets */ = {isa = PBXFileReference; lastKnownFileType = folder.assetcatalog; path = Assets.xcassets; sourceTree = ""; }; + AE51FFE01F9DD116003F7477 /* Base */ = {isa = PBXFileReference; lastKnownFileType = file.storyboard; name = Base; path = Base.lproj/LaunchScreen.storyboard; sourceTree = ""; }; + AE51FFE21F9DD116003F7477 /* Info.plist */ = {isa = PBXFileReference; lastKnownFileType = text.plist.xml; path = Info.plist; sourceTree = ""; }; + AE51FFE71F9DD117003F7477 /* MoneyConverterTests.xctest */ = {isa = PBXFileReference; explicitFileType = wrapper.cfbundle; includeInIndex = 0; path = MoneyConverterTests.xctest; sourceTree = BUILT_PRODUCTS_DIR; }; + AE51FFEB1F9DD117003F7477 /* MoneyConverterTests.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = MoneyConverterTests.swift; sourceTree = ""; }; + AE51FFED1F9DD117003F7477 /* Info.plist */ = {isa = PBXFileReference; lastKnownFileType = text.plist.xml; path = Info.plist; sourceTree = ""; }; + AE51FFF21F9DD117003F7477 /* MoneyConverterUITests.xctest */ = {isa = PBXFileReference; explicitFileType = wrapper.cfbundle; includeInIndex = 0; path = MoneyConverterUITests.xctest; sourceTree = BUILT_PRODUCTS_DIR; }; + AE51FFF61F9DD117003F7477 /* MoneyConverterUITests.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = MoneyConverterUITests.swift; sourceTree = ""; }; + AE51FFF81F9DD117003F7477 /* Info.plist */ = {isa = PBXFileReference; lastKnownFileType = text.plist.xml; path = Info.plist; sourceTree = ""; }; +/* End PBXFileReference section */ + +/* Begin PBXFrameworksBuildPhase section */ + AE51FFD01F9DD116003F7477 /* Frameworks */ = { + isa = PBXFrameworksBuildPhase; + buildActionMask = 2147483647; + files = ( + ); + runOnlyForDeploymentPostprocessing = 0; + }; + AE51FFE41F9DD117003F7477 /* Frameworks */ = { + isa = PBXFrameworksBuildPhase; + buildActionMask = 2147483647; + files = ( + ); + runOnlyForDeploymentPostprocessing = 0; + }; + AE51FFEF1F9DD117003F7477 /* Frameworks */ = { + isa = PBXFrameworksBuildPhase; + buildActionMask = 2147483647; + files = ( + ); + runOnlyForDeploymentPostprocessing = 0; + }; +/* End PBXFrameworksBuildPhase section */ + +/* Begin PBXGroup section */ + AE51FFCA1F9DD116003F7477 = { + isa = PBXGroup; + children = ( + AE51FFD51F9DD116003F7477 /* MoneyConverter */, + AE51FFEA1F9DD117003F7477 /* MoneyConverterTests */, + AE51FFF51F9DD117003F7477 /* MoneyConverterUITests */, + AE51FFD41F9DD116003F7477 /* Products */, + ); + sourceTree = ""; + }; + AE51FFD41F9DD116003F7477 /* Products */ = { + isa = PBXGroup; + children = ( + AE51FFD31F9DD116003F7477 /* MoneyConverter.app */, + AE51FFE71F9DD117003F7477 /* MoneyConverterTests.xctest */, + AE51FFF21F9DD117003F7477 /* MoneyConverterUITests.xctest */, + ); + name = Products; + sourceTree = ""; + }; + AE51FFD51F9DD116003F7477 /* MoneyConverter */ = { + isa = PBXGroup; + children = ( + AE51FFD61F9DD116003F7477 /* AppDelegate.swift */, + AE51FFD81F9DD116003F7477 /* ViewController.swift */, + AE5100041F9DD9D0003F7477 /* Money.swift */, + AE51FFDA1F9DD116003F7477 /* Main.storyboard */, + AE51FFDD1F9DD116003F7477 /* Assets.xcassets */, + AE51FFDF1F9DD116003F7477 /* LaunchScreen.storyboard */, + AE51FFE21F9DD116003F7477 /* Info.plist */, + ); + path = MoneyConverter; + sourceTree = ""; + }; + AE51FFEA1F9DD117003F7477 /* MoneyConverterTests */ = { + isa = PBXGroup; + children = ( + AE51FFEB1F9DD117003F7477 /* MoneyConverterTests.swift */, + AE51FFED1F9DD117003F7477 /* Info.plist */, + ); + path = MoneyConverterTests; + sourceTree = ""; + }; + AE51FFF51F9DD117003F7477 /* MoneyConverterUITests */ = { + isa = PBXGroup; + children = ( + AE51FFF61F9DD117003F7477 /* MoneyConverterUITests.swift */, + AE51FFF81F9DD117003F7477 /* Info.plist */, + ); + path = MoneyConverterUITests; + sourceTree = ""; + }; +/* End PBXGroup section */ + +/* Begin PBXNativeTarget section */ + AE51FFD21F9DD116003F7477 /* MoneyConverter */ = { + isa = PBXNativeTarget; + buildConfigurationList = AE51FFFB1F9DD117003F7477 /* Build configuration list for PBXNativeTarget "MoneyConverter" */; + buildPhases = ( + AE51FFCF1F9DD116003F7477 /* Sources */, + AE51FFD01F9DD116003F7477 /* Frameworks */, + AE51FFD11F9DD116003F7477 /* Resources */, + ); + buildRules = ( + ); + dependencies = ( + ); + name = MoneyConverter; + productName = MoneyConverter; + productReference = AE51FFD31F9DD116003F7477 /* MoneyConverter.app */; + productType = "com.apple.product-type.application"; + }; + AE51FFE61F9DD117003F7477 /* MoneyConverterTests */ = { + isa = PBXNativeTarget; + buildConfigurationList = AE51FFFE1F9DD117003F7477 /* Build configuration list for PBXNativeTarget "MoneyConverterTests" */; + buildPhases = ( + AE51FFE31F9DD117003F7477 /* Sources */, + AE51FFE41F9DD117003F7477 /* Frameworks */, + AE51FFE51F9DD117003F7477 /* Resources */, + ); + buildRules = ( + ); + dependencies = ( + AE51FFE91F9DD117003F7477 /* PBXTargetDependency */, + ); + name = MoneyConverterTests; + productName = MoneyConverterTests; + productReference = AE51FFE71F9DD117003F7477 /* MoneyConverterTests.xctest */; + productType = "com.apple.product-type.bundle.unit-test"; + }; + AE51FFF11F9DD117003F7477 /* MoneyConverterUITests */ = { + isa = PBXNativeTarget; + buildConfigurationList = AE5100011F9DD117003F7477 /* Build configuration list for PBXNativeTarget "MoneyConverterUITests" */; + buildPhases = ( + AE51FFEE1F9DD117003F7477 /* Sources */, + AE51FFEF1F9DD117003F7477 /* Frameworks */, + AE51FFF01F9DD117003F7477 /* Resources */, + ); + buildRules = ( + ); + dependencies = ( + AE51FFF41F9DD117003F7477 /* PBXTargetDependency */, + ); + name = MoneyConverterUITests; + productName = MoneyConverterUITests; + productReference = AE51FFF21F9DD117003F7477 /* MoneyConverterUITests.xctest */; + productType = "com.apple.product-type.bundle.ui-testing"; + }; +/* End PBXNativeTarget section */ + +/* Begin PBXProject section */ + AE51FFCB1F9DD116003F7477 /* Project object */ = { + isa = PBXProject; + attributes = { + LastSwiftUpdateCheck = 0900; + LastUpgradeCheck = 0900; + ORGANIZATIONNAME = "황도증"; + TargetAttributes = { + AE51FFD21F9DD116003F7477 = { + CreatedOnToolsVersion = 9.0.1; + ProvisioningStyle = Automatic; + }; + AE51FFE61F9DD117003F7477 = { + CreatedOnToolsVersion = 9.0.1; + ProvisioningStyle = Automatic; + TestTargetID = AE51FFD21F9DD116003F7477; + }; + AE51FFF11F9DD117003F7477 = { + CreatedOnToolsVersion = 9.0.1; + ProvisioningStyle = Automatic; + TestTargetID = AE51FFD21F9DD116003F7477; + }; + }; + }; + buildConfigurationList = AE51FFCE1F9DD116003F7477 /* Build configuration list for PBXProject "MoneyConverter" */; + compatibilityVersion = "Xcode 8.0"; + developmentRegion = en; + hasScannedForEncodings = 0; + knownRegions = ( + en, + Base, + ); + mainGroup = AE51FFCA1F9DD116003F7477; + productRefGroup = AE51FFD41F9DD116003F7477 /* Products */; + projectDirPath = ""; + projectRoot = ""; + targets = ( + AE51FFD21F9DD116003F7477 /* MoneyConverter */, + AE51FFE61F9DD117003F7477 /* MoneyConverterTests */, + AE51FFF11F9DD117003F7477 /* MoneyConverterUITests */, + ); + }; +/* End PBXProject section */ + +/* Begin PBXResourcesBuildPhase section */ + AE51FFD11F9DD116003F7477 /* Resources */ = { + isa = PBXResourcesBuildPhase; + buildActionMask = 2147483647; + files = ( + AE51FFE11F9DD116003F7477 /* LaunchScreen.storyboard in Resources */, + AE51FFDE1F9DD116003F7477 /* Assets.xcassets in Resources */, + AE51FFDC1F9DD116003F7477 /* Main.storyboard in Resources */, + ); + runOnlyForDeploymentPostprocessing = 0; + }; + AE51FFE51F9DD117003F7477 /* Resources */ = { + isa = PBXResourcesBuildPhase; + buildActionMask = 2147483647; + files = ( + ); + runOnlyForDeploymentPostprocessing = 0; + }; + AE51FFF01F9DD117003F7477 /* Resources */ = { + isa = PBXResourcesBuildPhase; + buildActionMask = 2147483647; + files = ( + ); + runOnlyForDeploymentPostprocessing = 0; + }; +/* End PBXResourcesBuildPhase section */ + +/* Begin PBXSourcesBuildPhase section */ + AE51FFCF1F9DD116003F7477 /* Sources */ = { + isa = PBXSourcesBuildPhase; + buildActionMask = 2147483647; + files = ( + AE5100051F9DD9D0003F7477 /* Money.swift in Sources */, + AE51FFD91F9DD116003F7477 /* ViewController.swift in Sources */, + AE51FFD71F9DD116003F7477 /* AppDelegate.swift in Sources */, + ); + runOnlyForDeploymentPostprocessing = 0; + }; + AE51FFE31F9DD117003F7477 /* Sources */ = { + isa = PBXSourcesBuildPhase; + buildActionMask = 2147483647; + files = ( + AE51FFEC1F9DD117003F7477 /* MoneyConverterTests.swift in Sources */, + ); + runOnlyForDeploymentPostprocessing = 0; + }; + AE51FFEE1F9DD117003F7477 /* Sources */ = { + isa = PBXSourcesBuildPhase; + buildActionMask = 2147483647; + files = ( + AE51FFF71F9DD117003F7477 /* MoneyConverterUITests.swift in Sources */, + ); + runOnlyForDeploymentPostprocessing = 0; + }; +/* End PBXSourcesBuildPhase section */ + +/* Begin PBXTargetDependency section */ + AE51FFE91F9DD117003F7477 /* PBXTargetDependency */ = { + isa = PBXTargetDependency; + target = AE51FFD21F9DD116003F7477 /* MoneyConverter */; + targetProxy = AE51FFE81F9DD117003F7477 /* PBXContainerItemProxy */; + }; + AE51FFF41F9DD117003F7477 /* PBXTargetDependency */ = { + isa = PBXTargetDependency; + target = AE51FFD21F9DD116003F7477 /* MoneyConverter */; + targetProxy = AE51FFF31F9DD117003F7477 /* PBXContainerItemProxy */; + }; +/* End PBXTargetDependency section */ + +/* Begin PBXVariantGroup section */ + AE51FFDA1F9DD116003F7477 /* Main.storyboard */ = { + isa = PBXVariantGroup; + children = ( + AE51FFDB1F9DD116003F7477 /* Base */, + ); + name = Main.storyboard; + sourceTree = ""; + }; + AE51FFDF1F9DD116003F7477 /* LaunchScreen.storyboard */ = { + isa = PBXVariantGroup; + children = ( + AE51FFE01F9DD116003F7477 /* Base */, + ); + name = LaunchScreen.storyboard; + sourceTree = ""; + }; +/* End PBXVariantGroup section */ + +/* Begin XCBuildConfiguration section */ + AE5100001F9DD117003F7477 /* Release */ = { + isa = XCBuildConfiguration; + buildSettings = { + ALWAYS_EMBED_SWIFT_STANDARD_LIBRARIES = YES; + BUNDLE_LOADER = "$(TEST_HOST)"; + CODE_SIGN_STYLE = Automatic; + INFOPLIST_FILE = MoneyConverterTests/Info.plist; + LD_RUNPATH_SEARCH_PATHS = "$(inherited) @executable_path/Frameworks @loader_path/Frameworks"; + PRODUCT_BUNDLE_IDENTIFIER = "--------.MoneyConverterTests"; + PRODUCT_NAME = "$(TARGET_NAME)"; + SWIFT_VERSION = 4.0; + TARGETED_DEVICE_FAMILY = "1,2"; + TEST_HOST = "$(BUILT_PRODUCTS_DIR)/MoneyConverter.app/MoneyConverter"; + }; + name = Release; + }; + AE5100021F9DD117003F7477 /* Debug */ = { + isa = XCBuildConfiguration; + buildSettings = { + ALWAYS_EMBED_SWIFT_STANDARD_LIBRARIES = YES; + CODE_SIGN_STYLE = Automatic; + INFOPLIST_FILE = MoneyConverterUITests/Info.plist; + LD_RUNPATH_SEARCH_PATHS = "$(inherited) @executable_path/Frameworks @loader_path/Frameworks"; + PRODUCT_BUNDLE_IDENTIFIER = "--------.MoneyConverterUITests"; + PRODUCT_NAME = "$(TARGET_NAME)"; + SWIFT_VERSION = 4.0; + TARGETED_DEVICE_FAMILY = "1,2"; + TEST_TARGET_NAME = MoneyConverter; + }; + name = Debug; + }; + AE5100031F9DD117003F7477 /* Release */ = { + isa = XCBuildConfiguration; + buildSettings = { + ALWAYS_EMBED_SWIFT_STANDARD_LIBRARIES = YES; + CODE_SIGN_STYLE = Automatic; + INFOPLIST_FILE = MoneyConverterUITests/Info.plist; + LD_RUNPATH_SEARCH_PATHS = "$(inherited) @executable_path/Frameworks @loader_path/Frameworks"; + PRODUCT_BUNDLE_IDENTIFIER = "--------.MoneyConverterUITests"; + PRODUCT_NAME = "$(TARGET_NAME)"; + SWIFT_VERSION = 4.0; + TARGETED_DEVICE_FAMILY = "1,2"; + TEST_TARGET_NAME = MoneyConverter; + }; + name = Release; + }; + AE51FFF91F9DD117003F7477 /* Debug */ = { + isa = XCBuildConfiguration; + buildSettings = { + ALWAYS_SEARCH_USER_PATHS = NO; + CLANG_ANALYZER_NONNULL = YES; + CLANG_ANALYZER_NUMBER_OBJECT_CONVERSION = YES_AGGRESSIVE; + CLANG_CXX_LANGUAGE_STANDARD = "gnu++14"; + CLANG_CXX_LIBRARY = "libc++"; + CLANG_ENABLE_MODULES = YES; + CLANG_ENABLE_OBJC_ARC = YES; + CLANG_WARN_BLOCK_CAPTURE_AUTORELEASING = YES; + CLANG_WARN_BOOL_CONVERSION = YES; + CLANG_WARN_COMMA = YES; + CLANG_WARN_CONSTANT_CONVERSION = YES; + CLANG_WARN_DIRECT_OBJC_ISA_USAGE = YES_ERROR; + CLANG_WARN_DOCUMENTATION_COMMENTS = YES; + CLANG_WARN_EMPTY_BODY = YES; + CLANG_WARN_ENUM_CONVERSION = YES; + CLANG_WARN_INFINITE_RECURSION = YES; + CLANG_WARN_INT_CONVERSION = YES; + CLANG_WARN_NON_LITERAL_NULL_CONVERSION = YES; + CLANG_WARN_OBJC_LITERAL_CONVERSION = YES; + CLANG_WARN_OBJC_ROOT_CLASS = YES_ERROR; + CLANG_WARN_RANGE_LOOP_ANALYSIS = YES; + CLANG_WARN_STRICT_PROTOTYPES = YES; + CLANG_WARN_SUSPICIOUS_MOVE = YES; + CLANG_WARN_UNGUARDED_AVAILABILITY = YES_AGGRESSIVE; + CLANG_WARN_UNREACHABLE_CODE = YES; + CLANG_WARN__DUPLICATE_METHOD_MATCH = YES; + CODE_SIGN_IDENTITY = "iPhone Developer"; + COPY_PHASE_STRIP = NO; + DEBUG_INFORMATION_FORMAT = dwarf; + ENABLE_STRICT_OBJC_MSGSEND = YES; + ENABLE_TESTABILITY = YES; + GCC_C_LANGUAGE_STANDARD = gnu11; + GCC_DYNAMIC_NO_PIC = NO; + GCC_NO_COMMON_BLOCKS = YES; + GCC_OPTIMIZATION_LEVEL = 0; + GCC_PREPROCESSOR_DEFINITIONS = ( + "DEBUG=1", + "$(inherited)", + ); + GCC_WARN_64_TO_32_BIT_CONVERSION = YES; + GCC_WARN_ABOUT_RETURN_TYPE = YES_ERROR; + GCC_WARN_UNDECLARED_SELECTOR = YES; + GCC_WARN_UNINITIALIZED_AUTOS = YES_AGGRESSIVE; + GCC_WARN_UNUSED_FUNCTION = YES; + GCC_WARN_UNUSED_VARIABLE = YES; + IPHONEOS_DEPLOYMENT_TARGET = 11.0; + MTL_ENABLE_DEBUG_INFO = YES; + ONLY_ACTIVE_ARCH = YES; + SDKROOT = iphoneos; + SWIFT_ACTIVE_COMPILATION_CONDITIONS = DEBUG; + SWIFT_OPTIMIZATION_LEVEL = "-Onone"; + }; + name = Debug; + }; + AE51FFFA1F9DD117003F7477 /* Release */ = { + isa = XCBuildConfiguration; + buildSettings = { + ALWAYS_SEARCH_USER_PATHS = NO; + CLANG_ANALYZER_NONNULL = YES; + CLANG_ANALYZER_NUMBER_OBJECT_CONVERSION = YES_AGGRESSIVE; + CLANG_CXX_LANGUAGE_STANDARD = "gnu++14"; + CLANG_CXX_LIBRARY = "libc++"; + CLANG_ENABLE_MODULES = YES; + CLANG_ENABLE_OBJC_ARC = YES; + CLANG_WARN_BLOCK_CAPTURE_AUTORELEASING = YES; + CLANG_WARN_BOOL_CONVERSION = YES; + CLANG_WARN_COMMA = YES; + CLANG_WARN_CONSTANT_CONVERSION = YES; + CLANG_WARN_DIRECT_OBJC_ISA_USAGE = YES_ERROR; + CLANG_WARN_DOCUMENTATION_COMMENTS = YES; + CLANG_WARN_EMPTY_BODY = YES; + CLANG_WARN_ENUM_CONVERSION = YES; + CLANG_WARN_INFINITE_RECURSION = YES; + CLANG_WARN_INT_CONVERSION = YES; + CLANG_WARN_NON_LITERAL_NULL_CONVERSION = YES; + CLANG_WARN_OBJC_LITERAL_CONVERSION = YES; + CLANG_WARN_OBJC_ROOT_CLASS = YES_ERROR; + CLANG_WARN_RANGE_LOOP_ANALYSIS = YES; + CLANG_WARN_STRICT_PROTOTYPES = YES; + CLANG_WARN_SUSPICIOUS_MOVE = YES; + CLANG_WARN_UNGUARDED_AVAILABILITY = YES_AGGRESSIVE; + CLANG_WARN_UNREACHABLE_CODE = YES; + CLANG_WARN__DUPLICATE_METHOD_MATCH = YES; + CODE_SIGN_IDENTITY = "iPhone Developer"; + COPY_PHASE_STRIP = NO; + DEBUG_INFORMATION_FORMAT = "dwarf-with-dsym"; + ENABLE_NS_ASSERTIONS = NO; + ENABLE_STRICT_OBJC_MSGSEND = YES; + GCC_C_LANGUAGE_STANDARD = gnu11; + GCC_NO_COMMON_BLOCKS = YES; + GCC_WARN_64_TO_32_BIT_CONVERSION = YES; + GCC_WARN_ABOUT_RETURN_TYPE = YES_ERROR; + GCC_WARN_UNDECLARED_SELECTOR = YES; + GCC_WARN_UNINITIALIZED_AUTOS = YES_AGGRESSIVE; + GCC_WARN_UNUSED_FUNCTION = YES; + GCC_WARN_UNUSED_VARIABLE = YES; + IPHONEOS_DEPLOYMENT_TARGET = 11.0; + MTL_ENABLE_DEBUG_INFO = NO; + SDKROOT = iphoneos; + SWIFT_OPTIMIZATION_LEVEL = "-Owholemodule"; + VALIDATE_PRODUCT = YES; + }; + name = Release; + }; + AE51FFFC1F9DD117003F7477 /* Debug */ = { + isa = XCBuildConfiguration; + buildSettings = { + ASSETCATALOG_COMPILER_APPICON_NAME = AppIcon; + CODE_SIGN_STYLE = Automatic; + INFOPLIST_FILE = MoneyConverter/Info.plist; + LD_RUNPATH_SEARCH_PATHS = "$(inherited) @executable_path/Frameworks"; + PRODUCT_BUNDLE_IDENTIFIER = "--------.MoneyConverter"; + PRODUCT_NAME = "$(TARGET_NAME)"; + SWIFT_VERSION = 4.0; + TARGETED_DEVICE_FAMILY = "1,2"; + }; + name = Debug; + }; + AE51FFFD1F9DD117003F7477 /* Release */ = { + isa = XCBuildConfiguration; + buildSettings = { + ASSETCATALOG_COMPILER_APPICON_NAME = AppIcon; + CODE_SIGN_STYLE = Automatic; + INFOPLIST_FILE = MoneyConverter/Info.plist; + LD_RUNPATH_SEARCH_PATHS = "$(inherited) @executable_path/Frameworks"; + PRODUCT_BUNDLE_IDENTIFIER = "--------.MoneyConverter"; + PRODUCT_NAME = "$(TARGET_NAME)"; + SWIFT_VERSION = 4.0; + TARGETED_DEVICE_FAMILY = "1,2"; + }; + name = Release; + }; + AE51FFFF1F9DD117003F7477 /* Debug */ = { + isa = XCBuildConfiguration; + buildSettings = { + ALWAYS_EMBED_SWIFT_STANDARD_LIBRARIES = YES; + BUNDLE_LOADER = "$(TEST_HOST)"; + CODE_SIGN_STYLE = Automatic; + INFOPLIST_FILE = MoneyConverterTests/Info.plist; + LD_RUNPATH_SEARCH_PATHS = "$(inherited) @executable_path/Frameworks @loader_path/Frameworks"; + PRODUCT_BUNDLE_IDENTIFIER = "--------.MoneyConverterTests"; + PRODUCT_NAME = "$(TARGET_NAME)"; + SWIFT_VERSION = 4.0; + TARGETED_DEVICE_FAMILY = "1,2"; + TEST_HOST = "$(BUILT_PRODUCTS_DIR)/MoneyConverter.app/MoneyConverter"; + }; + name = Debug; + }; +/* End XCBuildConfiguration section */ + +/* Begin XCConfigurationList section */ + AE5100011F9DD117003F7477 /* Build configuration list for PBXNativeTarget "MoneyConverterUITests" */ = { + isa = XCConfigurationList; + buildConfigurations = ( + AE5100021F9DD117003F7477 /* Debug */, + AE5100031F9DD117003F7477 /* Release */, + ); + defaultConfigurationIsVisible = 0; + defaultConfigurationName = Release; + }; + AE51FFCE1F9DD116003F7477 /* Build configuration list for PBXProject "MoneyConverter" */ = { + isa = XCConfigurationList; + buildConfigurations = ( + AE51FFF91F9DD117003F7477 /* Debug */, + AE51FFFA1F9DD117003F7477 /* Release */, + ); + defaultConfigurationIsVisible = 0; + defaultConfigurationName = Release; + }; + AE51FFFB1F9DD117003F7477 /* Build configuration list for PBXNativeTarget "MoneyConverter" */ = { + isa = XCConfigurationList; + buildConfigurations = ( + AE51FFFC1F9DD117003F7477 /* Debug */, + AE51FFFD1F9DD117003F7477 /* Release */, + ); + defaultConfigurationIsVisible = 0; + defaultConfigurationName = Release; + }; + AE51FFFE1F9DD117003F7477 /* Build configuration list for PBXNativeTarget "MoneyConverterTests" */ = { + isa = XCConfigurationList; + buildConfigurations = ( + AE51FFFF1F9DD117003F7477 /* Debug */, + AE5100001F9DD117003F7477 /* Release */, + ); + defaultConfigurationIsVisible = 0; + defaultConfigurationName = Release; + }; +/* End XCConfigurationList section */ + }; + rootObject = AE51FFCB1F9DD116003F7477 /* Project object */; +} diff --git "a/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/MoneyConverter/MoneyConverter.xcodeproj/project.xcworkspace/contents.xcworkspacedata" "b/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/MoneyConverter/MoneyConverter.xcodeproj/project.xcworkspace/contents.xcworkspacedata" new file mode 100644 index 0000000..5566428 --- /dev/null +++ "b/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/MoneyConverter/MoneyConverter.xcodeproj/project.xcworkspace/contents.xcworkspacedata" @@ -0,0 +1,7 @@ + + + + + diff --git "a/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/MoneyConverter/MoneyConverter/AppDelegate.swift" "b/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/MoneyConverter/MoneyConverter/AppDelegate.swift" new file mode 100644 index 0000000..a55f070 --- /dev/null +++ "b/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/MoneyConverter/MoneyConverter/AppDelegate.swift" @@ -0,0 +1,46 @@ +// +// AppDelegate.swift +// MoneyConverter +// +// Created by 황도증 on 2017. 10. 23.. +// Copyright © 2017년 황도증. All rights reserved. +// + +import UIKit + +@UIApplicationMain +class AppDelegate: UIResponder, UIApplicationDelegate { + + var window: UIWindow? + + + func application(_ application: UIApplication, didFinishLaunchingWithOptions launchOptions: [UIApplicationLaunchOptionsKey: Any]?) -> Bool { + // Override point for customization after application launch. + return true + } + + func applicationWillResignActive(_ application: UIApplication) { + // Sent when the application is about to move from active to inactive state. This can occur for certain types of temporary interruptions (such as an incoming phone call or SMS message) or when the user quits the application and it begins the transition to the background state. + // Use this method to pause ongoing tasks, disable timers, and invalidate graphics rendering callbacks. Games should use this method to pause the game. + } + + func applicationDidEnterBackground(_ application: UIApplication) { + // Use this method to release shared resources, save user data, invalidate timers, and store enough application state information to restore your application to its current state in case it is terminated later. + // If your application supports background execution, this method is called instead of applicationWillTerminate: when the user quits. + } + + func applicationWillEnterForeground(_ application: UIApplication) { + // Called as part of the transition from the background to the active state; here you can undo many of the changes made on entering the background. + } + + func applicationDidBecomeActive(_ application: UIApplication) { + // Restart any tasks that were paused (or not yet started) while the application was inactive. If the application was previously in the background, optionally refresh the user interface. + } + + func applicationWillTerminate(_ application: UIApplication) { + // Called when the application is about to terminate. Save data if appropriate. See also applicationDidEnterBackground:. + } + + +} + diff --git "a/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/MoneyConverter/MoneyConverter/Assets.xcassets/AppIcon.appiconset/Contents.json" "b/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/MoneyConverter/MoneyConverter/Assets.xcassets/AppIcon.appiconset/Contents.json" new file mode 100644 index 0000000..1d060ed --- /dev/null +++ "b/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/MoneyConverter/MoneyConverter/Assets.xcassets/AppIcon.appiconset/Contents.json" @@ -0,0 +1,93 @@ +{ + "images" : [ + { + "idiom" : "iphone", + "size" : "20x20", + "scale" : "2x" + }, + { + "idiom" : "iphone", + "size" : "20x20", + "scale" : "3x" + }, + { + "idiom" : "iphone", + "size" : "29x29", + "scale" : "2x" + }, + { + "idiom" : "iphone", + "size" : "29x29", + "scale" : "3x" + }, + { + "idiom" : "iphone", + "size" : "40x40", + "scale" : "2x" + }, + { + "idiom" : "iphone", + "size" : "40x40", + "scale" : "3x" + }, + { + "idiom" : "iphone", + "size" : "60x60", + "scale" : "2x" + }, + { + "idiom" : "iphone", + "size" : "60x60", + "scale" : "3x" + }, + { + "idiom" : "ipad", + "size" : "20x20", + "scale" : "1x" + }, + { + "idiom" : "ipad", + "size" : "20x20", + "scale" : "2x" + }, + { + "idiom" : "ipad", + "size" : "29x29", + "scale" : "1x" + }, + { + "idiom" : "ipad", + "size" : "29x29", + "scale" : "2x" + }, + { + "idiom" : "ipad", + "size" : "40x40", + "scale" : "1x" + }, + { + "idiom" : "ipad", + "size" : "40x40", + "scale" : "2x" + }, + { + "idiom" : "ipad", + "size" : "76x76", + "scale" : "1x" + }, + { + "idiom" : "ipad", + "size" : "76x76", + "scale" : "2x" + }, + { + "idiom" : "ipad", + "size" : "83.5x83.5", + "scale" : "2x" + } + ], + "info" : { + "version" : 1, + "author" : "xcode" + } +} \ No newline at end of file diff --git "a/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/MoneyConverter/MoneyConverter/Base.lproj/LaunchScreen.storyboard" "b/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/MoneyConverter/MoneyConverter/Base.lproj/LaunchScreen.storyboard" new file mode 100644 index 0000000..f83f6fd --- /dev/null +++ "b/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/MoneyConverter/MoneyConverter/Base.lproj/LaunchScreen.storyboard" @@ -0,0 +1,25 @@ + + + + + + + + + + + + + + + + + + + + + + + + + diff --git "a/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/MoneyConverter/MoneyConverter/Base.lproj/Main.storyboard" "b/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/MoneyConverter/MoneyConverter/Base.lproj/Main.storyboard" new file mode 100644 index 0000000..718df7d --- /dev/null +++ "b/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/MoneyConverter/MoneyConverter/Base.lproj/Main.storyboard" @@ -0,0 +1,67 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + diff --git "a/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/MoneyConverter/MoneyConverter/Info.plist" "b/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/MoneyConverter/MoneyConverter/Info.plist" new file mode 100644 index 0000000..16be3b6 --- /dev/null +++ "b/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/MoneyConverter/MoneyConverter/Info.plist" @@ -0,0 +1,45 @@ + + + + + CFBundleDevelopmentRegion + $(DEVELOPMENT_LANGUAGE) + CFBundleExecutable + $(EXECUTABLE_NAME) + CFBundleIdentifier + $(PRODUCT_BUNDLE_IDENTIFIER) + CFBundleInfoDictionaryVersion + 6.0 + CFBundleName + $(PRODUCT_NAME) + CFBundlePackageType + APPL + CFBundleShortVersionString + 1.0 + CFBundleVersion + 1 + LSRequiresIPhoneOS + + UILaunchStoryboardName + LaunchScreen + UIMainStoryboardFile + Main + UIRequiredDeviceCapabilities + + armv7 + + UISupportedInterfaceOrientations + + UIInterfaceOrientationPortrait + UIInterfaceOrientationLandscapeLeft + UIInterfaceOrientationLandscapeRight + + UISupportedInterfaceOrientations~ipad + + UIInterfaceOrientationPortrait + UIInterfaceOrientationPortraitUpsideDown + UIInterfaceOrientationLandscapeLeft + UIInterfaceOrientationLandscapeRight + + + diff --git "a/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/MoneyConverter/MoneyConverter/Money.swift" "b/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/MoneyConverter/MoneyConverter/Money.swift" new file mode 100644 index 0000000..0ff07ac --- /dev/null +++ "b/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/MoneyConverter/MoneyConverter/Money.swift" @@ -0,0 +1,62 @@ +// +// Money.swift +// MoneyConverter +// +// Created by 황도증 on 2017. 10. 23.. +// Copyright © 2017년 황도증. All rights reserved. +// + +import Foundation + +enum Currency:Int { + case USD = 0, KRW, JPY, EUR + + var ratio:Double { + get { + switch self { + case .USD: + return 1.0 + case .KRW: + return 1178.5 + case .JPY: + return 122.45 + case .EUR: + return 0.92 + } + } + } + + var symbol:String { + get { + switch self { + case .USD: + return "$" + case .KRW: + return "₩" + case .JPY: + return "¥" + case .EUR: + return "€" + } + } + } +} + +struct Money { + var usdollar = 0.0 + + init(_ _usdollar:Double) { + usdollar = _usdollar + } + + init(_ amount:Double, currency:Currency) { + usdollar = amount / currency.ratio + } + + func valueInCurrency(currency:Currency) -> String { + return "\(currency.symbol)" + "\(usdollar * currency.ratio)" + } +} + +let myMoney = Money(120) +let incomeKRW = Money(350_000, currency: .KRW) diff --git "a/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/MoneyConverter/MoneyConverter/ViewController.swift" "b/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/MoneyConverter/MoneyConverter/ViewController.swift" new file mode 100644 index 0000000..c6e3a2b --- /dev/null +++ "b/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/MoneyConverter/MoneyConverter/ViewController.swift" @@ -0,0 +1,52 @@ +// +// ViewController.swift +// MoneyConverter +// +// Created by 황도증 on 2017. 10. 23.. +// Copyright © 2017년 황도증. All rights reserved. +// + +import UIKit + +class ViewController: UIViewController { + + @IBOutlet weak var currencySegment: UISegmentedControl! + @IBOutlet weak var sourceMoneyField: UITextField! + @IBOutlet weak var targetMoneyLabel: UILabel! + + override func viewDidLoad() { + super.viewDidLoad() + // Do any additional setup after loading the view, typically from a nib. + } + + override func didReceiveMemoryWarning() { + super.didReceiveMemoryWarning() + // Dispose of any resources that can be recreated. + } + + @IBAction func convertMoney(_ sender: Any) { + + guard let sourceCurrency = Currency(rawValue: currencySegment.selectedSegmentIndex) else { + print("Source currency Error") + return + } + + guard let sourceAmount = Double(sourceMoneyField.text!) else { + targetMoneyLabel.text = "Error" + return + } + + let sourceMoney = Money(sourceAmount, currency: sourceCurrency) + + var targetMoneyString = "" + for i in 0..<4 { + targetMoneyString += sourceMoney.valueInCurrency(currency: Currency.init(rawValue : i)!) + targetMoneyString += "\r\n" + } + + + targetMoneyLabel.text = targetMoneyString + } + +} + diff --git "a/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/MoneyConverter/MoneyConverterTests/Info.plist" "b/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/MoneyConverter/MoneyConverterTests/Info.plist" new file mode 100644 index 0000000..6c40a6c --- /dev/null +++ "b/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/MoneyConverter/MoneyConverterTests/Info.plist" @@ -0,0 +1,22 @@ + + + + + CFBundleDevelopmentRegion + $(DEVELOPMENT_LANGUAGE) + CFBundleExecutable + $(EXECUTABLE_NAME) + CFBundleIdentifier + $(PRODUCT_BUNDLE_IDENTIFIER) + CFBundleInfoDictionaryVersion + 6.0 + CFBundleName + $(PRODUCT_NAME) + CFBundlePackageType + BNDL + CFBundleShortVersionString + 1.0 + CFBundleVersion + 1 + + diff --git "a/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/MoneyConverter/MoneyConverterTests/MoneyConverterTests.swift" "b/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/MoneyConverter/MoneyConverterTests/MoneyConverterTests.swift" new file mode 100644 index 0000000..5cd05d5 --- /dev/null +++ "b/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/MoneyConverter/MoneyConverterTests/MoneyConverterTests.swift" @@ -0,0 +1,36 @@ +// +// MoneyConverterTests.swift +// MoneyConverterTests +// +// Created by 황도증 on 2017. 10. 23.. +// Copyright © 2017년 황도증. All rights reserved. +// + +import XCTest +@testable import MoneyConverter + +class MoneyConverterTests: XCTestCase { + + override func setUp() { + super.setUp() + // Put setup code here. This method is called before the invocation of each test method in the class. + } + + override func tearDown() { + // Put teardown code here. This method is called after the invocation of each test method in the class. + super.tearDown() + } + + func testExample() { + // This is an example of a functional test case. + // Use XCTAssert and related functions to verify your tests produce the correct results. + } + + func testPerformanceExample() { + // This is an example of a performance test case. + self.measure { + // Put the code you want to measure the time of here. + } + } + +} diff --git "a/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/MoneyConverter/MoneyConverterUITests/Info.plist" "b/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/MoneyConverter/MoneyConverterUITests/Info.plist" new file mode 100644 index 0000000..6c40a6c --- /dev/null +++ "b/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/MoneyConverter/MoneyConverterUITests/Info.plist" @@ -0,0 +1,22 @@ + + + + + CFBundleDevelopmentRegion + $(DEVELOPMENT_LANGUAGE) + CFBundleExecutable + $(EXECUTABLE_NAME) + CFBundleIdentifier + $(PRODUCT_BUNDLE_IDENTIFIER) + CFBundleInfoDictionaryVersion + 6.0 + CFBundleName + $(PRODUCT_NAME) + CFBundlePackageType + BNDL + CFBundleShortVersionString + 1.0 + CFBundleVersion + 1 + + diff --git "a/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/MoneyConverter/MoneyConverterUITests/MoneyConverterUITests.swift" "b/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/MoneyConverter/MoneyConverterUITests/MoneyConverterUITests.swift" new file mode 100644 index 0000000..09be271 --- /dev/null +++ "b/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/MoneyConverter/MoneyConverterUITests/MoneyConverterUITests.swift" @@ -0,0 +1,36 @@ +// +// MoneyConverterUITests.swift +// MoneyConverterUITests +// +// Created by 황도증 on 2017. 10. 23.. +// Copyright © 2017년 황도증. All rights reserved. +// + +import XCTest + +class MoneyConverterUITests: XCTestCase { + + override func setUp() { + super.setUp() + + // Put setup code here. This method is called before the invocation of each test method in the class. + + // In UI tests it is usually best to stop immediately when a failure occurs. + continueAfterFailure = false + // UI tests must launch the application that they test. Doing this in setup will make sure it happens for each test method. + XCUIApplication().launch() + + // In UI tests it’s important to set the initial state - such as interface orientation - required for your tests before they run. The setUp method is a good place to do this. + } + + override func tearDown() { + // Put teardown code here. This method is called after the invocation of each test method in the class. + super.tearDown() + } + + func testExample() { + // Use recording to get started writing UI tests. + // Use XCTAssert and related functions to verify your tests produce the correct results. + } + +} diff --git "a/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/Optional.playground/Contents.swift" "b/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/Optional.playground/Contents.swift" new file mode 100644 index 0000000..6152ba1 --- /dev/null +++ "b/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/Optional.playground/Contents.swift" @@ -0,0 +1,37 @@ +//: Playground - noun: a place where people can play + +import UIKit + +var title = "Hello, playground" +var ratings:[Int]? = nil +var supportUrl:String? = nil + +supportUrl = "www.DJ.com" +//print("\(title) has \(ratings!.count). \r\n support to webpage : \(supportUrl)") + +//force unwrapping +//물음표로 옵셔널을 선언하고 느낌표로 데이터를 확신한다고 표시. 느낌표가 많으면 크래쉬가 날 가능성이 많다 +var bookDescription:String = "\(title)" +if ratings != nil { + bookDescription += "has \(ratings!.count) ratings" +} +if supportUrl != nil { + bookDescription += "\r\nsupport webpage : \(supportUrl!)" +} + +print(bookDescription) + +//optional binding. +if let theRating = ratings { + bookDescription += "has \(theRating) ratings" +} +if let theURL = supportUrl { + bookDescription += "\r\nsupport webpage : \(theURL)" +} + + +//implicitly unwrapped optional. +//옵셔널 사용을 편하게 하기 위한 편의장치. 어쩔 수 없이 옵셔널이지만 실행 중 항상 값을 가지는 게 거의 확실. +var URL:String! = nil +//선언 시에 !를 사용해 선언하고, 후에 옵셔널이 아닌 것처럼 사용한다. + diff --git "a/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/Optional.playground/contents.xcplayground" "b/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/Optional.playground/contents.xcplayground" new file mode 100644 index 0000000..5da2641 --- /dev/null +++ "b/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/Optional.playground/contents.xcplayground" @@ -0,0 +1,4 @@ + + + + \ No newline at end of file diff --git "a/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/Optional.playground/playground.xcworkspace/contents.xcworkspacedata" "b/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/Optional.playground/playground.xcworkspace/contents.xcworkspacedata" new file mode 100644 index 0000000..919434a --- /dev/null +++ "b/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/Optional.playground/playground.xcworkspace/contents.xcworkspacedata" @@ -0,0 +1,7 @@ + + + + + diff --git "a/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/Optional.playground/timeline.xctimeline" "b/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/Optional.playground/timeline.xctimeline" new file mode 100644 index 0000000..77f057d --- /dev/null +++ "b/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/Optional.playground/timeline.xctimeline" @@ -0,0 +1,12 @@ + + + + + + + diff --git "a/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/Optional_quiz.playground/Contents.swift" "b/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/Optional_quiz.playground/Contents.swift" new file mode 100644 index 0000000..c5ca9e0 --- /dev/null +++ "b/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/Optional_quiz.playground/Contents.swift" @@ -0,0 +1,47 @@ +//: Playground - noun: a place where people can play + +import UIKit + +//아래는 애플와치와 쌍을 이룬 아이폰을 찾는 가상의 코드입니다.(실제 애플와치 앱에서 이런 코드를 사용하는 것은 아닙니다) optional binding을 써서 빈 칸에 적당한 코드를 작성해주세요. + +struct WatchDevice { + var pairediPhone:String? //애플와치와 쌍을 이루는 아이폰의 이름. + var appInstalled = false //어플리케이션의 설치 유무 + + enum WatchSize { + case m42, m38 + } +} + +var appleWatch:WatchDevice? = nil +appleWatch = WatchDevice(pairediPhone: "링고스타의 아이폰", appInstalled: true) + +// ①appleWatch에 대해 optional binding으로 watch라는 새로운 변수를 생성해주세요. +if let watch = appleWatch { + // ②watch와 쌍을 이루는 아이폰의 이름에 대해 + // optional binding으로 phoneName이라는 새로운 변수를 생성해 주세요. + if let phoneName = watch.pairediPhone { + print ("AppleWatch가 \(phoneName)과 쌍을 이룹니다.") + } +} + + + +/*실습1에서 쓴 코드를 더 줄여 써 봅시다. 실습1과 동일한 결과가 나오도록 밑줄 친 구문을 완성해주세요. 실행 시 "AppleWatch가 링고스타의 아이폰과 쌍을 이룹니다."라는 구문이 나오면 됩니다. +struct WatchDevice { + var pairediPhone:String? //애플와치와 쌍을 이루는 아이폰의 이름. + var appInstalled = false //어플리케이션의 설치 유무 + + enum WatchSize { + case m42, m38 + } +} + +var appleWatch:WatchDevice? = nil +appleWatch = WatchDevice(pairediPhone: "링고스타의 아이폰", appInstalled: true) + +// appleWatch에 appleWatch에 대해 optional binding으로 phoneName이라는 새로운 변수를 생성해 주세요 +if let phoneName = appleWatch?.pairediPhone { + print ("AppleWatch가 \(phoneName)과 쌍을 이룹니다.") +} +*/ diff --git "a/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/Optional_quiz.playground/contents.xcplayground" "b/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/Optional_quiz.playground/contents.xcplayground" new file mode 100644 index 0000000..5da2641 --- /dev/null +++ "b/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/Optional_quiz.playground/contents.xcplayground" @@ -0,0 +1,4 @@ + + + + \ No newline at end of file diff --git "a/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/Optional_quiz.playground/playground.xcworkspace/contents.xcworkspacedata" "b/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/Optional_quiz.playground/playground.xcworkspace/contents.xcworkspacedata" new file mode 100644 index 0000000..919434a --- /dev/null +++ "b/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/Optional_quiz.playground/playground.xcworkspace/contents.xcworkspacedata" @@ -0,0 +1,7 @@ + + + + + diff --git "a/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/String&numbers.playground/Contents.swift" "b/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/String&numbers.playground/Contents.swift" new file mode 100644 index 0000000..46f35d3 --- /dev/null +++ "b/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/String&numbers.playground/Contents.swift" @@ -0,0 +1,43 @@ +//: Playground - noun: a place where people can play + +import UIKit + +let name = "DJ" + +var greeting = "Hello" +greeting += " " + name + + +//문자열에 각각의 문자에 접근할 수 있도록 해주는 characters (일종의 배열로 리턴) +let character = name.characters +let count = character.count + +//문자열의 앞 혹은 뒤에 특정 문자열이 들어가있는지 불리안 값으로 리턴해주는 hasPrefix, hasSuffix +let url = "www.dj.com" +let hasProtocol = url.hasPrefix("www") + +// 변수의 타입을 맞춰줘야한다. +var speed:Int = 20 +speed += Int(10.5) + +let pi = 3.14 +let divider = 2 +let halfPi = 3.14/Double(divider) + +//String타입도 넘버로 바꿔줄 수 있음 +let text:String = "213" +let textToNumber = Int(text) +speed += textToNumber! + +//String타입을 넘버로 바꾸는 방법2 +let occur = "10" +if let occ = Int(occur) { + print("By optional binding :", occ*2) // 20 + +} + +//판교와 파주 사이에 거리는 69500m입니다. 2번째 줄의 distance를 적당한 타입으로 변경해서 description을 다음과 같이 출력되게 완성해보세요. "판교에서 파주는 69.5km 거리입니다." +let distance = 69500 +let description = "판교에서 파주는 " + "\(Double(distance)/1000)" + "km 거리입니다." + +print(description) diff --git "a/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/String&numbers.playground/contents.xcplayground" "b/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/String&numbers.playground/contents.xcplayground" new file mode 100644 index 0000000..5da2641 --- /dev/null +++ "b/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/String&numbers.playground/contents.xcplayground" @@ -0,0 +1,4 @@ + + + + \ No newline at end of file diff --git "a/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/String&numbers.playground/timeline.xctimeline" "b/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/String&numbers.playground/timeline.xctimeline" new file mode 100644 index 0000000..97b973d --- /dev/null +++ "b/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/String&numbers.playground/timeline.xctimeline" @@ -0,0 +1,11 @@ + + + + + + + diff --git "a/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/Tuple&typealias.playground/Contents.swift" "b/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/Tuple&typealias.playground/Contents.swift" new file mode 100644 index 0000000..ba33ef4 --- /dev/null +++ "b/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/Tuple&typealias.playground/Contents.swift" @@ -0,0 +1,39 @@ +//: Playground - noun: a place where people can play + +import UIKit + +//튜플은 콤마로 구분되는 값들의 리스트 +//튜플 안에는 다양한 타입이 함께 섞여 들어갈 수 있다. 물론 튜플이 또 들어갈 수 있다. + +let time1 = (9, 10, 12) +time1.0 +let time2:(h:Int, m:Int, s:Int) = (11, 22, 33) +time2.h + +let duration = (time1, time2) +let (start, end) = duration +let endHour = end.h + + +//타입을 새로이 지정할 수 있다. +typealias Time = (h:Int, m:Int, s:Int) +typealias Duration = (start:Time, end:Time) + +let today:Duration = ((9,19,2), (22,30,10)) +print("We studied until \(today.end.h) today") + +/* + 트라이애슬론은 수영, 사이클, 달리기가 합쳐진 운동으로, 우리에게 철인 3종 경기라는 이름으로 잘 알려져 있습니다. 트라이애슬론에는 단거리 경주인 sprint와 장거리 경기인 ironMan 경기가 있습니다. + + ironMan경기의 사이클 거리가 sprint경기의 사이클 거리의 몇배인지를 times에 저장하고 싶습니다. 코드 5번째 줄의 _____를 수정해서 times에 값을 저장하세요. +*/ +typealias Triathlon = (swim:Int, cycle:Int, running:Int) +let sprint = Triathlon(750, 20000, 5000) +let ironMan = Triathlon(3800, 180000, 42200) + +//let times = ______ +let times = ironMan.cycle/sprint.cycle + +// 아래는 결과 테스트를 위한 코드입니다. 수정하지 마세요. +print(times) + diff --git "a/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/Tuple&typealias.playground/contents.xcplayground" "b/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/Tuple&typealias.playground/contents.xcplayground" new file mode 100644 index 0000000..5da2641 --- /dev/null +++ "b/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/Tuple&typealias.playground/contents.xcplayground" @@ -0,0 +1,4 @@ + + + + \ No newline at end of file diff --git "a/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/closure.playground/Contents.swift" "b/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/closure.playground/Contents.swift" new file mode 100644 index 0000000..310a863 --- /dev/null +++ "b/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/closure.playground/Contents.swift" @@ -0,0 +1,27 @@ +//: Playground - noun: a place where people can play + +import UIKit + +/*클로저는 1등시민으로 사용가능한 독립적인 코드조각이다. + 자신이 정의된 환경을 캡처해서 저장한 뒤 닫아버린다고 해서 클로저라 부름 + Objective-C의 Block이나 Java의 Lambda도 클로저의 일종 + in 이 사용되면 클로저. + 하지만 in은 흔히 생략됨 + */ + +let addVATClosure = { (source:Double) -> Double in return source * 1.1} +let couponDiscountClosure = { (source:Double) -> Double in return source * 0.9 } + +let price1023 = addVATClosure(350.3) + +//클로져의 축약1 - 타입을 추론. 들어론 매개변수와 같은 타입을 리턴한다 +let addVATClosure2 = { source in return source * 1.1} + +//클로저의 축약2 - 리턴 생략. 클로저는 무조건 값을 리턴하므로 +let addVATClosure3 = { source in source * 1.1} + +//클로저의 축약3 - 매개변수 생략. 매개변수를 위치로 참조한다. 첫번째 매개변수 = $0, 두번째 매개변수 = $1 etc +let addVATClosure4 = { $0 * 1.1} +let couponDiscountClosure4 = { $0 * 0.9 } + +let price = addVATClosure4(400) diff --git "a/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/closure.playground/contents.xcplayground" "b/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/closure.playground/contents.xcplayground" new file mode 100644 index 0000000..5da2641 --- /dev/null +++ "b/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/closure.playground/contents.xcplayground" @@ -0,0 +1,4 @@ + + + + \ No newline at end of file diff --git "a/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/closure.playground/playground.xcworkspace/contents.xcworkspacedata" "b/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/closure.playground/playground.xcworkspace/contents.xcworkspacedata" new file mode 100644 index 0000000..919434a --- /dev/null +++ "b/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/closure.playground/playground.xcworkspace/contents.xcworkspacedata" @@ -0,0 +1,7 @@ + + + + + diff --git "a/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/currying.playground/Contents.swift" "b/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/currying.playground/Contents.swift" new file mode 100644 index 0000000..37b7c6f --- /dev/null +++ "b/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/currying.playground/Contents.swift" @@ -0,0 +1,54 @@ +//: Playground - noun: a place where people can play + +import UIKit + +/*다른 함수를 매개변수로 받거나 함수를 리턴타입으로 사용하는 함수를 고차함수라고 한다.] + 이번에는 함수를 리턴하는 함수를 사용해 본다 + + makeAdder 함수 + 함수안에서 함수를 생성해서 리턴한다 + makeAdder는 결과적으로 두 개의 정수를 더하는 함수 + 하나의 정수를 받아서, 정수를 받아 정수를 리턴하는 함수를 만들어 리턴한다 + 이런 식으로 여러 개의 매개변수를 받는 함수를 쪼개서 하나의 매개변수를 받은 뒤 나머지 매개변수를 받는 함수를 리턴하는 함수를 커링(Currying)함수라고 한다 + */ + +let addVATClosure = { (source:Double) -> Double in return source * 1.1} +let couponDiscountClosure = { (source:Double) -> Double in return source * 0.9 } + +let price1023 = addVATClosure(350.3) + +let addVATClosure2 = { source in return source * 1.1} +let addVATClosure3 = { source in source * 1.1} +let addVATClosure4 = { $0 * 1.1} +let couponDiscountClosure4 = { $0 * 0.9 } + +let price = addVATClosure4(400) + + +func makeAdder (x:Int) -> (Int) -> Int { + func adder (a:Int) -> Int { + return x + a + } + return adder +} +//클로져를 사용 +func makeAdder2 (x:Int) -> (Int) -> Int { + let adder:(Int) -> Int = { + return $0 + x + } + return adder +} + +func makeAdder3 (x:Int) -> (Int) -> Int { + return { + return $0 + x + } +} + +let add5 = makeAdder(x: 5) +let add10 = makeAdder2(x: 10) + +print(add5(2)) +print(add10(2)) +//함수를 리턴하는 함수는 이런 식으로 두 개의 매개변수를 넣을 수도 있다 +print(makeAdder2(x: 5)(2)) diff --git "a/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/currying.playground/contents.xcplayground" "b/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/currying.playground/contents.xcplayground" new file mode 100644 index 0000000..5da2641 --- /dev/null +++ "b/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/currying.playground/contents.xcplayground" @@ -0,0 +1,4 @@ + + + + \ No newline at end of file diff --git "a/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/currying.playground/playground.xcworkspace/contents.xcworkspacedata" "b/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/currying.playground/playground.xcworkspace/contents.xcworkspacedata" new file mode 100644 index 0000000..919434a --- /dev/null +++ "b/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/currying.playground/playground.xcworkspace/contents.xcworkspacedata" @@ -0,0 +1,7 @@ + + + + + diff --git "a/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/filter.playground/Contents.swift" "b/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/filter.playground/Contents.swift" new file mode 100644 index 0000000..3f42644 --- /dev/null +++ "b/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/filter.playground/Contents.swift" @@ -0,0 +1,22 @@ +//: Playground - noun: a place where people can play + +import UIKit + +/*고차함수 map + filter 함수는 배열과 조건문이 있는 함수를 매개변수로 받아서, 배열의 하나하나에 함수의 조건문을 적용해서 통과하는 항목만으로 새로운 배열을 만드는 함수이다. + + transactions 배열에서 큰 값만 추려내기 + 거래금액이 500 이상인 경우 true를 리턴하는 함수 + 적용 시 조건에 맞는 항목만으로 이루어진 배열 생성 + meetingRooms 딕셔너리에 filter 적용하기 + 딕셔너리에 filter를 적용하면 튜플의 배열로 변환 + meetingRooms의 value는 튜플에서 .1로 접근 가능 + */ + +var meetingRooms:[String:Int] = ["A":10, "B":20, "C":30, "D":40] + +let members = 20 +//filter. 딕셔너리의 키나 벨류 값에 접근할 수 있다 +let available = meetingRooms.filter( {$0.value > 20} ) + +print("\(available)") diff --git "a/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/filter.playground/contents.xcplayground" "b/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/filter.playground/contents.xcplayground" new file mode 100644 index 0000000..5da2641 --- /dev/null +++ "b/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/filter.playground/contents.xcplayground" @@ -0,0 +1,4 @@ + + + + \ No newline at end of file diff --git "a/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/filter.playground/playground.xcworkspace/contents.xcworkspacedata" "b/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/filter.playground/playground.xcworkspace/contents.xcworkspacedata" new file mode 100644 index 0000000..919434a --- /dev/null +++ "b/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/filter.playground/playground.xcworkspace/contents.xcworkspacedata" @@ -0,0 +1,7 @@ + + + + + diff --git "a/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/instance_class.playground/Contents.swift" "b/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/instance_class.playground/Contents.swift" new file mode 100644 index 0000000..8943188 --- /dev/null +++ "b/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/instance_class.playground/Contents.swift" @@ -0,0 +1,45 @@ +//: Playground - noun: a place where people can play + +import UIKit + +struct Task { + var title:String + var time:Int? + + var owner:Employee + var participant:Employee? +} + +/*데이터 모델의 중요한 구성요소로써 Object를 만든다 + 클래스는 객체지향 프로그래밍(OOP, Object Oriented Programming)의 바탕을 이룬다 + + 클래스로 만든 오브젝트는 Reference Type으로 동작하며, 할당시 복사되지 않는다 + 하나의 인스턴스에 대한 레퍼런스를 공유한다 + 인스턴스를 할당한 뒤 수정하면 원본과 할당된 곳 모두 수정됨 + */ + +class Employee { + var name:String? + var phoneNumber:String? + var boss:Employee? +} + +//class는 let으로 정의해도 프라퍼티가 var이면 수정 가능 +let me:Employee = Employee() +me.name = "Alex" +me.phoneNumber = "010-3398-9879" + +let toby = Employee() +toby.name = "Toby" +toby.phoneNumber = "010-3392-8765" + +var callTask = Task(title: "Call to Toby", time: 10*60, owner:me, participant:toby) +var reportTask = Task(title: "report to Boss", time: nil, owner:me, participant:nil) + +var todayTask:[Task] = [] +todayTask += [callTask, reportTask] +todayTask[1].time = 15*60 + +callTask.title = "Call to Toby" + +print("Today task = \(todayTask)") diff --git "a/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/instance_class.playground/contents.xcplayground" "b/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/instance_class.playground/contents.xcplayground" new file mode 100644 index 0000000..5da2641 --- /dev/null +++ "b/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/instance_class.playground/contents.xcplayground" @@ -0,0 +1,4 @@ + + + + \ No newline at end of file diff --git "a/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/instance_class.playground/playground.xcworkspace/contents.xcworkspacedata" "b/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/instance_class.playground/playground.xcworkspace/contents.xcworkspacedata" new file mode 100644 index 0000000..919434a --- /dev/null +++ "b/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/instance_class.playground/playground.xcworkspace/contents.xcworkspacedata" @@ -0,0 +1,7 @@ + + + + + diff --git "a/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/instance_class.playground/timeline.xctimeline" "b/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/instance_class.playground/timeline.xctimeline" new file mode 100644 index 0000000..25f5f3a --- /dev/null +++ "b/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/instance_class.playground/timeline.xctimeline" @@ -0,0 +1,16 @@ + + + + + + + + + diff --git "a/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/instance_intialize.playground/Contents.swift" "b/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/instance_intialize.playground/Contents.swift" new file mode 100644 index 0000000..4bf922e --- /dev/null +++ "b/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/instance_intialize.playground/Contents.swift" @@ -0,0 +1,97 @@ +//: Playground - noun: a place where people can play + +import UIKit + +/*초기화 작업은 인스턴스가 가지고 있는 모든 스토어드 프라퍼티(Stored Property)들의 최초 값을 설정하는 것 + + 스토어드 프라퍼티 + 저장소를 가지고 있는 프라퍼티 + + 컴퓨티드 프라퍼티 + 저장소 없이 계산에 의해 값을 리턴하는 프라퍼티 + + 구조체의 초기화 + 여러 개의 init 메소드 허용 + 상속을 허락하지 않으므로 Class에 비해 상대적으로 단순. + + 클래스의 초기화 + 하나의 지정초기화 메소드 + 여러 개의 편의 초기화 메소드 허용 + */ +struct Task { + var title:String + var time:Int? + + var owner:Employee + var participant:Employee? + + var type:TaskType + enum TaskType { + case Call + case Report + case Meet + case Support + + var typeTitle:String { + get { + let titleString:String + switch self { + case .Call: + titleString = "Call" + case .Report: + titleString = "Report" + case .Meet: + titleString = "Meet" + case .Support: + titleString = "Support" + } + return titleString + } + } + } + + init(type:TaskType, owner:Employee) { + self.type = type + self.title = type.typeTitle + self.owner = owner + self.time = nil + self.participant = nil + } +} + +class Employee { + var name:String? + var phoneNumber:String? + var boss:Employee? + + init (name:String) { + self.name = name + } + + init(name:String, phone:String) { + self.name = name + self.phoneNumber = phone + } +} + +let me:Employee = Employee(name: "Alex", phone:"010-3398-8792") +//me.name = "Alex" +//me.phoneNumber = "010-3398-9879" + +let toby = Employee(name: "Toby") +//toby.name = "Toby" +toby.phoneNumber = "010-3392-8765" + +//var callTask = Task(title: "Call to Toby", time: 10*60, owner:me, participant:toby, type:.Call) +var callTask = Task(type:.Call, owner:me) +callTask.time = 10*60 +var reportTask = Task(type:.Report, owner:me) +//var reportTask = Task(title: "report to Boss", time: nil, owner:me, participant:nil, type:Task.TaskType.Report) + +var todayTask:[Task] = [] +todayTask += [callTask, reportTask] +todayTask[1].time = 15*60 + +callTask.title = "Call to Toby" + +print("Today task = \(todayTask)") diff --git "a/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/instance_intialize.playground/contents.xcplayground" "b/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/instance_intialize.playground/contents.xcplayground" new file mode 100644 index 0000000..5da2641 --- /dev/null +++ "b/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/instance_intialize.playground/contents.xcplayground" @@ -0,0 +1,4 @@ + + + + \ No newline at end of file diff --git "a/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/instance_intialize.playground/playground.xcworkspace/contents.xcworkspacedata" "b/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/instance_intialize.playground/playground.xcworkspace/contents.xcworkspacedata" new file mode 100644 index 0000000..919434a --- /dev/null +++ "b/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/instance_intialize.playground/playground.xcworkspace/contents.xcworkspacedata" @@ -0,0 +1,7 @@ + + + + + diff --git "a/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/instance_intialize.playground/timeline.xctimeline" "b/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/instance_intialize.playground/timeline.xctimeline" new file mode 100644 index 0000000..da8edd3 --- /dev/null +++ "b/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/instance_intialize.playground/timeline.xctimeline" @@ -0,0 +1,16 @@ + + + + + + + + + diff --git "a/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/instance_structure.playground/Contents.swift" "b/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/instance_structure.playground/Contents.swift" new file mode 100644 index 0000000..7c82a18 --- /dev/null +++ "b/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/instance_structure.playground/Contents.swift" @@ -0,0 +1,33 @@ +//: Playground - noun: a place where people can play + +import UIKit + +/*구조체는 Class와 함께 데이터 모델의 중요한 구성요소 중 하나 +내부에 변수나 상수 또는 함수를 선언한 뒤 인스턴스(Instance)를 만들어서 사용한다 +주로 좌표나 크기처럼 간단한 값을 표현하는 데 많이 사용되어 왔다 +Swift에서 Class의 대안으로 그 역할이 커지고 있다 +*/ + +struct Task { + var title:String + var time:Int? +} + +var callTask = Task(title: "Call to Randy", time: 10*60) +var reportTask = Task(title: "report to Boss", time: nil) + +var todayTask:[Task] = [] +todayTask += [callTask, reportTask] +todayTask[1].time = 15*60 + +/*구조체는 Value Type + Value 타입의 인스턴스 + Int나 Double 과 같이 직접 값을 가지는 것 + Reference 타입의 인스턴스 + 인스턴스가 있는 메모리 번지를 참조하는 것 + Value 타입은 할당시에 인스턴스가 복사되지만 + Reference 타입은 할당시 참조하는 메모리 번지만 전달된다 + */ +callTask.title = "Call to Toby" + +print("Today task = \(todayTask)") diff --git "a/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/instance_structure.playground/contents.xcplayground" "b/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/instance_structure.playground/contents.xcplayground" new file mode 100644 index 0000000..5da2641 --- /dev/null +++ "b/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/instance_structure.playground/contents.xcplayground" @@ -0,0 +1,4 @@ + + + + \ No newline at end of file diff --git "a/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/instance_structure.playground/timeline.xctimeline" "b/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/instance_structure.playground/timeline.xctimeline" new file mode 100644 index 0000000..ecab9c1 --- /dev/null +++ "b/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/instance_structure.playground/timeline.xctimeline" @@ -0,0 +1,16 @@ + + + + + + + + + diff --git "a/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/interaction/interaction.xcodeproj/project.pbxproj" "b/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/interaction/interaction.xcodeproj/project.pbxproj" new file mode 100644 index 0000000..ddec32f --- /dev/null +++ "b/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/interaction/interaction.xcodeproj/project.pbxproj" @@ -0,0 +1,557 @@ +// !$*UTF8*$! +{ + archiveVersion = 1; + classes = { + }; + objectVersion = 48; + objects = { + +/* Begin PBXBuildFile section */ + AE4DD38A1F9B7CCC0009D236 /* AppDelegate.swift in Sources */ = {isa = PBXBuildFile; fileRef = AE4DD3891F9B7CCC0009D236 /* AppDelegate.swift */; }; + AE4DD38C1F9B7CCC0009D236 /* ViewController.swift in Sources */ = {isa = PBXBuildFile; fileRef = AE4DD38B1F9B7CCC0009D236 /* ViewController.swift */; }; + AE4DD38F1F9B7CCC0009D236 /* Main.storyboard in Resources */ = {isa = PBXBuildFile; fileRef = AE4DD38D1F9B7CCC0009D236 /* Main.storyboard */; }; + AE4DD3911F9B7CCC0009D236 /* Assets.xcassets in Resources */ = {isa = PBXBuildFile; fileRef = AE4DD3901F9B7CCC0009D236 /* Assets.xcassets */; }; + AE4DD3941F9B7CCC0009D236 /* LaunchScreen.storyboard in Resources */ = {isa = PBXBuildFile; fileRef = AE4DD3921F9B7CCC0009D236 /* LaunchScreen.storyboard */; }; + AE4DD39F1F9B7CCC0009D236 /* interactionTests.swift in Sources */ = {isa = PBXBuildFile; fileRef = AE4DD39E1F9B7CCC0009D236 /* interactionTests.swift */; }; + AE4DD3AA1F9B7CCC0009D236 /* interactionUITests.swift in Sources */ = {isa = PBXBuildFile; fileRef = AE4DD3A91F9B7CCC0009D236 /* interactionUITests.swift */; }; +/* End PBXBuildFile section */ + +/* Begin PBXContainerItemProxy section */ + AE4DD39B1F9B7CCC0009D236 /* PBXContainerItemProxy */ = { + isa = PBXContainerItemProxy; + containerPortal = AE4DD37E1F9B7CCC0009D236 /* Project object */; + proxyType = 1; + remoteGlobalIDString = AE4DD3851F9B7CCC0009D236; + remoteInfo = interaction; + }; + AE4DD3A61F9B7CCC0009D236 /* PBXContainerItemProxy */ = { + isa = PBXContainerItemProxy; + containerPortal = AE4DD37E1F9B7CCC0009D236 /* Project object */; + proxyType = 1; + remoteGlobalIDString = AE4DD3851F9B7CCC0009D236; + remoteInfo = interaction; + }; +/* End PBXContainerItemProxy section */ + +/* Begin PBXFileReference section */ + AE4DD3861F9B7CCC0009D236 /* interaction.app */ = {isa = PBXFileReference; explicitFileType = wrapper.application; includeInIndex = 0; path = interaction.app; sourceTree = BUILT_PRODUCTS_DIR; }; + AE4DD3891F9B7CCC0009D236 /* AppDelegate.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = AppDelegate.swift; sourceTree = ""; }; + AE4DD38B1F9B7CCC0009D236 /* ViewController.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = ViewController.swift; sourceTree = ""; }; + AE4DD38E1F9B7CCC0009D236 /* Base */ = {isa = PBXFileReference; lastKnownFileType = file.storyboard; name = Base; path = Base.lproj/Main.storyboard; sourceTree = ""; }; + AE4DD3901F9B7CCC0009D236 /* Assets.xcassets */ = {isa = PBXFileReference; lastKnownFileType = folder.assetcatalog; path = Assets.xcassets; sourceTree = ""; }; + AE4DD3931F9B7CCC0009D236 /* Base */ = {isa = PBXFileReference; lastKnownFileType = file.storyboard; name = Base; path = Base.lproj/LaunchScreen.storyboard; sourceTree = ""; }; + AE4DD3951F9B7CCC0009D236 /* Info.plist */ = {isa = PBXFileReference; lastKnownFileType = text.plist.xml; path = Info.plist; sourceTree = ""; }; + AE4DD39A1F9B7CCC0009D236 /* interactionTests.xctest */ = {isa = PBXFileReference; explicitFileType = wrapper.cfbundle; includeInIndex = 0; path = interactionTests.xctest; sourceTree = BUILT_PRODUCTS_DIR; }; + AE4DD39E1F9B7CCC0009D236 /* interactionTests.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = interactionTests.swift; sourceTree = ""; }; + AE4DD3A01F9B7CCC0009D236 /* Info.plist */ = {isa = PBXFileReference; lastKnownFileType = text.plist.xml; path = Info.plist; sourceTree = ""; }; + AE4DD3A51F9B7CCC0009D236 /* interactionUITests.xctest */ = {isa = PBXFileReference; explicitFileType = wrapper.cfbundle; includeInIndex = 0; path = interactionUITests.xctest; sourceTree = BUILT_PRODUCTS_DIR; }; + AE4DD3A91F9B7CCC0009D236 /* interactionUITests.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = interactionUITests.swift; sourceTree = ""; }; + AE4DD3AB1F9B7CCC0009D236 /* Info.plist */ = {isa = PBXFileReference; lastKnownFileType = text.plist.xml; path = Info.plist; sourceTree = ""; }; +/* End PBXFileReference section */ + +/* Begin PBXFrameworksBuildPhase section */ + AE4DD3831F9B7CCC0009D236 /* Frameworks */ = { + isa = PBXFrameworksBuildPhase; + buildActionMask = 2147483647; + files = ( + ); + runOnlyForDeploymentPostprocessing = 0; + }; + AE4DD3971F9B7CCC0009D236 /* Frameworks */ = { + isa = PBXFrameworksBuildPhase; + buildActionMask = 2147483647; + files = ( + ); + runOnlyForDeploymentPostprocessing = 0; + }; + AE4DD3A21F9B7CCC0009D236 /* Frameworks */ = { + isa = PBXFrameworksBuildPhase; + buildActionMask = 2147483647; + files = ( + ); + runOnlyForDeploymentPostprocessing = 0; + }; +/* End PBXFrameworksBuildPhase section */ + +/* Begin PBXGroup section */ + AE4DD37D1F9B7CCC0009D236 = { + isa = PBXGroup; + children = ( + AE4DD3881F9B7CCC0009D236 /* interaction */, + AE4DD39D1F9B7CCC0009D236 /* interactionTests */, + AE4DD3A81F9B7CCC0009D236 /* interactionUITests */, + AE4DD3871F9B7CCC0009D236 /* Products */, + ); + sourceTree = ""; + }; + AE4DD3871F9B7CCC0009D236 /* Products */ = { + isa = PBXGroup; + children = ( + AE4DD3861F9B7CCC0009D236 /* interaction.app */, + AE4DD39A1F9B7CCC0009D236 /* interactionTests.xctest */, + AE4DD3A51F9B7CCC0009D236 /* interactionUITests.xctest */, + ); + name = Products; + sourceTree = ""; + }; + AE4DD3881F9B7CCC0009D236 /* interaction */ = { + isa = PBXGroup; + children = ( + AE4DD3891F9B7CCC0009D236 /* AppDelegate.swift */, + AE4DD38B1F9B7CCC0009D236 /* ViewController.swift */, + AE4DD38D1F9B7CCC0009D236 /* Main.storyboard */, + AE4DD3901F9B7CCC0009D236 /* Assets.xcassets */, + AE4DD3921F9B7CCC0009D236 /* LaunchScreen.storyboard */, + AE4DD3951F9B7CCC0009D236 /* Info.plist */, + ); + path = interaction; + sourceTree = ""; + }; + AE4DD39D1F9B7CCC0009D236 /* interactionTests */ = { + isa = PBXGroup; + children = ( + AE4DD39E1F9B7CCC0009D236 /* interactionTests.swift */, + AE4DD3A01F9B7CCC0009D236 /* Info.plist */, + ); + path = interactionTests; + sourceTree = ""; + }; + AE4DD3A81F9B7CCC0009D236 /* interactionUITests */ = { + isa = PBXGroup; + children = ( + AE4DD3A91F9B7CCC0009D236 /* interactionUITests.swift */, + AE4DD3AB1F9B7CCC0009D236 /* Info.plist */, + ); + path = interactionUITests; + sourceTree = ""; + }; +/* End PBXGroup section */ + +/* Begin PBXNativeTarget section */ + AE4DD3851F9B7CCC0009D236 /* interaction */ = { + isa = PBXNativeTarget; + buildConfigurationList = AE4DD3AE1F9B7CCC0009D236 /* Build configuration list for PBXNativeTarget "interaction" */; + buildPhases = ( + AE4DD3821F9B7CCC0009D236 /* Sources */, + AE4DD3831F9B7CCC0009D236 /* Frameworks */, + AE4DD3841F9B7CCC0009D236 /* Resources */, + ); + buildRules = ( + ); + dependencies = ( + ); + name = interaction; + productName = interaction; + productReference = AE4DD3861F9B7CCC0009D236 /* interaction.app */; + productType = "com.apple.product-type.application"; + }; + AE4DD3991F9B7CCC0009D236 /* interactionTests */ = { + isa = PBXNativeTarget; + buildConfigurationList = AE4DD3B11F9B7CCC0009D236 /* Build configuration list for PBXNativeTarget "interactionTests" */; + buildPhases = ( + AE4DD3961F9B7CCC0009D236 /* Sources */, + AE4DD3971F9B7CCC0009D236 /* Frameworks */, + AE4DD3981F9B7CCC0009D236 /* Resources */, + ); + buildRules = ( + ); + dependencies = ( + AE4DD39C1F9B7CCC0009D236 /* PBXTargetDependency */, + ); + name = interactionTests; + productName = interactionTests; + productReference = AE4DD39A1F9B7CCC0009D236 /* interactionTests.xctest */; + productType = "com.apple.product-type.bundle.unit-test"; + }; + AE4DD3A41F9B7CCC0009D236 /* interactionUITests */ = { + isa = PBXNativeTarget; + buildConfigurationList = AE4DD3B41F9B7CCC0009D236 /* Build configuration list for PBXNativeTarget "interactionUITests" */; + buildPhases = ( + AE4DD3A11F9B7CCC0009D236 /* Sources */, + AE4DD3A21F9B7CCC0009D236 /* Frameworks */, + AE4DD3A31F9B7CCC0009D236 /* Resources */, + ); + buildRules = ( + ); + dependencies = ( + AE4DD3A71F9B7CCC0009D236 /* PBXTargetDependency */, + ); + name = interactionUITests; + productName = interactionUITests; + productReference = AE4DD3A51F9B7CCC0009D236 /* interactionUITests.xctest */; + productType = "com.apple.product-type.bundle.ui-testing"; + }; +/* End PBXNativeTarget section */ + +/* Begin PBXProject section */ + AE4DD37E1F9B7CCC0009D236 /* Project object */ = { + isa = PBXProject; + attributes = { + LastSwiftUpdateCheck = 0900; + LastUpgradeCheck = 0900; + ORGANIZATIONNAME = "황도증"; + TargetAttributes = { + AE4DD3851F9B7CCC0009D236 = { + CreatedOnToolsVersion = 9.0.1; + ProvisioningStyle = Automatic; + }; + AE4DD3991F9B7CCC0009D236 = { + CreatedOnToolsVersion = 9.0.1; + ProvisioningStyle = Automatic; + TestTargetID = AE4DD3851F9B7CCC0009D236; + }; + AE4DD3A41F9B7CCC0009D236 = { + CreatedOnToolsVersion = 9.0.1; + ProvisioningStyle = Automatic; + TestTargetID = AE4DD3851F9B7CCC0009D236; + }; + }; + }; + buildConfigurationList = AE4DD3811F9B7CCC0009D236 /* Build configuration list for PBXProject "interaction" */; + compatibilityVersion = "Xcode 8.0"; + developmentRegion = en; + hasScannedForEncodings = 0; + knownRegions = ( + en, + Base, + ); + mainGroup = AE4DD37D1F9B7CCC0009D236; + productRefGroup = AE4DD3871F9B7CCC0009D236 /* Products */; + projectDirPath = ""; + projectRoot = ""; + targets = ( + AE4DD3851F9B7CCC0009D236 /* interaction */, + AE4DD3991F9B7CCC0009D236 /* interactionTests */, + AE4DD3A41F9B7CCC0009D236 /* interactionUITests */, + ); + }; +/* End PBXProject section */ + +/* Begin PBXResourcesBuildPhase section */ + AE4DD3841F9B7CCC0009D236 /* Resources */ = { + isa = PBXResourcesBuildPhase; + buildActionMask = 2147483647; + files = ( + AE4DD3941F9B7CCC0009D236 /* LaunchScreen.storyboard in Resources */, + AE4DD3911F9B7CCC0009D236 /* Assets.xcassets in Resources */, + AE4DD38F1F9B7CCC0009D236 /* Main.storyboard in Resources */, + ); + runOnlyForDeploymentPostprocessing = 0; + }; + AE4DD3981F9B7CCC0009D236 /* Resources */ = { + isa = PBXResourcesBuildPhase; + buildActionMask = 2147483647; + files = ( + ); + runOnlyForDeploymentPostprocessing = 0; + }; + AE4DD3A31F9B7CCC0009D236 /* Resources */ = { + isa = PBXResourcesBuildPhase; + buildActionMask = 2147483647; + files = ( + ); + runOnlyForDeploymentPostprocessing = 0; + }; +/* End PBXResourcesBuildPhase section */ + +/* Begin PBXSourcesBuildPhase section */ + AE4DD3821F9B7CCC0009D236 /* Sources */ = { + isa = PBXSourcesBuildPhase; + buildActionMask = 2147483647; + files = ( + AE4DD38C1F9B7CCC0009D236 /* ViewController.swift in Sources */, + AE4DD38A1F9B7CCC0009D236 /* AppDelegate.swift in Sources */, + ); + runOnlyForDeploymentPostprocessing = 0; + }; + AE4DD3961F9B7CCC0009D236 /* Sources */ = { + isa = PBXSourcesBuildPhase; + buildActionMask = 2147483647; + files = ( + AE4DD39F1F9B7CCC0009D236 /* interactionTests.swift in Sources */, + ); + runOnlyForDeploymentPostprocessing = 0; + }; + AE4DD3A11F9B7CCC0009D236 /* Sources */ = { + isa = PBXSourcesBuildPhase; + buildActionMask = 2147483647; + files = ( + AE4DD3AA1F9B7CCC0009D236 /* interactionUITests.swift in Sources */, + ); + runOnlyForDeploymentPostprocessing = 0; + }; +/* End PBXSourcesBuildPhase section */ + +/* Begin PBXTargetDependency section */ + AE4DD39C1F9B7CCC0009D236 /* PBXTargetDependency */ = { + isa = PBXTargetDependency; + target = AE4DD3851F9B7CCC0009D236 /* interaction */; + targetProxy = AE4DD39B1F9B7CCC0009D236 /* PBXContainerItemProxy */; + }; + AE4DD3A71F9B7CCC0009D236 /* PBXTargetDependency */ = { + isa = PBXTargetDependency; + target = AE4DD3851F9B7CCC0009D236 /* interaction */; + targetProxy = AE4DD3A61F9B7CCC0009D236 /* PBXContainerItemProxy */; + }; +/* End PBXTargetDependency section */ + +/* Begin PBXVariantGroup section */ + AE4DD38D1F9B7CCC0009D236 /* Main.storyboard */ = { + isa = PBXVariantGroup; + children = ( + AE4DD38E1F9B7CCC0009D236 /* Base */, + ); + name = Main.storyboard; + sourceTree = ""; + }; + AE4DD3921F9B7CCC0009D236 /* LaunchScreen.storyboard */ = { + isa = PBXVariantGroup; + children = ( + AE4DD3931F9B7CCC0009D236 /* Base */, + ); + name = LaunchScreen.storyboard; + sourceTree = ""; + }; +/* End PBXVariantGroup section */ + +/* Begin XCBuildConfiguration section */ + AE4DD3AC1F9B7CCC0009D236 /* Debug */ = { + isa = XCBuildConfiguration; + buildSettings = { + ALWAYS_SEARCH_USER_PATHS = NO; + CLANG_ANALYZER_NONNULL = YES; + CLANG_ANALYZER_NUMBER_OBJECT_CONVERSION = YES_AGGRESSIVE; + CLANG_CXX_LANGUAGE_STANDARD = "gnu++14"; + CLANG_CXX_LIBRARY = "libc++"; + CLANG_ENABLE_MODULES = YES; + CLANG_ENABLE_OBJC_ARC = YES; + CLANG_WARN_BLOCK_CAPTURE_AUTORELEASING = YES; + CLANG_WARN_BOOL_CONVERSION = YES; + CLANG_WARN_COMMA = YES; + CLANG_WARN_CONSTANT_CONVERSION = YES; + CLANG_WARN_DIRECT_OBJC_ISA_USAGE = YES_ERROR; + CLANG_WARN_DOCUMENTATION_COMMENTS = YES; + CLANG_WARN_EMPTY_BODY = YES; + CLANG_WARN_ENUM_CONVERSION = YES; + CLANG_WARN_INFINITE_RECURSION = YES; + CLANG_WARN_INT_CONVERSION = YES; + CLANG_WARN_NON_LITERAL_NULL_CONVERSION = YES; + CLANG_WARN_OBJC_LITERAL_CONVERSION = YES; + CLANG_WARN_OBJC_ROOT_CLASS = YES_ERROR; + CLANG_WARN_RANGE_LOOP_ANALYSIS = YES; + CLANG_WARN_STRICT_PROTOTYPES = YES; + CLANG_WARN_SUSPICIOUS_MOVE = YES; + CLANG_WARN_UNGUARDED_AVAILABILITY = YES_AGGRESSIVE; + CLANG_WARN_UNREACHABLE_CODE = YES; + CLANG_WARN__DUPLICATE_METHOD_MATCH = YES; + CODE_SIGN_IDENTITY = "iPhone Developer"; + COPY_PHASE_STRIP = NO; + DEBUG_INFORMATION_FORMAT = dwarf; + ENABLE_STRICT_OBJC_MSGSEND = YES; + ENABLE_TESTABILITY = YES; + GCC_C_LANGUAGE_STANDARD = gnu11; + GCC_DYNAMIC_NO_PIC = NO; + GCC_NO_COMMON_BLOCKS = YES; + GCC_OPTIMIZATION_LEVEL = 0; + GCC_PREPROCESSOR_DEFINITIONS = ( + "DEBUG=1", + "$(inherited)", + ); + GCC_WARN_64_TO_32_BIT_CONVERSION = YES; + GCC_WARN_ABOUT_RETURN_TYPE = YES_ERROR; + GCC_WARN_UNDECLARED_SELECTOR = YES; + GCC_WARN_UNINITIALIZED_AUTOS = YES_AGGRESSIVE; + GCC_WARN_UNUSED_FUNCTION = YES; + GCC_WARN_UNUSED_VARIABLE = YES; + IPHONEOS_DEPLOYMENT_TARGET = 11.0; + MTL_ENABLE_DEBUG_INFO = YES; + ONLY_ACTIVE_ARCH = YES; + SDKROOT = iphoneos; + SWIFT_ACTIVE_COMPILATION_CONDITIONS = DEBUG; + SWIFT_OPTIMIZATION_LEVEL = "-Onone"; + }; + name = Debug; + }; + AE4DD3AD1F9B7CCC0009D236 /* Release */ = { + isa = XCBuildConfiguration; + buildSettings = { + ALWAYS_SEARCH_USER_PATHS = NO; + CLANG_ANALYZER_NONNULL = YES; + CLANG_ANALYZER_NUMBER_OBJECT_CONVERSION = YES_AGGRESSIVE; + CLANG_CXX_LANGUAGE_STANDARD = "gnu++14"; + CLANG_CXX_LIBRARY = "libc++"; + CLANG_ENABLE_MODULES = YES; + CLANG_ENABLE_OBJC_ARC = YES; + CLANG_WARN_BLOCK_CAPTURE_AUTORELEASING = YES; + CLANG_WARN_BOOL_CONVERSION = YES; + CLANG_WARN_COMMA = YES; + CLANG_WARN_CONSTANT_CONVERSION = YES; + CLANG_WARN_DIRECT_OBJC_ISA_USAGE = YES_ERROR; + CLANG_WARN_DOCUMENTATION_COMMENTS = YES; + CLANG_WARN_EMPTY_BODY = YES; + CLANG_WARN_ENUM_CONVERSION = YES; + CLANG_WARN_INFINITE_RECURSION = YES; + CLANG_WARN_INT_CONVERSION = YES; + CLANG_WARN_NON_LITERAL_NULL_CONVERSION = YES; + CLANG_WARN_OBJC_LITERAL_CONVERSION = YES; + CLANG_WARN_OBJC_ROOT_CLASS = YES_ERROR; + CLANG_WARN_RANGE_LOOP_ANALYSIS = YES; + CLANG_WARN_STRICT_PROTOTYPES = YES; + CLANG_WARN_SUSPICIOUS_MOVE = YES; + CLANG_WARN_UNGUARDED_AVAILABILITY = YES_AGGRESSIVE; + CLANG_WARN_UNREACHABLE_CODE = YES; + CLANG_WARN__DUPLICATE_METHOD_MATCH = YES; + CODE_SIGN_IDENTITY = "iPhone Developer"; + COPY_PHASE_STRIP = NO; + DEBUG_INFORMATION_FORMAT = "dwarf-with-dsym"; + ENABLE_NS_ASSERTIONS = NO; + ENABLE_STRICT_OBJC_MSGSEND = YES; + GCC_C_LANGUAGE_STANDARD = gnu11; + GCC_NO_COMMON_BLOCKS = YES; + GCC_WARN_64_TO_32_BIT_CONVERSION = YES; + GCC_WARN_ABOUT_RETURN_TYPE = YES_ERROR; + GCC_WARN_UNDECLARED_SELECTOR = YES; + GCC_WARN_UNINITIALIZED_AUTOS = YES_AGGRESSIVE; + GCC_WARN_UNUSED_FUNCTION = YES; + GCC_WARN_UNUSED_VARIABLE = YES; + IPHONEOS_DEPLOYMENT_TARGET = 11.0; + MTL_ENABLE_DEBUG_INFO = NO; + SDKROOT = iphoneos; + SWIFT_OPTIMIZATION_LEVEL = "-Owholemodule"; + VALIDATE_PRODUCT = YES; + }; + name = Release; + }; + AE4DD3AF1F9B7CCC0009D236 /* Debug */ = { + isa = XCBuildConfiguration; + buildSettings = { + ASSETCATALOG_COMPILER_APPICON_NAME = AppIcon; + CODE_SIGN_STYLE = Automatic; + INFOPLIST_FILE = interaction/Info.plist; + LD_RUNPATH_SEARCH_PATHS = "$(inherited) @executable_path/Frameworks"; + PRODUCT_BUNDLE_IDENTIFIER = "--------.interaction"; + PRODUCT_NAME = "$(TARGET_NAME)"; + SWIFT_VERSION = 4.0; + TARGETED_DEVICE_FAMILY = "1,2"; + }; + name = Debug; + }; + AE4DD3B01F9B7CCC0009D236 /* Release */ = { + isa = XCBuildConfiguration; + buildSettings = { + ASSETCATALOG_COMPILER_APPICON_NAME = AppIcon; + CODE_SIGN_STYLE = Automatic; + INFOPLIST_FILE = interaction/Info.plist; + LD_RUNPATH_SEARCH_PATHS = "$(inherited) @executable_path/Frameworks"; + PRODUCT_BUNDLE_IDENTIFIER = "--------.interaction"; + PRODUCT_NAME = "$(TARGET_NAME)"; + SWIFT_VERSION = 4.0; + TARGETED_DEVICE_FAMILY = "1,2"; + }; + name = Release; + }; + AE4DD3B21F9B7CCC0009D236 /* Debug */ = { + isa = XCBuildConfiguration; + buildSettings = { + ALWAYS_EMBED_SWIFT_STANDARD_LIBRARIES = YES; + BUNDLE_LOADER = "$(TEST_HOST)"; + CODE_SIGN_STYLE = Automatic; + INFOPLIST_FILE = interactionTests/Info.plist; + LD_RUNPATH_SEARCH_PATHS = "$(inherited) @executable_path/Frameworks @loader_path/Frameworks"; + PRODUCT_BUNDLE_IDENTIFIER = "--------.interactionTests"; + PRODUCT_NAME = "$(TARGET_NAME)"; + SWIFT_VERSION = 4.0; + TARGETED_DEVICE_FAMILY = "1,2"; + TEST_HOST = "$(BUILT_PRODUCTS_DIR)/interaction.app/interaction"; + }; + name = Debug; + }; + AE4DD3B31F9B7CCC0009D236 /* Release */ = { + isa = XCBuildConfiguration; + buildSettings = { + ALWAYS_EMBED_SWIFT_STANDARD_LIBRARIES = YES; + BUNDLE_LOADER = "$(TEST_HOST)"; + CODE_SIGN_STYLE = Automatic; + INFOPLIST_FILE = interactionTests/Info.plist; + LD_RUNPATH_SEARCH_PATHS = "$(inherited) @executable_path/Frameworks @loader_path/Frameworks"; + PRODUCT_BUNDLE_IDENTIFIER = "--------.interactionTests"; + PRODUCT_NAME = "$(TARGET_NAME)"; + SWIFT_VERSION = 4.0; + TARGETED_DEVICE_FAMILY = "1,2"; + TEST_HOST = "$(BUILT_PRODUCTS_DIR)/interaction.app/interaction"; + }; + name = Release; + }; + AE4DD3B51F9B7CCC0009D236 /* Debug */ = { + isa = XCBuildConfiguration; + buildSettings = { + ALWAYS_EMBED_SWIFT_STANDARD_LIBRARIES = YES; + CODE_SIGN_STYLE = Automatic; + INFOPLIST_FILE = interactionUITests/Info.plist; + LD_RUNPATH_SEARCH_PATHS = "$(inherited) @executable_path/Frameworks @loader_path/Frameworks"; + PRODUCT_BUNDLE_IDENTIFIER = "--------.interactionUITests"; + PRODUCT_NAME = "$(TARGET_NAME)"; + SWIFT_VERSION = 4.0; + TARGETED_DEVICE_FAMILY = "1,2"; + TEST_TARGET_NAME = interaction; + }; + name = Debug; + }; + AE4DD3B61F9B7CCC0009D236 /* Release */ = { + isa = XCBuildConfiguration; + buildSettings = { + ALWAYS_EMBED_SWIFT_STANDARD_LIBRARIES = YES; + CODE_SIGN_STYLE = Automatic; + INFOPLIST_FILE = interactionUITests/Info.plist; + LD_RUNPATH_SEARCH_PATHS = "$(inherited) @executable_path/Frameworks @loader_path/Frameworks"; + PRODUCT_BUNDLE_IDENTIFIER = "--------.interactionUITests"; + PRODUCT_NAME = "$(TARGET_NAME)"; + SWIFT_VERSION = 4.0; + TARGETED_DEVICE_FAMILY = "1,2"; + TEST_TARGET_NAME = interaction; + }; + name = Release; + }; +/* End XCBuildConfiguration section */ + +/* Begin XCConfigurationList section */ + AE4DD3811F9B7CCC0009D236 /* Build configuration list for PBXProject "interaction" */ = { + isa = XCConfigurationList; + buildConfigurations = ( + AE4DD3AC1F9B7CCC0009D236 /* Debug */, + AE4DD3AD1F9B7CCC0009D236 /* Release */, + ); + defaultConfigurationIsVisible = 0; + defaultConfigurationName = Release; + }; + AE4DD3AE1F9B7CCC0009D236 /* Build configuration list for PBXNativeTarget "interaction" */ = { + isa = XCConfigurationList; + buildConfigurations = ( + AE4DD3AF1F9B7CCC0009D236 /* Debug */, + AE4DD3B01F9B7CCC0009D236 /* Release */, + ); + defaultConfigurationIsVisible = 0; + defaultConfigurationName = Release; + }; + AE4DD3B11F9B7CCC0009D236 /* Build configuration list for PBXNativeTarget "interactionTests" */ = { + isa = XCConfigurationList; + buildConfigurations = ( + AE4DD3B21F9B7CCC0009D236 /* Debug */, + AE4DD3B31F9B7CCC0009D236 /* Release */, + ); + defaultConfigurationIsVisible = 0; + defaultConfigurationName = Release; + }; + AE4DD3B41F9B7CCC0009D236 /* Build configuration list for PBXNativeTarget "interactionUITests" */ = { + isa = XCConfigurationList; + buildConfigurations = ( + AE4DD3B51F9B7CCC0009D236 /* Debug */, + AE4DD3B61F9B7CCC0009D236 /* Release */, + ); + defaultConfigurationIsVisible = 0; + defaultConfigurationName = Release; + }; +/* End XCConfigurationList section */ + }; + rootObject = AE4DD37E1F9B7CCC0009D236 /* Project object */; +} diff --git "a/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/interaction/interaction.xcodeproj/project.xcworkspace/contents.xcworkspacedata" "b/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/interaction/interaction.xcodeproj/project.xcworkspace/contents.xcworkspacedata" new file mode 100644 index 0000000..0385138 --- /dev/null +++ "b/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/interaction/interaction.xcodeproj/project.xcworkspace/contents.xcworkspacedata" @@ -0,0 +1,7 @@ + + + + + diff --git "a/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/interaction/interaction/AppDelegate.swift" "b/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/interaction/interaction/AppDelegate.swift" new file mode 100644 index 0000000..fad47e1 --- /dev/null +++ "b/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/interaction/interaction/AppDelegate.swift" @@ -0,0 +1,46 @@ +// +// AppDelegate.swift +// interaction +// +// Created by 황도증 on 2017. 10. 21.. +// Copyright © 2017년 황도증. All rights reserved. +// + +import UIKit + +@UIApplicationMain +class AppDelegate: UIResponder, UIApplicationDelegate { + + var window: UIWindow? + + + func application(_ application: UIApplication, didFinishLaunchingWithOptions launchOptions: [UIApplicationLaunchOptionsKey: Any]?) -> Bool { + // Override point for customization after application launch. + return true + } + + func applicationWillResignActive(_ application: UIApplication) { + // Sent when the application is about to move from active to inactive state. This can occur for certain types of temporary interruptions (such as an incoming phone call or SMS message) or when the user quits the application and it begins the transition to the background state. + // Use this method to pause ongoing tasks, disable timers, and invalidate graphics rendering callbacks. Games should use this method to pause the game. + } + + func applicationDidEnterBackground(_ application: UIApplication) { + // Use this method to release shared resources, save user data, invalidate timers, and store enough application state information to restore your application to its current state in case it is terminated later. + // If your application supports background execution, this method is called instead of applicationWillTerminate: when the user quits. + } + + func applicationWillEnterForeground(_ application: UIApplication) { + // Called as part of the transition from the background to the active state; here you can undo many of the changes made on entering the background. + } + + func applicationDidBecomeActive(_ application: UIApplication) { + // Restart any tasks that were paused (or not yet started) while the application was inactive. If the application was previously in the background, optionally refresh the user interface. + } + + func applicationWillTerminate(_ application: UIApplication) { + // Called when the application is about to terminate. Save data if appropriate. See also applicationDidEnterBackground:. + } + + +} + diff --git "a/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/interaction/interaction/Assets.xcassets/AppIcon.appiconset/Contents.json" "b/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/interaction/interaction/Assets.xcassets/AppIcon.appiconset/Contents.json" new file mode 100644 index 0000000..1d060ed --- /dev/null +++ "b/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/interaction/interaction/Assets.xcassets/AppIcon.appiconset/Contents.json" @@ -0,0 +1,93 @@ +{ + "images" : [ + { + "idiom" : "iphone", + "size" : "20x20", + "scale" : "2x" + }, + { + "idiom" : "iphone", + "size" : "20x20", + "scale" : "3x" + }, + { + "idiom" : "iphone", + "size" : "29x29", + "scale" : "2x" + }, + { + "idiom" : "iphone", + "size" : "29x29", + "scale" : "3x" + }, + { + "idiom" : "iphone", + "size" : "40x40", + "scale" : "2x" + }, + { + "idiom" : "iphone", + "size" : "40x40", + "scale" : "3x" + }, + { + "idiom" : "iphone", + "size" : "60x60", + "scale" : "2x" + }, + { + "idiom" : "iphone", + "size" : "60x60", + "scale" : "3x" + }, + { + "idiom" : "ipad", + "size" : "20x20", + "scale" : "1x" + }, + { + "idiom" : "ipad", + "size" : "20x20", + "scale" : "2x" + }, + { + "idiom" : "ipad", + "size" : "29x29", + "scale" : "1x" + }, + { + "idiom" : "ipad", + "size" : "29x29", + "scale" : "2x" + }, + { + "idiom" : "ipad", + "size" : "40x40", + "scale" : "1x" + }, + { + "idiom" : "ipad", + "size" : "40x40", + "scale" : "2x" + }, + { + "idiom" : "ipad", + "size" : "76x76", + "scale" : "1x" + }, + { + "idiom" : "ipad", + "size" : "76x76", + "scale" : "2x" + }, + { + "idiom" : "ipad", + "size" : "83.5x83.5", + "scale" : "2x" + } + ], + "info" : { + "version" : 1, + "author" : "xcode" + } +} \ No newline at end of file diff --git "a/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/interaction/interaction/Base.lproj/LaunchScreen.storyboard" "b/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/interaction/interaction/Base.lproj/LaunchScreen.storyboard" new file mode 100644 index 0000000..f83f6fd --- /dev/null +++ "b/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/interaction/interaction/Base.lproj/LaunchScreen.storyboard" @@ -0,0 +1,25 @@ + + + + + + + + + + + + + + + + + + + + + + + + + diff --git "a/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/interaction/interaction/Base.lproj/Main.storyboard" "b/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/interaction/interaction/Base.lproj/Main.storyboard" new file mode 100644 index 0000000..4e48970 --- /dev/null +++ "b/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/interaction/interaction/Base.lproj/Main.storyboard" @@ -0,0 +1,47 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + diff --git "a/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/interaction/interaction/Info.plist" "b/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/interaction/interaction/Info.plist" new file mode 100644 index 0000000..16be3b6 --- /dev/null +++ "b/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/interaction/interaction/Info.plist" @@ -0,0 +1,45 @@ + + + + + CFBundleDevelopmentRegion + $(DEVELOPMENT_LANGUAGE) + CFBundleExecutable + $(EXECUTABLE_NAME) + CFBundleIdentifier + $(PRODUCT_BUNDLE_IDENTIFIER) + CFBundleInfoDictionaryVersion + 6.0 + CFBundleName + $(PRODUCT_NAME) + CFBundlePackageType + APPL + CFBundleShortVersionString + 1.0 + CFBundleVersion + 1 + LSRequiresIPhoneOS + + UILaunchStoryboardName + LaunchScreen + UIMainStoryboardFile + Main + UIRequiredDeviceCapabilities + + armv7 + + UISupportedInterfaceOrientations + + UIInterfaceOrientationPortrait + UIInterfaceOrientationLandscapeLeft + UIInterfaceOrientationLandscapeRight + + UISupportedInterfaceOrientations~ipad + + UIInterfaceOrientationPortrait + UIInterfaceOrientationPortraitUpsideDown + UIInterfaceOrientationLandscapeLeft + UIInterfaceOrientationLandscapeRight + + + diff --git "a/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/interaction/interaction/ViewController.swift" "b/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/interaction/interaction/ViewController.swift" new file mode 100644 index 0000000..ea49598 --- /dev/null +++ "b/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/interaction/interaction/ViewController.swift" @@ -0,0 +1,30 @@ +// +// ViewController.swift +// interaction +// +// Created by 황도증 on 2017. 10. 21.. +// Copyright © 2017년 황도증. All rights reserved. +// + +import UIKit + +class ViewController: UIViewController { + + @IBOutlet weak var myText: UILabel! + + override func viewDidLoad() { + super.viewDidLoad() + // Do any additional setup after loading the view, typically from a nib. + } + + override func didReceiveMemoryWarning() { + super.didReceiveMemoryWarning() + // Dispose of any resources that can be recreated. + } + + @IBAction func myButton(_ sender: Any) { + myText.text = "Hello, iPhone" + } + +} + diff --git "a/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/interaction/interactionTests/Info.plist" "b/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/interaction/interactionTests/Info.plist" new file mode 100644 index 0000000..6c40a6c --- /dev/null +++ "b/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/interaction/interactionTests/Info.plist" @@ -0,0 +1,22 @@ + + + + + CFBundleDevelopmentRegion + $(DEVELOPMENT_LANGUAGE) + CFBundleExecutable + $(EXECUTABLE_NAME) + CFBundleIdentifier + $(PRODUCT_BUNDLE_IDENTIFIER) + CFBundleInfoDictionaryVersion + 6.0 + CFBundleName + $(PRODUCT_NAME) + CFBundlePackageType + BNDL + CFBundleShortVersionString + 1.0 + CFBundleVersion + 1 + + diff --git "a/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/interaction/interactionTests/interactionTests.swift" "b/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/interaction/interactionTests/interactionTests.swift" new file mode 100644 index 0000000..c4e8800 --- /dev/null +++ "b/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/interaction/interactionTests/interactionTests.swift" @@ -0,0 +1,36 @@ +// +// interactionTests.swift +// interactionTests +// +// Created by 황도증 on 2017. 10. 21.. +// Copyright © 2017년 황도증. All rights reserved. +// + +import XCTest +@testable import interaction + +class interactionTests: XCTestCase { + + override func setUp() { + super.setUp() + // Put setup code here. This method is called before the invocation of each test method in the class. + } + + override func tearDown() { + // Put teardown code here. This method is called after the invocation of each test method in the class. + super.tearDown() + } + + func testExample() { + // This is an example of a functional test case. + // Use XCTAssert and related functions to verify your tests produce the correct results. + } + + func testPerformanceExample() { + // This is an example of a performance test case. + self.measure { + // Put the code you want to measure the time of here. + } + } + +} diff --git "a/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/interaction/interactionUITests/Info.plist" "b/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/interaction/interactionUITests/Info.plist" new file mode 100644 index 0000000..6c40a6c --- /dev/null +++ "b/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/interaction/interactionUITests/Info.plist" @@ -0,0 +1,22 @@ + + + + + CFBundleDevelopmentRegion + $(DEVELOPMENT_LANGUAGE) + CFBundleExecutable + $(EXECUTABLE_NAME) + CFBundleIdentifier + $(PRODUCT_BUNDLE_IDENTIFIER) + CFBundleInfoDictionaryVersion + 6.0 + CFBundleName + $(PRODUCT_NAME) + CFBundlePackageType + BNDL + CFBundleShortVersionString + 1.0 + CFBundleVersion + 1 + + diff --git "a/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/interaction/interactionUITests/interactionUITests.swift" "b/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/interaction/interactionUITests/interactionUITests.swift" new file mode 100644 index 0000000..4cc426f --- /dev/null +++ "b/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/interaction/interactionUITests/interactionUITests.swift" @@ -0,0 +1,36 @@ +// +// interactionUITests.swift +// interactionUITests +// +// Created by 황도증 on 2017. 10. 21.. +// Copyright © 2017년 황도증. All rights reserved. +// + +import XCTest + +class interactionUITests: XCTestCase { + + override func setUp() { + super.setUp() + + // Put setup code here. This method is called before the invocation of each test method in the class. + + // In UI tests it is usually best to stop immediately when a failure occurs. + continueAfterFailure = false + // UI tests must launch the application that they test. Doing this in setup will make sure it happens for each test method. + XCUIApplication().launch() + + // In UI tests it’s important to set the initial state - such as interface orientation - required for your tests before they run. The setUp method is a good place to do this. + } + + override func tearDown() { + // Put teardown code here. This method is called after the invocation of each test method in the class. + super.tearDown() + } + + func testExample() { + // Use recording to get started writing UI tests. + // Use XCTAssert and related functions to verify your tests produce the correct results. + } + +} diff --git "a/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/let&var.playground/Contents.swift" "b/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/let&var.playground/Contents.swift" new file mode 100644 index 0000000..4b01c35 --- /dev/null +++ "b/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/let&var.playground/Contents.swift" @@ -0,0 +1,20 @@ +//: Playground - noun: a place where people can play + +import UIKit + +let macSpeed:Int = 300 + +var currentSpeed = 20 +currentSpeed += 20 +//currentSpeed += 10.5 + +//판교역 도착 방송을 위해 작성한 코드에서 문제가 생겼습니다. 어디가 문제인지 알아내, 방송이 무사히 전달될 수 있도록 코드를 수정해주세요. + +var announcement:String = "" +let intro = "다음 역은 " +let outro = "입니다." + +let station = "판교역" + +announcement = intro + station + outro +print(announcement) diff --git "a/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/let&var.playground/contents.xcplayground" "b/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/let&var.playground/contents.xcplayground" new file mode 100644 index 0000000..5da2641 --- /dev/null +++ "b/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/let&var.playground/contents.xcplayground" @@ -0,0 +1,4 @@ + + + + \ No newline at end of file diff --git "a/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/let&var.playground/playground.xcworkspace/contents.xcworkspacedata" "b/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/let&var.playground/playground.xcworkspace/contents.xcworkspacedata" new file mode 100644 index 0000000..919434a --- /dev/null +++ "b/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/let&var.playground/playground.xcworkspace/contents.xcworkspacedata" @@ -0,0 +1,7 @@ + + + + + diff --git "a/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/map.playground/Contents.swift" "b/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/map.playground/Contents.swift" new file mode 100644 index 0000000..d16f975 --- /dev/null +++ "b/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/map.playground/Contents.swift" @@ -0,0 +1,36 @@ +//: Playground - noun: a place where people can play + +import UIKit + +/*고차함수 map + map을 활용해 반복문을 대체한다 + + map 함수는 배열과 함수를 매개변수로 받아서, 배열의 항목 하나하나에 매개변수로 받은 함수를 적용하는 함수이다. + [a, b, c, d].map{f(x)} + -> [f(a), f(b), f(c), f(d)] + + transactions 배열에 map 적용하기 + 배열의 값은 Double + 함수는 Double을 받아 Double을 리턴 + 배열의 값 각각에 함수를 적용한 결과 배열을 생성 + */ + +let transactions = [600.0, 403.3, 408.3, 562.3, 902.2] + +func addVAT (source: Double) -> Double { + return source * 1.1 +} + +var vatPrices:[Double] = [] + +for transaction in transactions { + vatPrices += [addVAT(source: transaction)] +} + +//map +let vatMapPrice = transactions.map({transaction -> Double in + return transaction * 1.1 +}) + +//축약 +let vatMapprice2 = transactions.map({ $0 * 1.1 }) diff --git "a/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/map.playground/contents.xcplayground" "b/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/map.playground/contents.xcplayground" new file mode 100644 index 0000000..5da2641 --- /dev/null +++ "b/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/map.playground/contents.xcplayground" @@ -0,0 +1,4 @@ + + + + \ No newline at end of file diff --git "a/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/map.playground/playground.xcworkspace/contents.xcworkspacedata" "b/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/map.playground/playground.xcworkspace/contents.xcworkspacedata" new file mode 100644 index 0000000..919434a --- /dev/null +++ "b/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/map.playground/playground.xcworkspace/contents.xcworkspacedata" @@ -0,0 +1,7 @@ + + + + + diff --git "a/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/meetingRooms/meetingRooms.xcodeproj/project.pbxproj" "b/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/meetingRooms/meetingRooms.xcodeproj/project.pbxproj" new file mode 100644 index 0000000..c09b5be --- /dev/null +++ "b/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/meetingRooms/meetingRooms.xcodeproj/project.pbxproj" @@ -0,0 +1,561 @@ +// !$*UTF8*$! +{ + archiveVersion = 1; + classes = { + }; + objectVersion = 48; + objects = { + +/* Begin PBXBuildFile section */ + AE99575B1FA704AF00397D38 /* AppDelegate.swift in Sources */ = {isa = PBXBuildFile; fileRef = AE99575A1FA704AF00397D38 /* AppDelegate.swift */; }; + AE99575D1FA704AF00397D38 /* ViewController.swift in Sources */ = {isa = PBXBuildFile; fileRef = AE99575C1FA704AF00397D38 /* ViewController.swift */; }; + AE9957601FA704AF00397D38 /* Main.storyboard in Resources */ = {isa = PBXBuildFile; fileRef = AE99575E1FA704AF00397D38 /* Main.storyboard */; }; + AE9957621FA704AF00397D38 /* Assets.xcassets in Resources */ = {isa = PBXBuildFile; fileRef = AE9957611FA704AF00397D38 /* Assets.xcassets */; }; + AE9957651FA704AF00397D38 /* LaunchScreen.storyboard in Resources */ = {isa = PBXBuildFile; fileRef = AE9957631FA704AF00397D38 /* LaunchScreen.storyboard */; }; + AE9957701FA704AF00397D38 /* meetingRoomsTests.swift in Sources */ = {isa = PBXBuildFile; fileRef = AE99576F1FA704AF00397D38 /* meetingRoomsTests.swift */; }; + AE99577B1FA704B000397D38 /* meetingRoomsUITests.swift in Sources */ = {isa = PBXBuildFile; fileRef = AE99577A1FA704B000397D38 /* meetingRoomsUITests.swift */; }; + AE9957891FA7054800397D38 /* MeetingRoomListViewController.swift in Sources */ = {isa = PBXBuildFile; fileRef = AE9957881FA7054800397D38 /* MeetingRoomListViewController.swift */; }; +/* End PBXBuildFile section */ + +/* Begin PBXContainerItemProxy section */ + AE99576C1FA704AF00397D38 /* PBXContainerItemProxy */ = { + isa = PBXContainerItemProxy; + containerPortal = AE99574F1FA704AF00397D38 /* Project object */; + proxyType = 1; + remoteGlobalIDString = AE9957561FA704AF00397D38; + remoteInfo = meetingRooms; + }; + AE9957771FA704B000397D38 /* PBXContainerItemProxy */ = { + isa = PBXContainerItemProxy; + containerPortal = AE99574F1FA704AF00397D38 /* Project object */; + proxyType = 1; + remoteGlobalIDString = AE9957561FA704AF00397D38; + remoteInfo = meetingRooms; + }; +/* End PBXContainerItemProxy section */ + +/* Begin PBXFileReference section */ + AE9957571FA704AF00397D38 /* meetingRooms.app */ = {isa = PBXFileReference; explicitFileType = wrapper.application; includeInIndex = 0; path = meetingRooms.app; sourceTree = BUILT_PRODUCTS_DIR; }; + AE99575A1FA704AF00397D38 /* AppDelegate.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = AppDelegate.swift; sourceTree = ""; }; + AE99575C1FA704AF00397D38 /* ViewController.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = ViewController.swift; sourceTree = ""; }; + AE99575F1FA704AF00397D38 /* Base */ = {isa = PBXFileReference; lastKnownFileType = file.storyboard; name = Base; path = Base.lproj/Main.storyboard; sourceTree = ""; }; + AE9957611FA704AF00397D38 /* Assets.xcassets */ = {isa = PBXFileReference; lastKnownFileType = folder.assetcatalog; path = Assets.xcassets; sourceTree = ""; }; + AE9957641FA704AF00397D38 /* Base */ = {isa = PBXFileReference; lastKnownFileType = file.storyboard; name = Base; path = Base.lproj/LaunchScreen.storyboard; sourceTree = ""; }; + AE9957661FA704AF00397D38 /* Info.plist */ = {isa = PBXFileReference; lastKnownFileType = text.plist.xml; path = Info.plist; sourceTree = ""; }; + AE99576B1FA704AF00397D38 /* meetingRoomsTests.xctest */ = {isa = PBXFileReference; explicitFileType = wrapper.cfbundle; includeInIndex = 0; path = meetingRoomsTests.xctest; sourceTree = BUILT_PRODUCTS_DIR; }; + AE99576F1FA704AF00397D38 /* meetingRoomsTests.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = meetingRoomsTests.swift; sourceTree = ""; }; + AE9957711FA704AF00397D38 /* Info.plist */ = {isa = PBXFileReference; lastKnownFileType = text.plist.xml; path = Info.plist; sourceTree = ""; }; + AE9957761FA704B000397D38 /* meetingRoomsUITests.xctest */ = {isa = PBXFileReference; explicitFileType = wrapper.cfbundle; includeInIndex = 0; path = meetingRoomsUITests.xctest; sourceTree = BUILT_PRODUCTS_DIR; }; + AE99577A1FA704B000397D38 /* meetingRoomsUITests.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = meetingRoomsUITests.swift; sourceTree = ""; }; + AE99577C1FA704B000397D38 /* Info.plist */ = {isa = PBXFileReference; lastKnownFileType = text.plist.xml; path = Info.plist; sourceTree = ""; }; + AE9957881FA7054800397D38 /* MeetingRoomListViewController.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = MeetingRoomListViewController.swift; sourceTree = ""; }; +/* End PBXFileReference section */ + +/* Begin PBXFrameworksBuildPhase section */ + AE9957541FA704AF00397D38 /* Frameworks */ = { + isa = PBXFrameworksBuildPhase; + buildActionMask = 2147483647; + files = ( + ); + runOnlyForDeploymentPostprocessing = 0; + }; + AE9957681FA704AF00397D38 /* Frameworks */ = { + isa = PBXFrameworksBuildPhase; + buildActionMask = 2147483647; + files = ( + ); + runOnlyForDeploymentPostprocessing = 0; + }; + AE9957731FA704B000397D38 /* Frameworks */ = { + isa = PBXFrameworksBuildPhase; + buildActionMask = 2147483647; + files = ( + ); + runOnlyForDeploymentPostprocessing = 0; + }; +/* End PBXFrameworksBuildPhase section */ + +/* Begin PBXGroup section */ + AE99574E1FA704AF00397D38 = { + isa = PBXGroup; + children = ( + AE9957591FA704AF00397D38 /* meetingRooms */, + AE99576E1FA704AF00397D38 /* meetingRoomsTests */, + AE9957791FA704B000397D38 /* meetingRoomsUITests */, + AE9957581FA704AF00397D38 /* Products */, + ); + sourceTree = ""; + }; + AE9957581FA704AF00397D38 /* Products */ = { + isa = PBXGroup; + children = ( + AE9957571FA704AF00397D38 /* meetingRooms.app */, + AE99576B1FA704AF00397D38 /* meetingRoomsTests.xctest */, + AE9957761FA704B000397D38 /* meetingRoomsUITests.xctest */, + ); + name = Products; + sourceTree = ""; + }; + AE9957591FA704AF00397D38 /* meetingRooms */ = { + isa = PBXGroup; + children = ( + AE99575A1FA704AF00397D38 /* AppDelegate.swift */, + AE99575C1FA704AF00397D38 /* ViewController.swift */, + AE99575E1FA704AF00397D38 /* Main.storyboard */, + AE9957881FA7054800397D38 /* MeetingRoomListViewController.swift */, + AE9957611FA704AF00397D38 /* Assets.xcassets */, + AE9957631FA704AF00397D38 /* LaunchScreen.storyboard */, + AE9957661FA704AF00397D38 /* Info.plist */, + ); + path = meetingRooms; + sourceTree = ""; + }; + AE99576E1FA704AF00397D38 /* meetingRoomsTests */ = { + isa = PBXGroup; + children = ( + AE99576F1FA704AF00397D38 /* meetingRoomsTests.swift */, + AE9957711FA704AF00397D38 /* Info.plist */, + ); + path = meetingRoomsTests; + sourceTree = ""; + }; + AE9957791FA704B000397D38 /* meetingRoomsUITests */ = { + isa = PBXGroup; + children = ( + AE99577A1FA704B000397D38 /* meetingRoomsUITests.swift */, + AE99577C1FA704B000397D38 /* Info.plist */, + ); + path = meetingRoomsUITests; + sourceTree = ""; + }; +/* End PBXGroup section */ + +/* Begin PBXNativeTarget section */ + AE9957561FA704AF00397D38 /* meetingRooms */ = { + isa = PBXNativeTarget; + buildConfigurationList = AE99577F1FA704B000397D38 /* Build configuration list for PBXNativeTarget "meetingRooms" */; + buildPhases = ( + AE9957531FA704AF00397D38 /* Sources */, + AE9957541FA704AF00397D38 /* Frameworks */, + AE9957551FA704AF00397D38 /* Resources */, + ); + buildRules = ( + ); + dependencies = ( + ); + name = meetingRooms; + productName = meetingRooms; + productReference = AE9957571FA704AF00397D38 /* meetingRooms.app */; + productType = "com.apple.product-type.application"; + }; + AE99576A1FA704AF00397D38 /* meetingRoomsTests */ = { + isa = PBXNativeTarget; + buildConfigurationList = AE9957821FA704B000397D38 /* Build configuration list for PBXNativeTarget "meetingRoomsTests" */; + buildPhases = ( + AE9957671FA704AF00397D38 /* Sources */, + AE9957681FA704AF00397D38 /* Frameworks */, + AE9957691FA704AF00397D38 /* Resources */, + ); + buildRules = ( + ); + dependencies = ( + AE99576D1FA704AF00397D38 /* PBXTargetDependency */, + ); + name = meetingRoomsTests; + productName = meetingRoomsTests; + productReference = AE99576B1FA704AF00397D38 /* meetingRoomsTests.xctest */; + productType = "com.apple.product-type.bundle.unit-test"; + }; + AE9957751FA704B000397D38 /* meetingRoomsUITests */ = { + isa = PBXNativeTarget; + buildConfigurationList = AE9957851FA704B000397D38 /* Build configuration list for PBXNativeTarget "meetingRoomsUITests" */; + buildPhases = ( + AE9957721FA704B000397D38 /* Sources */, + AE9957731FA704B000397D38 /* Frameworks */, + AE9957741FA704B000397D38 /* Resources */, + ); + buildRules = ( + ); + dependencies = ( + AE9957781FA704B000397D38 /* PBXTargetDependency */, + ); + name = meetingRoomsUITests; + productName = meetingRoomsUITests; + productReference = AE9957761FA704B000397D38 /* meetingRoomsUITests.xctest */; + productType = "com.apple.product-type.bundle.ui-testing"; + }; +/* End PBXNativeTarget section */ + +/* Begin PBXProject section */ + AE99574F1FA704AF00397D38 /* Project object */ = { + isa = PBXProject; + attributes = { + LastSwiftUpdateCheck = 0900; + LastUpgradeCheck = 0900; + ORGANIZATIONNAME = "황도증"; + TargetAttributes = { + AE9957561FA704AF00397D38 = { + CreatedOnToolsVersion = 9.0.1; + ProvisioningStyle = Automatic; + }; + AE99576A1FA704AF00397D38 = { + CreatedOnToolsVersion = 9.0.1; + ProvisioningStyle = Automatic; + TestTargetID = AE9957561FA704AF00397D38; + }; + AE9957751FA704B000397D38 = { + CreatedOnToolsVersion = 9.0.1; + ProvisioningStyle = Automatic; + TestTargetID = AE9957561FA704AF00397D38; + }; + }; + }; + buildConfigurationList = AE9957521FA704AF00397D38 /* Build configuration list for PBXProject "meetingRooms" */; + compatibilityVersion = "Xcode 8.0"; + developmentRegion = en; + hasScannedForEncodings = 0; + knownRegions = ( + en, + Base, + ); + mainGroup = AE99574E1FA704AF00397D38; + productRefGroup = AE9957581FA704AF00397D38 /* Products */; + projectDirPath = ""; + projectRoot = ""; + targets = ( + AE9957561FA704AF00397D38 /* meetingRooms */, + AE99576A1FA704AF00397D38 /* meetingRoomsTests */, + AE9957751FA704B000397D38 /* meetingRoomsUITests */, + ); + }; +/* End PBXProject section */ + +/* Begin PBXResourcesBuildPhase section */ + AE9957551FA704AF00397D38 /* Resources */ = { + isa = PBXResourcesBuildPhase; + buildActionMask = 2147483647; + files = ( + AE9957651FA704AF00397D38 /* LaunchScreen.storyboard in Resources */, + AE9957621FA704AF00397D38 /* Assets.xcassets in Resources */, + AE9957601FA704AF00397D38 /* Main.storyboard in Resources */, + ); + runOnlyForDeploymentPostprocessing = 0; + }; + AE9957691FA704AF00397D38 /* Resources */ = { + isa = PBXResourcesBuildPhase; + buildActionMask = 2147483647; + files = ( + ); + runOnlyForDeploymentPostprocessing = 0; + }; + AE9957741FA704B000397D38 /* Resources */ = { + isa = PBXResourcesBuildPhase; + buildActionMask = 2147483647; + files = ( + ); + runOnlyForDeploymentPostprocessing = 0; + }; +/* End PBXResourcesBuildPhase section */ + +/* Begin PBXSourcesBuildPhase section */ + AE9957531FA704AF00397D38 /* Sources */ = { + isa = PBXSourcesBuildPhase; + buildActionMask = 2147483647; + files = ( + AE99575D1FA704AF00397D38 /* ViewController.swift in Sources */, + AE99575B1FA704AF00397D38 /* AppDelegate.swift in Sources */, + AE9957891FA7054800397D38 /* MeetingRoomListViewController.swift in Sources */, + ); + runOnlyForDeploymentPostprocessing = 0; + }; + AE9957671FA704AF00397D38 /* Sources */ = { + isa = PBXSourcesBuildPhase; + buildActionMask = 2147483647; + files = ( + AE9957701FA704AF00397D38 /* meetingRoomsTests.swift in Sources */, + ); + runOnlyForDeploymentPostprocessing = 0; + }; + AE9957721FA704B000397D38 /* Sources */ = { + isa = PBXSourcesBuildPhase; + buildActionMask = 2147483647; + files = ( + AE99577B1FA704B000397D38 /* meetingRoomsUITests.swift in Sources */, + ); + runOnlyForDeploymentPostprocessing = 0; + }; +/* End PBXSourcesBuildPhase section */ + +/* Begin PBXTargetDependency section */ + AE99576D1FA704AF00397D38 /* PBXTargetDependency */ = { + isa = PBXTargetDependency; + target = AE9957561FA704AF00397D38 /* meetingRooms */; + targetProxy = AE99576C1FA704AF00397D38 /* PBXContainerItemProxy */; + }; + AE9957781FA704B000397D38 /* PBXTargetDependency */ = { + isa = PBXTargetDependency; + target = AE9957561FA704AF00397D38 /* meetingRooms */; + targetProxy = AE9957771FA704B000397D38 /* PBXContainerItemProxy */; + }; +/* End PBXTargetDependency section */ + +/* Begin PBXVariantGroup section */ + AE99575E1FA704AF00397D38 /* Main.storyboard */ = { + isa = PBXVariantGroup; + children = ( + AE99575F1FA704AF00397D38 /* Base */, + ); + name = Main.storyboard; + sourceTree = ""; + }; + AE9957631FA704AF00397D38 /* LaunchScreen.storyboard */ = { + isa = PBXVariantGroup; + children = ( + AE9957641FA704AF00397D38 /* Base */, + ); + name = LaunchScreen.storyboard; + sourceTree = ""; + }; +/* End PBXVariantGroup section */ + +/* Begin XCBuildConfiguration section */ + AE99577D1FA704B000397D38 /* Debug */ = { + isa = XCBuildConfiguration; + buildSettings = { + ALWAYS_SEARCH_USER_PATHS = NO; + CLANG_ANALYZER_NONNULL = YES; + CLANG_ANALYZER_NUMBER_OBJECT_CONVERSION = YES_AGGRESSIVE; + CLANG_CXX_LANGUAGE_STANDARD = "gnu++14"; + CLANG_CXX_LIBRARY = "libc++"; + CLANG_ENABLE_MODULES = YES; + CLANG_ENABLE_OBJC_ARC = YES; + CLANG_WARN_BLOCK_CAPTURE_AUTORELEASING = YES; + CLANG_WARN_BOOL_CONVERSION = YES; + CLANG_WARN_COMMA = YES; + CLANG_WARN_CONSTANT_CONVERSION = YES; + CLANG_WARN_DIRECT_OBJC_ISA_USAGE = YES_ERROR; + CLANG_WARN_DOCUMENTATION_COMMENTS = YES; + CLANG_WARN_EMPTY_BODY = YES; + CLANG_WARN_ENUM_CONVERSION = YES; + CLANG_WARN_INFINITE_RECURSION = YES; + CLANG_WARN_INT_CONVERSION = YES; + CLANG_WARN_NON_LITERAL_NULL_CONVERSION = YES; + CLANG_WARN_OBJC_LITERAL_CONVERSION = YES; + CLANG_WARN_OBJC_ROOT_CLASS = YES_ERROR; + CLANG_WARN_RANGE_LOOP_ANALYSIS = YES; + CLANG_WARN_STRICT_PROTOTYPES = YES; + CLANG_WARN_SUSPICIOUS_MOVE = YES; + CLANG_WARN_UNGUARDED_AVAILABILITY = YES_AGGRESSIVE; + CLANG_WARN_UNREACHABLE_CODE = YES; + CLANG_WARN__DUPLICATE_METHOD_MATCH = YES; + CODE_SIGN_IDENTITY = "iPhone Developer"; + COPY_PHASE_STRIP = NO; + DEBUG_INFORMATION_FORMAT = dwarf; + ENABLE_STRICT_OBJC_MSGSEND = YES; + ENABLE_TESTABILITY = YES; + GCC_C_LANGUAGE_STANDARD = gnu11; + GCC_DYNAMIC_NO_PIC = NO; + GCC_NO_COMMON_BLOCKS = YES; + GCC_OPTIMIZATION_LEVEL = 0; + GCC_PREPROCESSOR_DEFINITIONS = ( + "DEBUG=1", + "$(inherited)", + ); + GCC_WARN_64_TO_32_BIT_CONVERSION = YES; + GCC_WARN_ABOUT_RETURN_TYPE = YES_ERROR; + GCC_WARN_UNDECLARED_SELECTOR = YES; + GCC_WARN_UNINITIALIZED_AUTOS = YES_AGGRESSIVE; + GCC_WARN_UNUSED_FUNCTION = YES; + GCC_WARN_UNUSED_VARIABLE = YES; + IPHONEOS_DEPLOYMENT_TARGET = 11.0; + MTL_ENABLE_DEBUG_INFO = YES; + ONLY_ACTIVE_ARCH = YES; + SDKROOT = iphoneos; + SWIFT_ACTIVE_COMPILATION_CONDITIONS = DEBUG; + SWIFT_OPTIMIZATION_LEVEL = "-Onone"; + }; + name = Debug; + }; + AE99577E1FA704B000397D38 /* Release */ = { + isa = XCBuildConfiguration; + buildSettings = { + ALWAYS_SEARCH_USER_PATHS = NO; + CLANG_ANALYZER_NONNULL = YES; + CLANG_ANALYZER_NUMBER_OBJECT_CONVERSION = YES_AGGRESSIVE; + CLANG_CXX_LANGUAGE_STANDARD = "gnu++14"; + CLANG_CXX_LIBRARY = "libc++"; + CLANG_ENABLE_MODULES = YES; + CLANG_ENABLE_OBJC_ARC = YES; + CLANG_WARN_BLOCK_CAPTURE_AUTORELEASING = YES; + CLANG_WARN_BOOL_CONVERSION = YES; + CLANG_WARN_COMMA = YES; + CLANG_WARN_CONSTANT_CONVERSION = YES; + CLANG_WARN_DIRECT_OBJC_ISA_USAGE = YES_ERROR; + CLANG_WARN_DOCUMENTATION_COMMENTS = YES; + CLANG_WARN_EMPTY_BODY = YES; + CLANG_WARN_ENUM_CONVERSION = YES; + CLANG_WARN_INFINITE_RECURSION = YES; + CLANG_WARN_INT_CONVERSION = YES; + CLANG_WARN_NON_LITERAL_NULL_CONVERSION = YES; + CLANG_WARN_OBJC_LITERAL_CONVERSION = YES; + CLANG_WARN_OBJC_ROOT_CLASS = YES_ERROR; + CLANG_WARN_RANGE_LOOP_ANALYSIS = YES; + CLANG_WARN_STRICT_PROTOTYPES = YES; + CLANG_WARN_SUSPICIOUS_MOVE = YES; + CLANG_WARN_UNGUARDED_AVAILABILITY = YES_AGGRESSIVE; + CLANG_WARN_UNREACHABLE_CODE = YES; + CLANG_WARN__DUPLICATE_METHOD_MATCH = YES; + CODE_SIGN_IDENTITY = "iPhone Developer"; + COPY_PHASE_STRIP = NO; + DEBUG_INFORMATION_FORMAT = "dwarf-with-dsym"; + ENABLE_NS_ASSERTIONS = NO; + ENABLE_STRICT_OBJC_MSGSEND = YES; + GCC_C_LANGUAGE_STANDARD = gnu11; + GCC_NO_COMMON_BLOCKS = YES; + GCC_WARN_64_TO_32_BIT_CONVERSION = YES; + GCC_WARN_ABOUT_RETURN_TYPE = YES_ERROR; + GCC_WARN_UNDECLARED_SELECTOR = YES; + GCC_WARN_UNINITIALIZED_AUTOS = YES_AGGRESSIVE; + GCC_WARN_UNUSED_FUNCTION = YES; + GCC_WARN_UNUSED_VARIABLE = YES; + IPHONEOS_DEPLOYMENT_TARGET = 11.0; + MTL_ENABLE_DEBUG_INFO = NO; + SDKROOT = iphoneos; + SWIFT_OPTIMIZATION_LEVEL = "-Owholemodule"; + VALIDATE_PRODUCT = YES; + }; + name = Release; + }; + AE9957801FA704B000397D38 /* Debug */ = { + isa = XCBuildConfiguration; + buildSettings = { + ASSETCATALOG_COMPILER_APPICON_NAME = AppIcon; + CODE_SIGN_STYLE = Automatic; + INFOPLIST_FILE = meetingRooms/Info.plist; + LD_RUNPATH_SEARCH_PATHS = "$(inherited) @executable_path/Frameworks"; + PRODUCT_BUNDLE_IDENTIFIER = "--------.meetingRooms"; + PRODUCT_NAME = "$(TARGET_NAME)"; + SWIFT_VERSION = 4.0; + TARGETED_DEVICE_FAMILY = "1,2"; + }; + name = Debug; + }; + AE9957811FA704B000397D38 /* Release */ = { + isa = XCBuildConfiguration; + buildSettings = { + ASSETCATALOG_COMPILER_APPICON_NAME = AppIcon; + CODE_SIGN_STYLE = Automatic; + INFOPLIST_FILE = meetingRooms/Info.plist; + LD_RUNPATH_SEARCH_PATHS = "$(inherited) @executable_path/Frameworks"; + PRODUCT_BUNDLE_IDENTIFIER = "--------.meetingRooms"; + PRODUCT_NAME = "$(TARGET_NAME)"; + SWIFT_VERSION = 4.0; + TARGETED_DEVICE_FAMILY = "1,2"; + }; + name = Release; + }; + AE9957831FA704B000397D38 /* Debug */ = { + isa = XCBuildConfiguration; + buildSettings = { + ALWAYS_EMBED_SWIFT_STANDARD_LIBRARIES = YES; + BUNDLE_LOADER = "$(TEST_HOST)"; + CODE_SIGN_STYLE = Automatic; + INFOPLIST_FILE = meetingRoomsTests/Info.plist; + LD_RUNPATH_SEARCH_PATHS = "$(inherited) @executable_path/Frameworks @loader_path/Frameworks"; + PRODUCT_BUNDLE_IDENTIFIER = "--------.meetingRoomsTests"; + PRODUCT_NAME = "$(TARGET_NAME)"; + SWIFT_VERSION = 4.0; + TARGETED_DEVICE_FAMILY = "1,2"; + TEST_HOST = "$(BUILT_PRODUCTS_DIR)/meetingRooms.app/meetingRooms"; + }; + name = Debug; + }; + AE9957841FA704B000397D38 /* Release */ = { + isa = XCBuildConfiguration; + buildSettings = { + ALWAYS_EMBED_SWIFT_STANDARD_LIBRARIES = YES; + BUNDLE_LOADER = "$(TEST_HOST)"; + CODE_SIGN_STYLE = Automatic; + INFOPLIST_FILE = meetingRoomsTests/Info.plist; + LD_RUNPATH_SEARCH_PATHS = "$(inherited) @executable_path/Frameworks @loader_path/Frameworks"; + PRODUCT_BUNDLE_IDENTIFIER = "--------.meetingRoomsTests"; + PRODUCT_NAME = "$(TARGET_NAME)"; + SWIFT_VERSION = 4.0; + TARGETED_DEVICE_FAMILY = "1,2"; + TEST_HOST = "$(BUILT_PRODUCTS_DIR)/meetingRooms.app/meetingRooms"; + }; + name = Release; + }; + AE9957861FA704B000397D38 /* Debug */ = { + isa = XCBuildConfiguration; + buildSettings = { + ALWAYS_EMBED_SWIFT_STANDARD_LIBRARIES = YES; + CODE_SIGN_STYLE = Automatic; + INFOPLIST_FILE = meetingRoomsUITests/Info.plist; + LD_RUNPATH_SEARCH_PATHS = "$(inherited) @executable_path/Frameworks @loader_path/Frameworks"; + PRODUCT_BUNDLE_IDENTIFIER = "--------.meetingRoomsUITests"; + PRODUCT_NAME = "$(TARGET_NAME)"; + SWIFT_VERSION = 4.0; + TARGETED_DEVICE_FAMILY = "1,2"; + TEST_TARGET_NAME = meetingRooms; + }; + name = Debug; + }; + AE9957871FA704B000397D38 /* Release */ = { + isa = XCBuildConfiguration; + buildSettings = { + ALWAYS_EMBED_SWIFT_STANDARD_LIBRARIES = YES; + CODE_SIGN_STYLE = Automatic; + INFOPLIST_FILE = meetingRoomsUITests/Info.plist; + LD_RUNPATH_SEARCH_PATHS = "$(inherited) @executable_path/Frameworks @loader_path/Frameworks"; + PRODUCT_BUNDLE_IDENTIFIER = "--------.meetingRoomsUITests"; + PRODUCT_NAME = "$(TARGET_NAME)"; + SWIFT_VERSION = 4.0; + TARGETED_DEVICE_FAMILY = "1,2"; + TEST_TARGET_NAME = meetingRooms; + }; + name = Release; + }; +/* End XCBuildConfiguration section */ + +/* Begin XCConfigurationList section */ + AE9957521FA704AF00397D38 /* Build configuration list for PBXProject "meetingRooms" */ = { + isa = XCConfigurationList; + buildConfigurations = ( + AE99577D1FA704B000397D38 /* Debug */, + AE99577E1FA704B000397D38 /* Release */, + ); + defaultConfigurationIsVisible = 0; + defaultConfigurationName = Release; + }; + AE99577F1FA704B000397D38 /* Build configuration list for PBXNativeTarget "meetingRooms" */ = { + isa = XCConfigurationList; + buildConfigurations = ( + AE9957801FA704B000397D38 /* Debug */, + AE9957811FA704B000397D38 /* Release */, + ); + defaultConfigurationIsVisible = 0; + defaultConfigurationName = Release; + }; + AE9957821FA704B000397D38 /* Build configuration list for PBXNativeTarget "meetingRoomsTests" */ = { + isa = XCConfigurationList; + buildConfigurations = ( + AE9957831FA704B000397D38 /* Debug */, + AE9957841FA704B000397D38 /* Release */, + ); + defaultConfigurationIsVisible = 0; + defaultConfigurationName = Release; + }; + AE9957851FA704B000397D38 /* Build configuration list for PBXNativeTarget "meetingRoomsUITests" */ = { + isa = XCConfigurationList; + buildConfigurations = ( + AE9957861FA704B000397D38 /* Debug */, + AE9957871FA704B000397D38 /* Release */, + ); + defaultConfigurationIsVisible = 0; + defaultConfigurationName = Release; + }; +/* End XCConfigurationList section */ + }; + rootObject = AE99574F1FA704AF00397D38 /* Project object */; +} diff --git "a/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/meetingRooms/meetingRooms.xcodeproj/project.xcworkspace/contents.xcworkspacedata" "b/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/meetingRooms/meetingRooms.xcodeproj/project.xcworkspace/contents.xcworkspacedata" new file mode 100644 index 0000000..8491799 --- /dev/null +++ "b/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/meetingRooms/meetingRooms.xcodeproj/project.xcworkspace/contents.xcworkspacedata" @@ -0,0 +1,7 @@ + + + + + diff --git "a/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/meetingRooms/meetingRooms/AppDelegate.swift" "b/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/meetingRooms/meetingRooms/AppDelegate.swift" new file mode 100644 index 0000000..fc60321 --- /dev/null +++ "b/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/meetingRooms/meetingRooms/AppDelegate.swift" @@ -0,0 +1,46 @@ +// +// AppDelegate.swift +// meetingRooms +// +// Created by 황도증 on 2017. 10. 30.. +// Copyright © 2017년 황도증. All rights reserved. +// + +import UIKit + +@UIApplicationMain +class AppDelegate: UIResponder, UIApplicationDelegate { + + var window: UIWindow? + + + func application(_ application: UIApplication, didFinishLaunchingWithOptions launchOptions: [UIApplicationLaunchOptionsKey: Any]?) -> Bool { + // Override point for customization after application launch. + return true + } + + func applicationWillResignActive(_ application: UIApplication) { + // Sent when the application is about to move from active to inactive state. This can occur for certain types of temporary interruptions (such as an incoming phone call or SMS message) or when the user quits the application and it begins the transition to the background state. + // Use this method to pause ongoing tasks, disable timers, and invalidate graphics rendering callbacks. Games should use this method to pause the game. + } + + func applicationDidEnterBackground(_ application: UIApplication) { + // Use this method to release shared resources, save user data, invalidate timers, and store enough application state information to restore your application to its current state in case it is terminated later. + // If your application supports background execution, this method is called instead of applicationWillTerminate: when the user quits. + } + + func applicationWillEnterForeground(_ application: UIApplication) { + // Called as part of the transition from the background to the active state; here you can undo many of the changes made on entering the background. + } + + func applicationDidBecomeActive(_ application: UIApplication) { + // Restart any tasks that were paused (or not yet started) while the application was inactive. If the application was previously in the background, optionally refresh the user interface. + } + + func applicationWillTerminate(_ application: UIApplication) { + // Called when the application is about to terminate. Save data if appropriate. See also applicationDidEnterBackground:. + } + + +} + diff --git "a/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/meetingRooms/meetingRooms/Assets.xcassets/AppIcon.appiconset/Contents.json" "b/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/meetingRooms/meetingRooms/Assets.xcassets/AppIcon.appiconset/Contents.json" new file mode 100644 index 0000000..d8db8d6 --- /dev/null +++ "b/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/meetingRooms/meetingRooms/Assets.xcassets/AppIcon.appiconset/Contents.json" @@ -0,0 +1,98 @@ +{ + "images" : [ + { + "idiom" : "iphone", + "size" : "20x20", + "scale" : "2x" + }, + { + "idiom" : "iphone", + "size" : "20x20", + "scale" : "3x" + }, + { + "idiom" : "iphone", + "size" : "29x29", + "scale" : "2x" + }, + { + "idiom" : "iphone", + "size" : "29x29", + "scale" : "3x" + }, + { + "idiom" : "iphone", + "size" : "40x40", + "scale" : "2x" + }, + { + "idiom" : "iphone", + "size" : "40x40", + "scale" : "3x" + }, + { + "idiom" : "iphone", + "size" : "60x60", + "scale" : "2x" + }, + { + "idiom" : "iphone", + "size" : "60x60", + "scale" : "3x" + }, + { + "idiom" : "ipad", + "size" : "20x20", + "scale" : "1x" + }, + { + "idiom" : "ipad", + "size" : "20x20", + "scale" : "2x" + }, + { + "idiom" : "ipad", + "size" : "29x29", + "scale" : "1x" + }, + { + "idiom" : "ipad", + "size" : "29x29", + "scale" : "2x" + }, + { + "idiom" : "ipad", + "size" : "40x40", + "scale" : "1x" + }, + { + "idiom" : "ipad", + "size" : "40x40", + "scale" : "2x" + }, + { + "idiom" : "ipad", + "size" : "76x76", + "scale" : "1x" + }, + { + "idiom" : "ipad", + "size" : "76x76", + "scale" : "2x" + }, + { + "idiom" : "ipad", + "size" : "83.5x83.5", + "scale" : "2x" + }, + { + "idiom" : "ios-marketing", + "size" : "1024x1024", + "scale" : "1x" + } + ], + "info" : { + "version" : 1, + "author" : "xcode" + } +} \ No newline at end of file diff --git "a/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/meetingRooms/meetingRooms/Base.lproj/LaunchScreen.storyboard" "b/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/meetingRooms/meetingRooms/Base.lproj/LaunchScreen.storyboard" new file mode 100644 index 0000000..f83f6fd --- /dev/null +++ "b/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/meetingRooms/meetingRooms/Base.lproj/LaunchScreen.storyboard" @@ -0,0 +1,25 @@ + + + + + + + + + + + + + + + + + + + + + + + + + diff --git "a/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/meetingRooms/meetingRooms/Base.lproj/Main.storyboard" "b/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/meetingRooms/meetingRooms/Base.lproj/Main.storyboard" new file mode 100644 index 0000000..ff29a4c --- /dev/null +++ "b/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/meetingRooms/meetingRooms/Base.lproj/Main.storyboard" @@ -0,0 +1,56 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + diff --git "a/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/meetingRooms/meetingRooms/Info.plist" "b/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/meetingRooms/meetingRooms/Info.plist" new file mode 100644 index 0000000..16be3b6 --- /dev/null +++ "b/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/meetingRooms/meetingRooms/Info.plist" @@ -0,0 +1,45 @@ + + + + + CFBundleDevelopmentRegion + $(DEVELOPMENT_LANGUAGE) + CFBundleExecutable + $(EXECUTABLE_NAME) + CFBundleIdentifier + $(PRODUCT_BUNDLE_IDENTIFIER) + CFBundleInfoDictionaryVersion + 6.0 + CFBundleName + $(PRODUCT_NAME) + CFBundlePackageType + APPL + CFBundleShortVersionString + 1.0 + CFBundleVersion + 1 + LSRequiresIPhoneOS + + UILaunchStoryboardName + LaunchScreen + UIMainStoryboardFile + Main + UIRequiredDeviceCapabilities + + armv7 + + UISupportedInterfaceOrientations + + UIInterfaceOrientationPortrait + UIInterfaceOrientationLandscapeLeft + UIInterfaceOrientationLandscapeRight + + UISupportedInterfaceOrientations~ipad + + UIInterfaceOrientationPortrait + UIInterfaceOrientationPortraitUpsideDown + UIInterfaceOrientationLandscapeLeft + UIInterfaceOrientationLandscapeRight + + + diff --git "a/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/meetingRooms/meetingRooms/MeetingRoomListViewController.swift" "b/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/meetingRooms/meetingRooms/MeetingRoomListViewController.swift" new file mode 100644 index 0000000..2742ac3 --- /dev/null +++ "b/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/meetingRooms/meetingRooms/MeetingRoomListViewController.swift" @@ -0,0 +1,105 @@ +// +// MeetingRoomListViewController.swift +// meetingRooms +// +// Created by 황도증 on 2017. 10. 30.. +// Copyright © 2017년 황도증. All rights reserved. +// + +import UIKit + +class MeetingRoomListViewController: UITableViewController { + + var meetingRooms:[String:Int] = ["Banksy":4, "Rivera":8, "Kahlo":10, "Cezanne":20, "Matisse":30, "Renoir":40] + + override func viewDidLoad() { + super.viewDidLoad() + + // Uncomment the following line to preserve selection between presentations + // self.clearsSelectionOnViewWillAppear = false + + // Uncomment the following line to display an Edit button in the navigation bar for this view controller. + // self.navigationItem.rightBarButtonItem = self.editButtonItem + } + + override func didReceiveMemoryWarning() { + super.didReceiveMemoryWarning() + // Dispose of any resources that can be recreated. + } + + // MARK: - Table view data source + + override func numberOfSections(in tableView: UITableView) -> Int { + // #warning Incomplete implementation, return the number of sections + return 1 + } + + override func tableView(_ tableView: UITableView, numberOfRowsInSection section: Int) -> Int { + // #warning Incomplete implementation, return the number of rows + return meetingRooms.count + } + + + override func tableView(_ tableView: UITableView, cellForRowAt indexPath: IndexPath) -> UITableViewCell { + let cell = tableView.dequeueReusableCell(withIdentifier: "MyCell", for: indexPath) + + // Configure the cell... + let roomNames = Array(meetingRooms.keys) + let roomName = roomNames[indexPath.row] + cell.textLabel!.text = roomName + + //roomName이라는 키값으로부터 capacity라는 정수 밸류 값을 가져오는 코드 + if let capacity:Int = meetingRooms[roomName] { + cell.detailTextLabel!.text = "\(capacity)" + } + + return cell + } + + + /* + // Override to support conditional editing of the table view. + override func tableView(_ tableView: UITableView, canEditRowAt indexPath: IndexPath) -> Bool { + // Return false if you do not want the specified item to be editable. + return true + } + */ + + /* + // Override to support editing the table view. + override func tableView(_ tableView: UITableView, commit editingStyle: UITableViewCellEditingStyle, forRowAt indexPath: IndexPath) { + if editingStyle == .delete { + // Delete the row from the data source + tableView.deleteRows(at: [indexPath], with: .fade) + } else if editingStyle == .insert { + // Create a new instance of the appropriate class, insert it into the array, and add a new row to the table view + } + } + */ + + /* + // Override to support rearranging the table view. + override func tableView(_ tableView: UITableView, moveRowAt fromIndexPath: IndexPath, to: IndexPath) { + + } + */ + + /* + // Override to support conditional rearranging of the table view. + override func tableView(_ tableView: UITableView, canMoveRowAt indexPath: IndexPath) -> Bool { + // Return false if you do not want the item to be re-orderable. + return true + } + */ + + /* + // MARK: - Navigation + + // In a storyboard-based application, you will often want to do a little preparation before navigation + override func prepare(for segue: UIStoryboardSegue, sender: Any?) { + // Get the new view controller using segue.destinationViewController. + // Pass the selected object to the new view controller. + } + */ + +} diff --git "a/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/meetingRooms/meetingRooms/ViewController.swift" "b/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/meetingRooms/meetingRooms/ViewController.swift" new file mode 100644 index 0000000..24bd9b0 --- /dev/null +++ "b/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/meetingRooms/meetingRooms/ViewController.swift" @@ -0,0 +1,25 @@ +// +// ViewController.swift +// meetingRooms +// +// Created by 황도증 on 2017. 10. 30.. +// Copyright © 2017년 황도증. All rights reserved. +// + +import UIKit + +class ViewController: UIViewController { + + override func viewDidLoad() { + super.viewDidLoad() + // Do any additional setup after loading the view, typically from a nib. + } + + override func didReceiveMemoryWarning() { + super.didReceiveMemoryWarning() + // Dispose of any resources that can be recreated. + } + + +} + diff --git "a/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/meetingRooms/meetingRoomsTests/Info.plist" "b/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/meetingRooms/meetingRoomsTests/Info.plist" new file mode 100644 index 0000000..6c40a6c --- /dev/null +++ "b/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/meetingRooms/meetingRoomsTests/Info.plist" @@ -0,0 +1,22 @@ + + + + + CFBundleDevelopmentRegion + $(DEVELOPMENT_LANGUAGE) + CFBundleExecutable + $(EXECUTABLE_NAME) + CFBundleIdentifier + $(PRODUCT_BUNDLE_IDENTIFIER) + CFBundleInfoDictionaryVersion + 6.0 + CFBundleName + $(PRODUCT_NAME) + CFBundlePackageType + BNDL + CFBundleShortVersionString + 1.0 + CFBundleVersion + 1 + + diff --git "a/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/meetingRooms/meetingRoomsTests/meetingRoomsTests.swift" "b/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/meetingRooms/meetingRoomsTests/meetingRoomsTests.swift" new file mode 100644 index 0000000..bfbd8d6 --- /dev/null +++ "b/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/meetingRooms/meetingRoomsTests/meetingRoomsTests.swift" @@ -0,0 +1,36 @@ +// +// meetingRoomsTests.swift +// meetingRoomsTests +// +// Created by 황도증 on 2017. 10. 30.. +// Copyright © 2017년 황도증. All rights reserved. +// + +import XCTest +@testable import meetingRooms + +class meetingRoomsTests: XCTestCase { + + override func setUp() { + super.setUp() + // Put setup code here. This method is called before the invocation of each test method in the class. + } + + override func tearDown() { + // Put teardown code here. This method is called after the invocation of each test method in the class. + super.tearDown() + } + + func testExample() { + // This is an example of a functional test case. + // Use XCTAssert and related functions to verify your tests produce the correct results. + } + + func testPerformanceExample() { + // This is an example of a performance test case. + self.measure { + // Put the code you want to measure the time of here. + } + } + +} diff --git "a/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/meetingRooms/meetingRoomsUITests/Info.plist" "b/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/meetingRooms/meetingRoomsUITests/Info.plist" new file mode 100644 index 0000000..6c40a6c --- /dev/null +++ "b/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/meetingRooms/meetingRoomsUITests/Info.plist" @@ -0,0 +1,22 @@ + + + + + CFBundleDevelopmentRegion + $(DEVELOPMENT_LANGUAGE) + CFBundleExecutable + $(EXECUTABLE_NAME) + CFBundleIdentifier + $(PRODUCT_BUNDLE_IDENTIFIER) + CFBundleInfoDictionaryVersion + 6.0 + CFBundleName + $(PRODUCT_NAME) + CFBundlePackageType + BNDL + CFBundleShortVersionString + 1.0 + CFBundleVersion + 1 + + diff --git "a/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/meetingRooms/meetingRoomsUITests/meetingRoomsUITests.swift" "b/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/meetingRooms/meetingRoomsUITests/meetingRoomsUITests.swift" new file mode 100644 index 0000000..4873bfa --- /dev/null +++ "b/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/meetingRooms/meetingRoomsUITests/meetingRoomsUITests.swift" @@ -0,0 +1,36 @@ +// +// meetingRoomsUITests.swift +// meetingRoomsUITests +// +// Created by 황도증 on 2017. 10. 30.. +// Copyright © 2017년 황도증. All rights reserved. +// + +import XCTest + +class meetingRoomsUITests: XCTestCase { + + override func setUp() { + super.setUp() + + // Put setup code here. This method is called before the invocation of each test method in the class. + + // In UI tests it is usually best to stop immediately when a failure occurs. + continueAfterFailure = false + // UI tests must launch the application that they test. Doing this in setup will make sure it happens for each test method. + XCUIApplication().launch() + + // In UI tests it’s important to set the initial state - such as interface orientation - required for your tests before they run. The setUp method is a good place to do this. + } + + override func tearDown() { + // Put teardown code here. This method is called after the invocation of each test method in the class. + super.tearDown() + } + + func testExample() { + // Use recording to get started writing UI tests. + // Use XCTAssert and related functions to verify your tests produce the correct results. + } + +} diff --git "a/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/meetingRooms_2/meetingRooms.xcodeproj/project.pbxproj" "b/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/meetingRooms_2/meetingRooms.xcodeproj/project.pbxproj" new file mode 100644 index 0000000..c09b5be --- /dev/null +++ "b/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/meetingRooms_2/meetingRooms.xcodeproj/project.pbxproj" @@ -0,0 +1,561 @@ +// !$*UTF8*$! +{ + archiveVersion = 1; + classes = { + }; + objectVersion = 48; + objects = { + +/* Begin PBXBuildFile section */ + AE99575B1FA704AF00397D38 /* AppDelegate.swift in Sources */ = {isa = PBXBuildFile; fileRef = AE99575A1FA704AF00397D38 /* AppDelegate.swift */; }; + AE99575D1FA704AF00397D38 /* ViewController.swift in Sources */ = {isa = PBXBuildFile; fileRef = AE99575C1FA704AF00397D38 /* ViewController.swift */; }; + AE9957601FA704AF00397D38 /* Main.storyboard in Resources */ = {isa = PBXBuildFile; fileRef = AE99575E1FA704AF00397D38 /* Main.storyboard */; }; + AE9957621FA704AF00397D38 /* Assets.xcassets in Resources */ = {isa = PBXBuildFile; fileRef = AE9957611FA704AF00397D38 /* Assets.xcassets */; }; + AE9957651FA704AF00397D38 /* LaunchScreen.storyboard in Resources */ = {isa = PBXBuildFile; fileRef = AE9957631FA704AF00397D38 /* LaunchScreen.storyboard */; }; + AE9957701FA704AF00397D38 /* meetingRoomsTests.swift in Sources */ = {isa = PBXBuildFile; fileRef = AE99576F1FA704AF00397D38 /* meetingRoomsTests.swift */; }; + AE99577B1FA704B000397D38 /* meetingRoomsUITests.swift in Sources */ = {isa = PBXBuildFile; fileRef = AE99577A1FA704B000397D38 /* meetingRoomsUITests.swift */; }; + AE9957891FA7054800397D38 /* MeetingRoomListViewController.swift in Sources */ = {isa = PBXBuildFile; fileRef = AE9957881FA7054800397D38 /* MeetingRoomListViewController.swift */; }; +/* End PBXBuildFile section */ + +/* Begin PBXContainerItemProxy section */ + AE99576C1FA704AF00397D38 /* PBXContainerItemProxy */ = { + isa = PBXContainerItemProxy; + containerPortal = AE99574F1FA704AF00397D38 /* Project object */; + proxyType = 1; + remoteGlobalIDString = AE9957561FA704AF00397D38; + remoteInfo = meetingRooms; + }; + AE9957771FA704B000397D38 /* PBXContainerItemProxy */ = { + isa = PBXContainerItemProxy; + containerPortal = AE99574F1FA704AF00397D38 /* Project object */; + proxyType = 1; + remoteGlobalIDString = AE9957561FA704AF00397D38; + remoteInfo = meetingRooms; + }; +/* End PBXContainerItemProxy section */ + +/* Begin PBXFileReference section */ + AE9957571FA704AF00397D38 /* meetingRooms.app */ = {isa = PBXFileReference; explicitFileType = wrapper.application; includeInIndex = 0; path = meetingRooms.app; sourceTree = BUILT_PRODUCTS_DIR; }; + AE99575A1FA704AF00397D38 /* AppDelegate.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = AppDelegate.swift; sourceTree = ""; }; + AE99575C1FA704AF00397D38 /* ViewController.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = ViewController.swift; sourceTree = ""; }; + AE99575F1FA704AF00397D38 /* Base */ = {isa = PBXFileReference; lastKnownFileType = file.storyboard; name = Base; path = Base.lproj/Main.storyboard; sourceTree = ""; }; + AE9957611FA704AF00397D38 /* Assets.xcassets */ = {isa = PBXFileReference; lastKnownFileType = folder.assetcatalog; path = Assets.xcassets; sourceTree = ""; }; + AE9957641FA704AF00397D38 /* Base */ = {isa = PBXFileReference; lastKnownFileType = file.storyboard; name = Base; path = Base.lproj/LaunchScreen.storyboard; sourceTree = ""; }; + AE9957661FA704AF00397D38 /* Info.plist */ = {isa = PBXFileReference; lastKnownFileType = text.plist.xml; path = Info.plist; sourceTree = ""; }; + AE99576B1FA704AF00397D38 /* meetingRoomsTests.xctest */ = {isa = PBXFileReference; explicitFileType = wrapper.cfbundle; includeInIndex = 0; path = meetingRoomsTests.xctest; sourceTree = BUILT_PRODUCTS_DIR; }; + AE99576F1FA704AF00397D38 /* meetingRoomsTests.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = meetingRoomsTests.swift; sourceTree = ""; }; + AE9957711FA704AF00397D38 /* Info.plist */ = {isa = PBXFileReference; lastKnownFileType = text.plist.xml; path = Info.plist; sourceTree = ""; }; + AE9957761FA704B000397D38 /* meetingRoomsUITests.xctest */ = {isa = PBXFileReference; explicitFileType = wrapper.cfbundle; includeInIndex = 0; path = meetingRoomsUITests.xctest; sourceTree = BUILT_PRODUCTS_DIR; }; + AE99577A1FA704B000397D38 /* meetingRoomsUITests.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = meetingRoomsUITests.swift; sourceTree = ""; }; + AE99577C1FA704B000397D38 /* Info.plist */ = {isa = PBXFileReference; lastKnownFileType = text.plist.xml; path = Info.plist; sourceTree = ""; }; + AE9957881FA7054800397D38 /* MeetingRoomListViewController.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = MeetingRoomListViewController.swift; sourceTree = ""; }; +/* End PBXFileReference section */ + +/* Begin PBXFrameworksBuildPhase section */ + AE9957541FA704AF00397D38 /* Frameworks */ = { + isa = PBXFrameworksBuildPhase; + buildActionMask = 2147483647; + files = ( + ); + runOnlyForDeploymentPostprocessing = 0; + }; + AE9957681FA704AF00397D38 /* Frameworks */ = { + isa = PBXFrameworksBuildPhase; + buildActionMask = 2147483647; + files = ( + ); + runOnlyForDeploymentPostprocessing = 0; + }; + AE9957731FA704B000397D38 /* Frameworks */ = { + isa = PBXFrameworksBuildPhase; + buildActionMask = 2147483647; + files = ( + ); + runOnlyForDeploymentPostprocessing = 0; + }; +/* End PBXFrameworksBuildPhase section */ + +/* Begin PBXGroup section */ + AE99574E1FA704AF00397D38 = { + isa = PBXGroup; + children = ( + AE9957591FA704AF00397D38 /* meetingRooms */, + AE99576E1FA704AF00397D38 /* meetingRoomsTests */, + AE9957791FA704B000397D38 /* meetingRoomsUITests */, + AE9957581FA704AF00397D38 /* Products */, + ); + sourceTree = ""; + }; + AE9957581FA704AF00397D38 /* Products */ = { + isa = PBXGroup; + children = ( + AE9957571FA704AF00397D38 /* meetingRooms.app */, + AE99576B1FA704AF00397D38 /* meetingRoomsTests.xctest */, + AE9957761FA704B000397D38 /* meetingRoomsUITests.xctest */, + ); + name = Products; + sourceTree = ""; + }; + AE9957591FA704AF00397D38 /* meetingRooms */ = { + isa = PBXGroup; + children = ( + AE99575A1FA704AF00397D38 /* AppDelegate.swift */, + AE99575C1FA704AF00397D38 /* ViewController.swift */, + AE99575E1FA704AF00397D38 /* Main.storyboard */, + AE9957881FA7054800397D38 /* MeetingRoomListViewController.swift */, + AE9957611FA704AF00397D38 /* Assets.xcassets */, + AE9957631FA704AF00397D38 /* LaunchScreen.storyboard */, + AE9957661FA704AF00397D38 /* Info.plist */, + ); + path = meetingRooms; + sourceTree = ""; + }; + AE99576E1FA704AF00397D38 /* meetingRoomsTests */ = { + isa = PBXGroup; + children = ( + AE99576F1FA704AF00397D38 /* meetingRoomsTests.swift */, + AE9957711FA704AF00397D38 /* Info.plist */, + ); + path = meetingRoomsTests; + sourceTree = ""; + }; + AE9957791FA704B000397D38 /* meetingRoomsUITests */ = { + isa = PBXGroup; + children = ( + AE99577A1FA704B000397D38 /* meetingRoomsUITests.swift */, + AE99577C1FA704B000397D38 /* Info.plist */, + ); + path = meetingRoomsUITests; + sourceTree = ""; + }; +/* End PBXGroup section */ + +/* Begin PBXNativeTarget section */ + AE9957561FA704AF00397D38 /* meetingRooms */ = { + isa = PBXNativeTarget; + buildConfigurationList = AE99577F1FA704B000397D38 /* Build configuration list for PBXNativeTarget "meetingRooms" */; + buildPhases = ( + AE9957531FA704AF00397D38 /* Sources */, + AE9957541FA704AF00397D38 /* Frameworks */, + AE9957551FA704AF00397D38 /* Resources */, + ); + buildRules = ( + ); + dependencies = ( + ); + name = meetingRooms; + productName = meetingRooms; + productReference = AE9957571FA704AF00397D38 /* meetingRooms.app */; + productType = "com.apple.product-type.application"; + }; + AE99576A1FA704AF00397D38 /* meetingRoomsTests */ = { + isa = PBXNativeTarget; + buildConfigurationList = AE9957821FA704B000397D38 /* Build configuration list for PBXNativeTarget "meetingRoomsTests" */; + buildPhases = ( + AE9957671FA704AF00397D38 /* Sources */, + AE9957681FA704AF00397D38 /* Frameworks */, + AE9957691FA704AF00397D38 /* Resources */, + ); + buildRules = ( + ); + dependencies = ( + AE99576D1FA704AF00397D38 /* PBXTargetDependency */, + ); + name = meetingRoomsTests; + productName = meetingRoomsTests; + productReference = AE99576B1FA704AF00397D38 /* meetingRoomsTests.xctest */; + productType = "com.apple.product-type.bundle.unit-test"; + }; + AE9957751FA704B000397D38 /* meetingRoomsUITests */ = { + isa = PBXNativeTarget; + buildConfigurationList = AE9957851FA704B000397D38 /* Build configuration list for PBXNativeTarget "meetingRoomsUITests" */; + buildPhases = ( + AE9957721FA704B000397D38 /* Sources */, + AE9957731FA704B000397D38 /* Frameworks */, + AE9957741FA704B000397D38 /* Resources */, + ); + buildRules = ( + ); + dependencies = ( + AE9957781FA704B000397D38 /* PBXTargetDependency */, + ); + name = meetingRoomsUITests; + productName = meetingRoomsUITests; + productReference = AE9957761FA704B000397D38 /* meetingRoomsUITests.xctest */; + productType = "com.apple.product-type.bundle.ui-testing"; + }; +/* End PBXNativeTarget section */ + +/* Begin PBXProject section */ + AE99574F1FA704AF00397D38 /* Project object */ = { + isa = PBXProject; + attributes = { + LastSwiftUpdateCheck = 0900; + LastUpgradeCheck = 0900; + ORGANIZATIONNAME = "황도증"; + TargetAttributes = { + AE9957561FA704AF00397D38 = { + CreatedOnToolsVersion = 9.0.1; + ProvisioningStyle = Automatic; + }; + AE99576A1FA704AF00397D38 = { + CreatedOnToolsVersion = 9.0.1; + ProvisioningStyle = Automatic; + TestTargetID = AE9957561FA704AF00397D38; + }; + AE9957751FA704B000397D38 = { + CreatedOnToolsVersion = 9.0.1; + ProvisioningStyle = Automatic; + TestTargetID = AE9957561FA704AF00397D38; + }; + }; + }; + buildConfigurationList = AE9957521FA704AF00397D38 /* Build configuration list for PBXProject "meetingRooms" */; + compatibilityVersion = "Xcode 8.0"; + developmentRegion = en; + hasScannedForEncodings = 0; + knownRegions = ( + en, + Base, + ); + mainGroup = AE99574E1FA704AF00397D38; + productRefGroup = AE9957581FA704AF00397D38 /* Products */; + projectDirPath = ""; + projectRoot = ""; + targets = ( + AE9957561FA704AF00397D38 /* meetingRooms */, + AE99576A1FA704AF00397D38 /* meetingRoomsTests */, + AE9957751FA704B000397D38 /* meetingRoomsUITests */, + ); + }; +/* End PBXProject section */ + +/* Begin PBXResourcesBuildPhase section */ + AE9957551FA704AF00397D38 /* Resources */ = { + isa = PBXResourcesBuildPhase; + buildActionMask = 2147483647; + files = ( + AE9957651FA704AF00397D38 /* LaunchScreen.storyboard in Resources */, + AE9957621FA704AF00397D38 /* Assets.xcassets in Resources */, + AE9957601FA704AF00397D38 /* Main.storyboard in Resources */, + ); + runOnlyForDeploymentPostprocessing = 0; + }; + AE9957691FA704AF00397D38 /* Resources */ = { + isa = PBXResourcesBuildPhase; + buildActionMask = 2147483647; + files = ( + ); + runOnlyForDeploymentPostprocessing = 0; + }; + AE9957741FA704B000397D38 /* Resources */ = { + isa = PBXResourcesBuildPhase; + buildActionMask = 2147483647; + files = ( + ); + runOnlyForDeploymentPostprocessing = 0; + }; +/* End PBXResourcesBuildPhase section */ + +/* Begin PBXSourcesBuildPhase section */ + AE9957531FA704AF00397D38 /* Sources */ = { + isa = PBXSourcesBuildPhase; + buildActionMask = 2147483647; + files = ( + AE99575D1FA704AF00397D38 /* ViewController.swift in Sources */, + AE99575B1FA704AF00397D38 /* AppDelegate.swift in Sources */, + AE9957891FA7054800397D38 /* MeetingRoomListViewController.swift in Sources */, + ); + runOnlyForDeploymentPostprocessing = 0; + }; + AE9957671FA704AF00397D38 /* Sources */ = { + isa = PBXSourcesBuildPhase; + buildActionMask = 2147483647; + files = ( + AE9957701FA704AF00397D38 /* meetingRoomsTests.swift in Sources */, + ); + runOnlyForDeploymentPostprocessing = 0; + }; + AE9957721FA704B000397D38 /* Sources */ = { + isa = PBXSourcesBuildPhase; + buildActionMask = 2147483647; + files = ( + AE99577B1FA704B000397D38 /* meetingRoomsUITests.swift in Sources */, + ); + runOnlyForDeploymentPostprocessing = 0; + }; +/* End PBXSourcesBuildPhase section */ + +/* Begin PBXTargetDependency section */ + AE99576D1FA704AF00397D38 /* PBXTargetDependency */ = { + isa = PBXTargetDependency; + target = AE9957561FA704AF00397D38 /* meetingRooms */; + targetProxy = AE99576C1FA704AF00397D38 /* PBXContainerItemProxy */; + }; + AE9957781FA704B000397D38 /* PBXTargetDependency */ = { + isa = PBXTargetDependency; + target = AE9957561FA704AF00397D38 /* meetingRooms */; + targetProxy = AE9957771FA704B000397D38 /* PBXContainerItemProxy */; + }; +/* End PBXTargetDependency section */ + +/* Begin PBXVariantGroup section */ + AE99575E1FA704AF00397D38 /* Main.storyboard */ = { + isa = PBXVariantGroup; + children = ( + AE99575F1FA704AF00397D38 /* Base */, + ); + name = Main.storyboard; + sourceTree = ""; + }; + AE9957631FA704AF00397D38 /* LaunchScreen.storyboard */ = { + isa = PBXVariantGroup; + children = ( + AE9957641FA704AF00397D38 /* Base */, + ); + name = LaunchScreen.storyboard; + sourceTree = ""; + }; +/* End PBXVariantGroup section */ + +/* Begin XCBuildConfiguration section */ + AE99577D1FA704B000397D38 /* Debug */ = { + isa = XCBuildConfiguration; + buildSettings = { + ALWAYS_SEARCH_USER_PATHS = NO; + CLANG_ANALYZER_NONNULL = YES; + CLANG_ANALYZER_NUMBER_OBJECT_CONVERSION = YES_AGGRESSIVE; + CLANG_CXX_LANGUAGE_STANDARD = "gnu++14"; + CLANG_CXX_LIBRARY = "libc++"; + CLANG_ENABLE_MODULES = YES; + CLANG_ENABLE_OBJC_ARC = YES; + CLANG_WARN_BLOCK_CAPTURE_AUTORELEASING = YES; + CLANG_WARN_BOOL_CONVERSION = YES; + CLANG_WARN_COMMA = YES; + CLANG_WARN_CONSTANT_CONVERSION = YES; + CLANG_WARN_DIRECT_OBJC_ISA_USAGE = YES_ERROR; + CLANG_WARN_DOCUMENTATION_COMMENTS = YES; + CLANG_WARN_EMPTY_BODY = YES; + CLANG_WARN_ENUM_CONVERSION = YES; + CLANG_WARN_INFINITE_RECURSION = YES; + CLANG_WARN_INT_CONVERSION = YES; + CLANG_WARN_NON_LITERAL_NULL_CONVERSION = YES; + CLANG_WARN_OBJC_LITERAL_CONVERSION = YES; + CLANG_WARN_OBJC_ROOT_CLASS = YES_ERROR; + CLANG_WARN_RANGE_LOOP_ANALYSIS = YES; + CLANG_WARN_STRICT_PROTOTYPES = YES; + CLANG_WARN_SUSPICIOUS_MOVE = YES; + CLANG_WARN_UNGUARDED_AVAILABILITY = YES_AGGRESSIVE; + CLANG_WARN_UNREACHABLE_CODE = YES; + CLANG_WARN__DUPLICATE_METHOD_MATCH = YES; + CODE_SIGN_IDENTITY = "iPhone Developer"; + COPY_PHASE_STRIP = NO; + DEBUG_INFORMATION_FORMAT = dwarf; + ENABLE_STRICT_OBJC_MSGSEND = YES; + ENABLE_TESTABILITY = YES; + GCC_C_LANGUAGE_STANDARD = gnu11; + GCC_DYNAMIC_NO_PIC = NO; + GCC_NO_COMMON_BLOCKS = YES; + GCC_OPTIMIZATION_LEVEL = 0; + GCC_PREPROCESSOR_DEFINITIONS = ( + "DEBUG=1", + "$(inherited)", + ); + GCC_WARN_64_TO_32_BIT_CONVERSION = YES; + GCC_WARN_ABOUT_RETURN_TYPE = YES_ERROR; + GCC_WARN_UNDECLARED_SELECTOR = YES; + GCC_WARN_UNINITIALIZED_AUTOS = YES_AGGRESSIVE; + GCC_WARN_UNUSED_FUNCTION = YES; + GCC_WARN_UNUSED_VARIABLE = YES; + IPHONEOS_DEPLOYMENT_TARGET = 11.0; + MTL_ENABLE_DEBUG_INFO = YES; + ONLY_ACTIVE_ARCH = YES; + SDKROOT = iphoneos; + SWIFT_ACTIVE_COMPILATION_CONDITIONS = DEBUG; + SWIFT_OPTIMIZATION_LEVEL = "-Onone"; + }; + name = Debug; + }; + AE99577E1FA704B000397D38 /* Release */ = { + isa = XCBuildConfiguration; + buildSettings = { + ALWAYS_SEARCH_USER_PATHS = NO; + CLANG_ANALYZER_NONNULL = YES; + CLANG_ANALYZER_NUMBER_OBJECT_CONVERSION = YES_AGGRESSIVE; + CLANG_CXX_LANGUAGE_STANDARD = "gnu++14"; + CLANG_CXX_LIBRARY = "libc++"; + CLANG_ENABLE_MODULES = YES; + CLANG_ENABLE_OBJC_ARC = YES; + CLANG_WARN_BLOCK_CAPTURE_AUTORELEASING = YES; + CLANG_WARN_BOOL_CONVERSION = YES; + CLANG_WARN_COMMA = YES; + CLANG_WARN_CONSTANT_CONVERSION = YES; + CLANG_WARN_DIRECT_OBJC_ISA_USAGE = YES_ERROR; + CLANG_WARN_DOCUMENTATION_COMMENTS = YES; + CLANG_WARN_EMPTY_BODY = YES; + CLANG_WARN_ENUM_CONVERSION = YES; + CLANG_WARN_INFINITE_RECURSION = YES; + CLANG_WARN_INT_CONVERSION = YES; + CLANG_WARN_NON_LITERAL_NULL_CONVERSION = YES; + CLANG_WARN_OBJC_LITERAL_CONVERSION = YES; + CLANG_WARN_OBJC_ROOT_CLASS = YES_ERROR; + CLANG_WARN_RANGE_LOOP_ANALYSIS = YES; + CLANG_WARN_STRICT_PROTOTYPES = YES; + CLANG_WARN_SUSPICIOUS_MOVE = YES; + CLANG_WARN_UNGUARDED_AVAILABILITY = YES_AGGRESSIVE; + CLANG_WARN_UNREACHABLE_CODE = YES; + CLANG_WARN__DUPLICATE_METHOD_MATCH = YES; + CODE_SIGN_IDENTITY = "iPhone Developer"; + COPY_PHASE_STRIP = NO; + DEBUG_INFORMATION_FORMAT = "dwarf-with-dsym"; + ENABLE_NS_ASSERTIONS = NO; + ENABLE_STRICT_OBJC_MSGSEND = YES; + GCC_C_LANGUAGE_STANDARD = gnu11; + GCC_NO_COMMON_BLOCKS = YES; + GCC_WARN_64_TO_32_BIT_CONVERSION = YES; + GCC_WARN_ABOUT_RETURN_TYPE = YES_ERROR; + GCC_WARN_UNDECLARED_SELECTOR = YES; + GCC_WARN_UNINITIALIZED_AUTOS = YES_AGGRESSIVE; + GCC_WARN_UNUSED_FUNCTION = YES; + GCC_WARN_UNUSED_VARIABLE = YES; + IPHONEOS_DEPLOYMENT_TARGET = 11.0; + MTL_ENABLE_DEBUG_INFO = NO; + SDKROOT = iphoneos; + SWIFT_OPTIMIZATION_LEVEL = "-Owholemodule"; + VALIDATE_PRODUCT = YES; + }; + name = Release; + }; + AE9957801FA704B000397D38 /* Debug */ = { + isa = XCBuildConfiguration; + buildSettings = { + ASSETCATALOG_COMPILER_APPICON_NAME = AppIcon; + CODE_SIGN_STYLE = Automatic; + INFOPLIST_FILE = meetingRooms/Info.plist; + LD_RUNPATH_SEARCH_PATHS = "$(inherited) @executable_path/Frameworks"; + PRODUCT_BUNDLE_IDENTIFIER = "--------.meetingRooms"; + PRODUCT_NAME = "$(TARGET_NAME)"; + SWIFT_VERSION = 4.0; + TARGETED_DEVICE_FAMILY = "1,2"; + }; + name = Debug; + }; + AE9957811FA704B000397D38 /* Release */ = { + isa = XCBuildConfiguration; + buildSettings = { + ASSETCATALOG_COMPILER_APPICON_NAME = AppIcon; + CODE_SIGN_STYLE = Automatic; + INFOPLIST_FILE = meetingRooms/Info.plist; + LD_RUNPATH_SEARCH_PATHS = "$(inherited) @executable_path/Frameworks"; + PRODUCT_BUNDLE_IDENTIFIER = "--------.meetingRooms"; + PRODUCT_NAME = "$(TARGET_NAME)"; + SWIFT_VERSION = 4.0; + TARGETED_DEVICE_FAMILY = "1,2"; + }; + name = Release; + }; + AE9957831FA704B000397D38 /* Debug */ = { + isa = XCBuildConfiguration; + buildSettings = { + ALWAYS_EMBED_SWIFT_STANDARD_LIBRARIES = YES; + BUNDLE_LOADER = "$(TEST_HOST)"; + CODE_SIGN_STYLE = Automatic; + INFOPLIST_FILE = meetingRoomsTests/Info.plist; + LD_RUNPATH_SEARCH_PATHS = "$(inherited) @executable_path/Frameworks @loader_path/Frameworks"; + PRODUCT_BUNDLE_IDENTIFIER = "--------.meetingRoomsTests"; + PRODUCT_NAME = "$(TARGET_NAME)"; + SWIFT_VERSION = 4.0; + TARGETED_DEVICE_FAMILY = "1,2"; + TEST_HOST = "$(BUILT_PRODUCTS_DIR)/meetingRooms.app/meetingRooms"; + }; + name = Debug; + }; + AE9957841FA704B000397D38 /* Release */ = { + isa = XCBuildConfiguration; + buildSettings = { + ALWAYS_EMBED_SWIFT_STANDARD_LIBRARIES = YES; + BUNDLE_LOADER = "$(TEST_HOST)"; + CODE_SIGN_STYLE = Automatic; + INFOPLIST_FILE = meetingRoomsTests/Info.plist; + LD_RUNPATH_SEARCH_PATHS = "$(inherited) @executable_path/Frameworks @loader_path/Frameworks"; + PRODUCT_BUNDLE_IDENTIFIER = "--------.meetingRoomsTests"; + PRODUCT_NAME = "$(TARGET_NAME)"; + SWIFT_VERSION = 4.0; + TARGETED_DEVICE_FAMILY = "1,2"; + TEST_HOST = "$(BUILT_PRODUCTS_DIR)/meetingRooms.app/meetingRooms"; + }; + name = Release; + }; + AE9957861FA704B000397D38 /* Debug */ = { + isa = XCBuildConfiguration; + buildSettings = { + ALWAYS_EMBED_SWIFT_STANDARD_LIBRARIES = YES; + CODE_SIGN_STYLE = Automatic; + INFOPLIST_FILE = meetingRoomsUITests/Info.plist; + LD_RUNPATH_SEARCH_PATHS = "$(inherited) @executable_path/Frameworks @loader_path/Frameworks"; + PRODUCT_BUNDLE_IDENTIFIER = "--------.meetingRoomsUITests"; + PRODUCT_NAME = "$(TARGET_NAME)"; + SWIFT_VERSION = 4.0; + TARGETED_DEVICE_FAMILY = "1,2"; + TEST_TARGET_NAME = meetingRooms; + }; + name = Debug; + }; + AE9957871FA704B000397D38 /* Release */ = { + isa = XCBuildConfiguration; + buildSettings = { + ALWAYS_EMBED_SWIFT_STANDARD_LIBRARIES = YES; + CODE_SIGN_STYLE = Automatic; + INFOPLIST_FILE = meetingRoomsUITests/Info.plist; + LD_RUNPATH_SEARCH_PATHS = "$(inherited) @executable_path/Frameworks @loader_path/Frameworks"; + PRODUCT_BUNDLE_IDENTIFIER = "--------.meetingRoomsUITests"; + PRODUCT_NAME = "$(TARGET_NAME)"; + SWIFT_VERSION = 4.0; + TARGETED_DEVICE_FAMILY = "1,2"; + TEST_TARGET_NAME = meetingRooms; + }; + name = Release; + }; +/* End XCBuildConfiguration section */ + +/* Begin XCConfigurationList section */ + AE9957521FA704AF00397D38 /* Build configuration list for PBXProject "meetingRooms" */ = { + isa = XCConfigurationList; + buildConfigurations = ( + AE99577D1FA704B000397D38 /* Debug */, + AE99577E1FA704B000397D38 /* Release */, + ); + defaultConfigurationIsVisible = 0; + defaultConfigurationName = Release; + }; + AE99577F1FA704B000397D38 /* Build configuration list for PBXNativeTarget "meetingRooms" */ = { + isa = XCConfigurationList; + buildConfigurations = ( + AE9957801FA704B000397D38 /* Debug */, + AE9957811FA704B000397D38 /* Release */, + ); + defaultConfigurationIsVisible = 0; + defaultConfigurationName = Release; + }; + AE9957821FA704B000397D38 /* Build configuration list for PBXNativeTarget "meetingRoomsTests" */ = { + isa = XCConfigurationList; + buildConfigurations = ( + AE9957831FA704B000397D38 /* Debug */, + AE9957841FA704B000397D38 /* Release */, + ); + defaultConfigurationIsVisible = 0; + defaultConfigurationName = Release; + }; + AE9957851FA704B000397D38 /* Build configuration list for PBXNativeTarget "meetingRoomsUITests" */ = { + isa = XCConfigurationList; + buildConfigurations = ( + AE9957861FA704B000397D38 /* Debug */, + AE9957871FA704B000397D38 /* Release */, + ); + defaultConfigurationIsVisible = 0; + defaultConfigurationName = Release; + }; +/* End XCConfigurationList section */ + }; + rootObject = AE99574F1FA704AF00397D38 /* Project object */; +} diff --git "a/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/meetingRooms_2/meetingRooms.xcodeproj/project.xcworkspace/contents.xcworkspacedata" "b/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/meetingRooms_2/meetingRooms.xcodeproj/project.xcworkspace/contents.xcworkspacedata" new file mode 100644 index 0000000..8491799 --- /dev/null +++ "b/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/meetingRooms_2/meetingRooms.xcodeproj/project.xcworkspace/contents.xcworkspacedata" @@ -0,0 +1,7 @@ + + + + + diff --git "a/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/meetingRooms_2/meetingRooms/AppDelegate.swift" "b/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/meetingRooms_2/meetingRooms/AppDelegate.swift" new file mode 100644 index 0000000..fc60321 --- /dev/null +++ "b/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/meetingRooms_2/meetingRooms/AppDelegate.swift" @@ -0,0 +1,46 @@ +// +// AppDelegate.swift +// meetingRooms +// +// Created by 황도증 on 2017. 10. 30.. +// Copyright © 2017년 황도증. All rights reserved. +// + +import UIKit + +@UIApplicationMain +class AppDelegate: UIResponder, UIApplicationDelegate { + + var window: UIWindow? + + + func application(_ application: UIApplication, didFinishLaunchingWithOptions launchOptions: [UIApplicationLaunchOptionsKey: Any]?) -> Bool { + // Override point for customization after application launch. + return true + } + + func applicationWillResignActive(_ application: UIApplication) { + // Sent when the application is about to move from active to inactive state. This can occur for certain types of temporary interruptions (such as an incoming phone call or SMS message) or when the user quits the application and it begins the transition to the background state. + // Use this method to pause ongoing tasks, disable timers, and invalidate graphics rendering callbacks. Games should use this method to pause the game. + } + + func applicationDidEnterBackground(_ application: UIApplication) { + // Use this method to release shared resources, save user data, invalidate timers, and store enough application state information to restore your application to its current state in case it is terminated later. + // If your application supports background execution, this method is called instead of applicationWillTerminate: when the user quits. + } + + func applicationWillEnterForeground(_ application: UIApplication) { + // Called as part of the transition from the background to the active state; here you can undo many of the changes made on entering the background. + } + + func applicationDidBecomeActive(_ application: UIApplication) { + // Restart any tasks that were paused (or not yet started) while the application was inactive. If the application was previously in the background, optionally refresh the user interface. + } + + func applicationWillTerminate(_ application: UIApplication) { + // Called when the application is about to terminate. Save data if appropriate. See also applicationDidEnterBackground:. + } + + +} + diff --git "a/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/meetingRooms_2/meetingRooms/Assets.xcassets/AppIcon.appiconset/Contents.json" "b/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/meetingRooms_2/meetingRooms/Assets.xcassets/AppIcon.appiconset/Contents.json" new file mode 100644 index 0000000..d8db8d6 --- /dev/null +++ "b/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/meetingRooms_2/meetingRooms/Assets.xcassets/AppIcon.appiconset/Contents.json" @@ -0,0 +1,98 @@ +{ + "images" : [ + { + "idiom" : "iphone", + "size" : "20x20", + "scale" : "2x" + }, + { + "idiom" : "iphone", + "size" : "20x20", + "scale" : "3x" + }, + { + "idiom" : "iphone", + "size" : "29x29", + "scale" : "2x" + }, + { + "idiom" : "iphone", + "size" : "29x29", + "scale" : "3x" + }, + { + "idiom" : "iphone", + "size" : "40x40", + "scale" : "2x" + }, + { + "idiom" : "iphone", + "size" : "40x40", + "scale" : "3x" + }, + { + "idiom" : "iphone", + "size" : "60x60", + "scale" : "2x" + }, + { + "idiom" : "iphone", + "size" : "60x60", + "scale" : "3x" + }, + { + "idiom" : "ipad", + "size" : "20x20", + "scale" : "1x" + }, + { + "idiom" : "ipad", + "size" : "20x20", + "scale" : "2x" + }, + { + "idiom" : "ipad", + "size" : "29x29", + "scale" : "1x" + }, + { + "idiom" : "ipad", + "size" : "29x29", + "scale" : "2x" + }, + { + "idiom" : "ipad", + "size" : "40x40", + "scale" : "1x" + }, + { + "idiom" : "ipad", + "size" : "40x40", + "scale" : "2x" + }, + { + "idiom" : "ipad", + "size" : "76x76", + "scale" : "1x" + }, + { + "idiom" : "ipad", + "size" : "76x76", + "scale" : "2x" + }, + { + "idiom" : "ipad", + "size" : "83.5x83.5", + "scale" : "2x" + }, + { + "idiom" : "ios-marketing", + "size" : "1024x1024", + "scale" : "1x" + } + ], + "info" : { + "version" : 1, + "author" : "xcode" + } +} \ No newline at end of file diff --git "a/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/meetingRooms_2/meetingRooms/Base.lproj/LaunchScreen.storyboard" "b/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/meetingRooms_2/meetingRooms/Base.lproj/LaunchScreen.storyboard" new file mode 100644 index 0000000..f83f6fd --- /dev/null +++ "b/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/meetingRooms_2/meetingRooms/Base.lproj/LaunchScreen.storyboard" @@ -0,0 +1,25 @@ + + + + + + + + + + + + + + + + + + + + + + + + + diff --git "a/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/meetingRooms_2/meetingRooms/Base.lproj/Main.storyboard" "b/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/meetingRooms_2/meetingRooms/Base.lproj/Main.storyboard" new file mode 100644 index 0000000..ff29a4c --- /dev/null +++ "b/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/meetingRooms_2/meetingRooms/Base.lproj/Main.storyboard" @@ -0,0 +1,56 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + diff --git "a/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/meetingRooms_2/meetingRooms/Info.plist" "b/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/meetingRooms_2/meetingRooms/Info.plist" new file mode 100644 index 0000000..16be3b6 --- /dev/null +++ "b/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/meetingRooms_2/meetingRooms/Info.plist" @@ -0,0 +1,45 @@ + + + + + CFBundleDevelopmentRegion + $(DEVELOPMENT_LANGUAGE) + CFBundleExecutable + $(EXECUTABLE_NAME) + CFBundleIdentifier + $(PRODUCT_BUNDLE_IDENTIFIER) + CFBundleInfoDictionaryVersion + 6.0 + CFBundleName + $(PRODUCT_NAME) + CFBundlePackageType + APPL + CFBundleShortVersionString + 1.0 + CFBundleVersion + 1 + LSRequiresIPhoneOS + + UILaunchStoryboardName + LaunchScreen + UIMainStoryboardFile + Main + UIRequiredDeviceCapabilities + + armv7 + + UISupportedInterfaceOrientations + + UIInterfaceOrientationPortrait + UIInterfaceOrientationLandscapeLeft + UIInterfaceOrientationLandscapeRight + + UISupportedInterfaceOrientations~ipad + + UIInterfaceOrientationPortrait + UIInterfaceOrientationPortraitUpsideDown + UIInterfaceOrientationLandscapeLeft + UIInterfaceOrientationLandscapeRight + + + diff --git "a/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/meetingRooms_2/meetingRooms/MeetingRoomListViewController.swift" "b/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/meetingRooms_2/meetingRooms/MeetingRoomListViewController.swift" new file mode 100644 index 0000000..3ddb971 --- /dev/null +++ "b/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/meetingRooms_2/meetingRooms/MeetingRoomListViewController.swift" @@ -0,0 +1,104 @@ +// +// MeetingRoomListViewController.swift +// meetingRooms +// +// Created by 황도증 on 2017. 10. 30.. +// Copyright © 2017년 황도증. All rights reserved. +// + +import UIKit + +class MeetingRoomListViewController: UITableViewController { + + var meetingRooms:[String:[String:Int]] = ["Meeting":["Banksy":4, "Rivera":8, "Kahlo":10], "Seminar":["Cezanne":20, "Matisse":30, "Renoir":40]] + + override func viewDidLoad() { + super.viewDidLoad() + + // Uncomment the following line to preserve selection between presentations + // self.clearsSelectionOnViewWillAppear = false + + // Uncomment the following line to display an Edit button in the navigation bar for this view controller. + // self.navigationItem.rightBarButtonItem = self.editButtonItem + } + + override func didReceiveMemoryWarning() { + super.didReceiveMemoryWarning() + // Dispose of any resources that can be recreated. + } + + // MARK: - Table view data source + + override func numberOfSections(in tableView: UITableView) -> Int { + // #warning Incomplete implementation, return the number of sections + return meetingRooms.count + } + + override func tableView(_ tableView: UITableView, numberOfRowsInSection section: Int) -> Int { + // #warning Incomplete implementation, return the number of rows + let categoryValues = Array(meetingRooms.values)[section] + return categoryValues.count + } + + + override func tableView(_ tableView: UITableView, cellForRowAt indexPath: IndexPath) -> UITableViewCell { + let cell = tableView.dequeueReusableCell(withIdentifier: "MyCell", for: indexPath) + + // Configure the cell... + let categoryValue = Array(meetingRooms.values)[indexPath.section] + + let roomName = Array(categoryValue.keys)[indexPath.row] + let capacity = Array(categoryValue.values)[indexPath.row] + + cell.textLabel!.text = roomName + cell.detailTextLabel!.text = "\(capacity)" + return cell + } + + + /* + // Override to support conditional editing of the table view. + override func tableView(_ tableView: UITableView, canEditRowAt indexPath: IndexPath) -> Bool { + // Return false if you do not want the specified item to be editable. + return true + } + */ + + /* + // Override to support editing the table view. + override func tableView(_ tableView: UITableView, commit editingStyle: UITableViewCellEditingStyle, forRowAt indexPath: IndexPath) { + if editingStyle == .delete { + // Delete the row from the data source + tableView.deleteRows(at: [indexPath], with: .fade) + } else if editingStyle == .insert { + // Create a new instance of the appropriate class, insert it into the array, and add a new row to the table view + } + } + */ + + /* + // Override to support rearranging the table view. + override func tableView(_ tableView: UITableView, moveRowAt fromIndexPath: IndexPath, to: IndexPath) { + + } + */ + + /* + // Override to support conditional rearranging of the table view. + override func tableView(_ tableView: UITableView, canMoveRowAt indexPath: IndexPath) -> Bool { + // Return false if you do not want the item to be re-orderable. + return true + } + */ + + /* + // MARK: - Navigation + + // In a storyboard-based application, you will often want to do a little preparation before navigation + override func prepare(for segue: UIStoryboardSegue, sender: Any?) { + // Get the new view controller using segue.destinationViewController. + // Pass the selected object to the new view controller. + } + */ + +} diff --git "a/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/meetingRooms_2/meetingRooms/ViewController.swift" "b/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/meetingRooms_2/meetingRooms/ViewController.swift" new file mode 100644 index 0000000..24bd9b0 --- /dev/null +++ "b/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/meetingRooms_2/meetingRooms/ViewController.swift" @@ -0,0 +1,25 @@ +// +// ViewController.swift +// meetingRooms +// +// Created by 황도증 on 2017. 10. 30.. +// Copyright © 2017년 황도증. All rights reserved. +// + +import UIKit + +class ViewController: UIViewController { + + override func viewDidLoad() { + super.viewDidLoad() + // Do any additional setup after loading the view, typically from a nib. + } + + override func didReceiveMemoryWarning() { + super.didReceiveMemoryWarning() + // Dispose of any resources that can be recreated. + } + + +} + diff --git "a/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/meetingRooms_2/meetingRoomsTests/Info.plist" "b/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/meetingRooms_2/meetingRoomsTests/Info.plist" new file mode 100644 index 0000000..6c40a6c --- /dev/null +++ "b/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/meetingRooms_2/meetingRoomsTests/Info.plist" @@ -0,0 +1,22 @@ + + + + + CFBundleDevelopmentRegion + $(DEVELOPMENT_LANGUAGE) + CFBundleExecutable + $(EXECUTABLE_NAME) + CFBundleIdentifier + $(PRODUCT_BUNDLE_IDENTIFIER) + CFBundleInfoDictionaryVersion + 6.0 + CFBundleName + $(PRODUCT_NAME) + CFBundlePackageType + BNDL + CFBundleShortVersionString + 1.0 + CFBundleVersion + 1 + + diff --git "a/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/meetingRooms_2/meetingRoomsTests/meetingRoomsTests.swift" "b/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/meetingRooms_2/meetingRoomsTests/meetingRoomsTests.swift" new file mode 100644 index 0000000..bfbd8d6 --- /dev/null +++ "b/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/meetingRooms_2/meetingRoomsTests/meetingRoomsTests.swift" @@ -0,0 +1,36 @@ +// +// meetingRoomsTests.swift +// meetingRoomsTests +// +// Created by 황도증 on 2017. 10. 30.. +// Copyright © 2017년 황도증. All rights reserved. +// + +import XCTest +@testable import meetingRooms + +class meetingRoomsTests: XCTestCase { + + override func setUp() { + super.setUp() + // Put setup code here. This method is called before the invocation of each test method in the class. + } + + override func tearDown() { + // Put teardown code here. This method is called after the invocation of each test method in the class. + super.tearDown() + } + + func testExample() { + // This is an example of a functional test case. + // Use XCTAssert and related functions to verify your tests produce the correct results. + } + + func testPerformanceExample() { + // This is an example of a performance test case. + self.measure { + // Put the code you want to measure the time of here. + } + } + +} diff --git "a/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/meetingRooms_2/meetingRoomsUITests/Info.plist" "b/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/meetingRooms_2/meetingRoomsUITests/Info.plist" new file mode 100644 index 0000000..6c40a6c --- /dev/null +++ "b/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/meetingRooms_2/meetingRoomsUITests/Info.plist" @@ -0,0 +1,22 @@ + + + + + CFBundleDevelopmentRegion + $(DEVELOPMENT_LANGUAGE) + CFBundleExecutable + $(EXECUTABLE_NAME) + CFBundleIdentifier + $(PRODUCT_BUNDLE_IDENTIFIER) + CFBundleInfoDictionaryVersion + 6.0 + CFBundleName + $(PRODUCT_NAME) + CFBundlePackageType + BNDL + CFBundleShortVersionString + 1.0 + CFBundleVersion + 1 + + diff --git "a/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/meetingRooms_2/meetingRoomsUITests/meetingRoomsUITests.swift" "b/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/meetingRooms_2/meetingRoomsUITests/meetingRoomsUITests.swift" new file mode 100644 index 0000000..4873bfa --- /dev/null +++ "b/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/meetingRooms_2/meetingRoomsUITests/meetingRoomsUITests.swift" @@ -0,0 +1,36 @@ +// +// meetingRoomsUITests.swift +// meetingRoomsUITests +// +// Created by 황도증 on 2017. 10. 30.. +// Copyright © 2017년 황도증. All rights reserved. +// + +import XCTest + +class meetingRoomsUITests: XCTestCase { + + override func setUp() { + super.setUp() + + // Put setup code here. This method is called before the invocation of each test method in the class. + + // In UI tests it is usually best to stop immediately when a failure occurs. + continueAfterFailure = false + // UI tests must launch the application that they test. Doing this in setup will make sure it happens for each test method. + XCUIApplication().launch() + + // In UI tests it’s important to set the initial state - such as interface orientation - required for your tests before they run. The setUp method is a good place to do this. + } + + override func tearDown() { + // Put teardown code here. This method is called after the invocation of each test method in the class. + super.tearDown() + } + + func testExample() { + // Use recording to get started writing UI tests. + // Use XCTAssert and related functions to verify your tests produce the correct results. + } + +} diff --git "a/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/meetingRooms_3/meetingRooms.xcodeproj/project.pbxproj" "b/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/meetingRooms_3/meetingRooms.xcodeproj/project.pbxproj" new file mode 100644 index 0000000..c09b5be --- /dev/null +++ "b/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/meetingRooms_3/meetingRooms.xcodeproj/project.pbxproj" @@ -0,0 +1,561 @@ +// !$*UTF8*$! +{ + archiveVersion = 1; + classes = { + }; + objectVersion = 48; + objects = { + +/* Begin PBXBuildFile section */ + AE99575B1FA704AF00397D38 /* AppDelegate.swift in Sources */ = {isa = PBXBuildFile; fileRef = AE99575A1FA704AF00397D38 /* AppDelegate.swift */; }; + AE99575D1FA704AF00397D38 /* ViewController.swift in Sources */ = {isa = PBXBuildFile; fileRef = AE99575C1FA704AF00397D38 /* ViewController.swift */; }; + AE9957601FA704AF00397D38 /* Main.storyboard in Resources */ = {isa = PBXBuildFile; fileRef = AE99575E1FA704AF00397D38 /* Main.storyboard */; }; + AE9957621FA704AF00397D38 /* Assets.xcassets in Resources */ = {isa = PBXBuildFile; fileRef = AE9957611FA704AF00397D38 /* Assets.xcassets */; }; + AE9957651FA704AF00397D38 /* LaunchScreen.storyboard in Resources */ = {isa = PBXBuildFile; fileRef = AE9957631FA704AF00397D38 /* LaunchScreen.storyboard */; }; + AE9957701FA704AF00397D38 /* meetingRoomsTests.swift in Sources */ = {isa = PBXBuildFile; fileRef = AE99576F1FA704AF00397D38 /* meetingRoomsTests.swift */; }; + AE99577B1FA704B000397D38 /* meetingRoomsUITests.swift in Sources */ = {isa = PBXBuildFile; fileRef = AE99577A1FA704B000397D38 /* meetingRoomsUITests.swift */; }; + AE9957891FA7054800397D38 /* MeetingRoomListViewController.swift in Sources */ = {isa = PBXBuildFile; fileRef = AE9957881FA7054800397D38 /* MeetingRoomListViewController.swift */; }; +/* End PBXBuildFile section */ + +/* Begin PBXContainerItemProxy section */ + AE99576C1FA704AF00397D38 /* PBXContainerItemProxy */ = { + isa = PBXContainerItemProxy; + containerPortal = AE99574F1FA704AF00397D38 /* Project object */; + proxyType = 1; + remoteGlobalIDString = AE9957561FA704AF00397D38; + remoteInfo = meetingRooms; + }; + AE9957771FA704B000397D38 /* PBXContainerItemProxy */ = { + isa = PBXContainerItemProxy; + containerPortal = AE99574F1FA704AF00397D38 /* Project object */; + proxyType = 1; + remoteGlobalIDString = AE9957561FA704AF00397D38; + remoteInfo = meetingRooms; + }; +/* End PBXContainerItemProxy section */ + +/* Begin PBXFileReference section */ + AE9957571FA704AF00397D38 /* meetingRooms.app */ = {isa = PBXFileReference; explicitFileType = wrapper.application; includeInIndex = 0; path = meetingRooms.app; sourceTree = BUILT_PRODUCTS_DIR; }; + AE99575A1FA704AF00397D38 /* AppDelegate.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = AppDelegate.swift; sourceTree = ""; }; + AE99575C1FA704AF00397D38 /* ViewController.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = ViewController.swift; sourceTree = ""; }; + AE99575F1FA704AF00397D38 /* Base */ = {isa = PBXFileReference; lastKnownFileType = file.storyboard; name = Base; path = Base.lproj/Main.storyboard; sourceTree = ""; }; + AE9957611FA704AF00397D38 /* Assets.xcassets */ = {isa = PBXFileReference; lastKnownFileType = folder.assetcatalog; path = Assets.xcassets; sourceTree = ""; }; + AE9957641FA704AF00397D38 /* Base */ = {isa = PBXFileReference; lastKnownFileType = file.storyboard; name = Base; path = Base.lproj/LaunchScreen.storyboard; sourceTree = ""; }; + AE9957661FA704AF00397D38 /* Info.plist */ = {isa = PBXFileReference; lastKnownFileType = text.plist.xml; path = Info.plist; sourceTree = ""; }; + AE99576B1FA704AF00397D38 /* meetingRoomsTests.xctest */ = {isa = PBXFileReference; explicitFileType = wrapper.cfbundle; includeInIndex = 0; path = meetingRoomsTests.xctest; sourceTree = BUILT_PRODUCTS_DIR; }; + AE99576F1FA704AF00397D38 /* meetingRoomsTests.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = meetingRoomsTests.swift; sourceTree = ""; }; + AE9957711FA704AF00397D38 /* Info.plist */ = {isa = PBXFileReference; lastKnownFileType = text.plist.xml; path = Info.plist; sourceTree = ""; }; + AE9957761FA704B000397D38 /* meetingRoomsUITests.xctest */ = {isa = PBXFileReference; explicitFileType = wrapper.cfbundle; includeInIndex = 0; path = meetingRoomsUITests.xctest; sourceTree = BUILT_PRODUCTS_DIR; }; + AE99577A1FA704B000397D38 /* meetingRoomsUITests.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = meetingRoomsUITests.swift; sourceTree = ""; }; + AE99577C1FA704B000397D38 /* Info.plist */ = {isa = PBXFileReference; lastKnownFileType = text.plist.xml; path = Info.plist; sourceTree = ""; }; + AE9957881FA7054800397D38 /* MeetingRoomListViewController.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = MeetingRoomListViewController.swift; sourceTree = ""; }; +/* End PBXFileReference section */ + +/* Begin PBXFrameworksBuildPhase section */ + AE9957541FA704AF00397D38 /* Frameworks */ = { + isa = PBXFrameworksBuildPhase; + buildActionMask = 2147483647; + files = ( + ); + runOnlyForDeploymentPostprocessing = 0; + }; + AE9957681FA704AF00397D38 /* Frameworks */ = { + isa = PBXFrameworksBuildPhase; + buildActionMask = 2147483647; + files = ( + ); + runOnlyForDeploymentPostprocessing = 0; + }; + AE9957731FA704B000397D38 /* Frameworks */ = { + isa = PBXFrameworksBuildPhase; + buildActionMask = 2147483647; + files = ( + ); + runOnlyForDeploymentPostprocessing = 0; + }; +/* End PBXFrameworksBuildPhase section */ + +/* Begin PBXGroup section */ + AE99574E1FA704AF00397D38 = { + isa = PBXGroup; + children = ( + AE9957591FA704AF00397D38 /* meetingRooms */, + AE99576E1FA704AF00397D38 /* meetingRoomsTests */, + AE9957791FA704B000397D38 /* meetingRoomsUITests */, + AE9957581FA704AF00397D38 /* Products */, + ); + sourceTree = ""; + }; + AE9957581FA704AF00397D38 /* Products */ = { + isa = PBXGroup; + children = ( + AE9957571FA704AF00397D38 /* meetingRooms.app */, + AE99576B1FA704AF00397D38 /* meetingRoomsTests.xctest */, + AE9957761FA704B000397D38 /* meetingRoomsUITests.xctest */, + ); + name = Products; + sourceTree = ""; + }; + AE9957591FA704AF00397D38 /* meetingRooms */ = { + isa = PBXGroup; + children = ( + AE99575A1FA704AF00397D38 /* AppDelegate.swift */, + AE99575C1FA704AF00397D38 /* ViewController.swift */, + AE99575E1FA704AF00397D38 /* Main.storyboard */, + AE9957881FA7054800397D38 /* MeetingRoomListViewController.swift */, + AE9957611FA704AF00397D38 /* Assets.xcassets */, + AE9957631FA704AF00397D38 /* LaunchScreen.storyboard */, + AE9957661FA704AF00397D38 /* Info.plist */, + ); + path = meetingRooms; + sourceTree = ""; + }; + AE99576E1FA704AF00397D38 /* meetingRoomsTests */ = { + isa = PBXGroup; + children = ( + AE99576F1FA704AF00397D38 /* meetingRoomsTests.swift */, + AE9957711FA704AF00397D38 /* Info.plist */, + ); + path = meetingRoomsTests; + sourceTree = ""; + }; + AE9957791FA704B000397D38 /* meetingRoomsUITests */ = { + isa = PBXGroup; + children = ( + AE99577A1FA704B000397D38 /* meetingRoomsUITests.swift */, + AE99577C1FA704B000397D38 /* Info.plist */, + ); + path = meetingRoomsUITests; + sourceTree = ""; + }; +/* End PBXGroup section */ + +/* Begin PBXNativeTarget section */ + AE9957561FA704AF00397D38 /* meetingRooms */ = { + isa = PBXNativeTarget; + buildConfigurationList = AE99577F1FA704B000397D38 /* Build configuration list for PBXNativeTarget "meetingRooms" */; + buildPhases = ( + AE9957531FA704AF00397D38 /* Sources */, + AE9957541FA704AF00397D38 /* Frameworks */, + AE9957551FA704AF00397D38 /* Resources */, + ); + buildRules = ( + ); + dependencies = ( + ); + name = meetingRooms; + productName = meetingRooms; + productReference = AE9957571FA704AF00397D38 /* meetingRooms.app */; + productType = "com.apple.product-type.application"; + }; + AE99576A1FA704AF00397D38 /* meetingRoomsTests */ = { + isa = PBXNativeTarget; + buildConfigurationList = AE9957821FA704B000397D38 /* Build configuration list for PBXNativeTarget "meetingRoomsTests" */; + buildPhases = ( + AE9957671FA704AF00397D38 /* Sources */, + AE9957681FA704AF00397D38 /* Frameworks */, + AE9957691FA704AF00397D38 /* Resources */, + ); + buildRules = ( + ); + dependencies = ( + AE99576D1FA704AF00397D38 /* PBXTargetDependency */, + ); + name = meetingRoomsTests; + productName = meetingRoomsTests; + productReference = AE99576B1FA704AF00397D38 /* meetingRoomsTests.xctest */; + productType = "com.apple.product-type.bundle.unit-test"; + }; + AE9957751FA704B000397D38 /* meetingRoomsUITests */ = { + isa = PBXNativeTarget; + buildConfigurationList = AE9957851FA704B000397D38 /* Build configuration list for PBXNativeTarget "meetingRoomsUITests" */; + buildPhases = ( + AE9957721FA704B000397D38 /* Sources */, + AE9957731FA704B000397D38 /* Frameworks */, + AE9957741FA704B000397D38 /* Resources */, + ); + buildRules = ( + ); + dependencies = ( + AE9957781FA704B000397D38 /* PBXTargetDependency */, + ); + name = meetingRoomsUITests; + productName = meetingRoomsUITests; + productReference = AE9957761FA704B000397D38 /* meetingRoomsUITests.xctest */; + productType = "com.apple.product-type.bundle.ui-testing"; + }; +/* End PBXNativeTarget section */ + +/* Begin PBXProject section */ + AE99574F1FA704AF00397D38 /* Project object */ = { + isa = PBXProject; + attributes = { + LastSwiftUpdateCheck = 0900; + LastUpgradeCheck = 0900; + ORGANIZATIONNAME = "황도증"; + TargetAttributes = { + AE9957561FA704AF00397D38 = { + CreatedOnToolsVersion = 9.0.1; + ProvisioningStyle = Automatic; + }; + AE99576A1FA704AF00397D38 = { + CreatedOnToolsVersion = 9.0.1; + ProvisioningStyle = Automatic; + TestTargetID = AE9957561FA704AF00397D38; + }; + AE9957751FA704B000397D38 = { + CreatedOnToolsVersion = 9.0.1; + ProvisioningStyle = Automatic; + TestTargetID = AE9957561FA704AF00397D38; + }; + }; + }; + buildConfigurationList = AE9957521FA704AF00397D38 /* Build configuration list for PBXProject "meetingRooms" */; + compatibilityVersion = "Xcode 8.0"; + developmentRegion = en; + hasScannedForEncodings = 0; + knownRegions = ( + en, + Base, + ); + mainGroup = AE99574E1FA704AF00397D38; + productRefGroup = AE9957581FA704AF00397D38 /* Products */; + projectDirPath = ""; + projectRoot = ""; + targets = ( + AE9957561FA704AF00397D38 /* meetingRooms */, + AE99576A1FA704AF00397D38 /* meetingRoomsTests */, + AE9957751FA704B000397D38 /* meetingRoomsUITests */, + ); + }; +/* End PBXProject section */ + +/* Begin PBXResourcesBuildPhase section */ + AE9957551FA704AF00397D38 /* Resources */ = { + isa = PBXResourcesBuildPhase; + buildActionMask = 2147483647; + files = ( + AE9957651FA704AF00397D38 /* LaunchScreen.storyboard in Resources */, + AE9957621FA704AF00397D38 /* Assets.xcassets in Resources */, + AE9957601FA704AF00397D38 /* Main.storyboard in Resources */, + ); + runOnlyForDeploymentPostprocessing = 0; + }; + AE9957691FA704AF00397D38 /* Resources */ = { + isa = PBXResourcesBuildPhase; + buildActionMask = 2147483647; + files = ( + ); + runOnlyForDeploymentPostprocessing = 0; + }; + AE9957741FA704B000397D38 /* Resources */ = { + isa = PBXResourcesBuildPhase; + buildActionMask = 2147483647; + files = ( + ); + runOnlyForDeploymentPostprocessing = 0; + }; +/* End PBXResourcesBuildPhase section */ + +/* Begin PBXSourcesBuildPhase section */ + AE9957531FA704AF00397D38 /* Sources */ = { + isa = PBXSourcesBuildPhase; + buildActionMask = 2147483647; + files = ( + AE99575D1FA704AF00397D38 /* ViewController.swift in Sources */, + AE99575B1FA704AF00397D38 /* AppDelegate.swift in Sources */, + AE9957891FA7054800397D38 /* MeetingRoomListViewController.swift in Sources */, + ); + runOnlyForDeploymentPostprocessing = 0; + }; + AE9957671FA704AF00397D38 /* Sources */ = { + isa = PBXSourcesBuildPhase; + buildActionMask = 2147483647; + files = ( + AE9957701FA704AF00397D38 /* meetingRoomsTests.swift in Sources */, + ); + runOnlyForDeploymentPostprocessing = 0; + }; + AE9957721FA704B000397D38 /* Sources */ = { + isa = PBXSourcesBuildPhase; + buildActionMask = 2147483647; + files = ( + AE99577B1FA704B000397D38 /* meetingRoomsUITests.swift in Sources */, + ); + runOnlyForDeploymentPostprocessing = 0; + }; +/* End PBXSourcesBuildPhase section */ + +/* Begin PBXTargetDependency section */ + AE99576D1FA704AF00397D38 /* PBXTargetDependency */ = { + isa = PBXTargetDependency; + target = AE9957561FA704AF00397D38 /* meetingRooms */; + targetProxy = AE99576C1FA704AF00397D38 /* PBXContainerItemProxy */; + }; + AE9957781FA704B000397D38 /* PBXTargetDependency */ = { + isa = PBXTargetDependency; + target = AE9957561FA704AF00397D38 /* meetingRooms */; + targetProxy = AE9957771FA704B000397D38 /* PBXContainerItemProxy */; + }; +/* End PBXTargetDependency section */ + +/* Begin PBXVariantGroup section */ + AE99575E1FA704AF00397D38 /* Main.storyboard */ = { + isa = PBXVariantGroup; + children = ( + AE99575F1FA704AF00397D38 /* Base */, + ); + name = Main.storyboard; + sourceTree = ""; + }; + AE9957631FA704AF00397D38 /* LaunchScreen.storyboard */ = { + isa = PBXVariantGroup; + children = ( + AE9957641FA704AF00397D38 /* Base */, + ); + name = LaunchScreen.storyboard; + sourceTree = ""; + }; +/* End PBXVariantGroup section */ + +/* Begin XCBuildConfiguration section */ + AE99577D1FA704B000397D38 /* Debug */ = { + isa = XCBuildConfiguration; + buildSettings = { + ALWAYS_SEARCH_USER_PATHS = NO; + CLANG_ANALYZER_NONNULL = YES; + CLANG_ANALYZER_NUMBER_OBJECT_CONVERSION = YES_AGGRESSIVE; + CLANG_CXX_LANGUAGE_STANDARD = "gnu++14"; + CLANG_CXX_LIBRARY = "libc++"; + CLANG_ENABLE_MODULES = YES; + CLANG_ENABLE_OBJC_ARC = YES; + CLANG_WARN_BLOCK_CAPTURE_AUTORELEASING = YES; + CLANG_WARN_BOOL_CONVERSION = YES; + CLANG_WARN_COMMA = YES; + CLANG_WARN_CONSTANT_CONVERSION = YES; + CLANG_WARN_DIRECT_OBJC_ISA_USAGE = YES_ERROR; + CLANG_WARN_DOCUMENTATION_COMMENTS = YES; + CLANG_WARN_EMPTY_BODY = YES; + CLANG_WARN_ENUM_CONVERSION = YES; + CLANG_WARN_INFINITE_RECURSION = YES; + CLANG_WARN_INT_CONVERSION = YES; + CLANG_WARN_NON_LITERAL_NULL_CONVERSION = YES; + CLANG_WARN_OBJC_LITERAL_CONVERSION = YES; + CLANG_WARN_OBJC_ROOT_CLASS = YES_ERROR; + CLANG_WARN_RANGE_LOOP_ANALYSIS = YES; + CLANG_WARN_STRICT_PROTOTYPES = YES; + CLANG_WARN_SUSPICIOUS_MOVE = YES; + CLANG_WARN_UNGUARDED_AVAILABILITY = YES_AGGRESSIVE; + CLANG_WARN_UNREACHABLE_CODE = YES; + CLANG_WARN__DUPLICATE_METHOD_MATCH = YES; + CODE_SIGN_IDENTITY = "iPhone Developer"; + COPY_PHASE_STRIP = NO; + DEBUG_INFORMATION_FORMAT = dwarf; + ENABLE_STRICT_OBJC_MSGSEND = YES; + ENABLE_TESTABILITY = YES; + GCC_C_LANGUAGE_STANDARD = gnu11; + GCC_DYNAMIC_NO_PIC = NO; + GCC_NO_COMMON_BLOCKS = YES; + GCC_OPTIMIZATION_LEVEL = 0; + GCC_PREPROCESSOR_DEFINITIONS = ( + "DEBUG=1", + "$(inherited)", + ); + GCC_WARN_64_TO_32_BIT_CONVERSION = YES; + GCC_WARN_ABOUT_RETURN_TYPE = YES_ERROR; + GCC_WARN_UNDECLARED_SELECTOR = YES; + GCC_WARN_UNINITIALIZED_AUTOS = YES_AGGRESSIVE; + GCC_WARN_UNUSED_FUNCTION = YES; + GCC_WARN_UNUSED_VARIABLE = YES; + IPHONEOS_DEPLOYMENT_TARGET = 11.0; + MTL_ENABLE_DEBUG_INFO = YES; + ONLY_ACTIVE_ARCH = YES; + SDKROOT = iphoneos; + SWIFT_ACTIVE_COMPILATION_CONDITIONS = DEBUG; + SWIFT_OPTIMIZATION_LEVEL = "-Onone"; + }; + name = Debug; + }; + AE99577E1FA704B000397D38 /* Release */ = { + isa = XCBuildConfiguration; + buildSettings = { + ALWAYS_SEARCH_USER_PATHS = NO; + CLANG_ANALYZER_NONNULL = YES; + CLANG_ANALYZER_NUMBER_OBJECT_CONVERSION = YES_AGGRESSIVE; + CLANG_CXX_LANGUAGE_STANDARD = "gnu++14"; + CLANG_CXX_LIBRARY = "libc++"; + CLANG_ENABLE_MODULES = YES; + CLANG_ENABLE_OBJC_ARC = YES; + CLANG_WARN_BLOCK_CAPTURE_AUTORELEASING = YES; + CLANG_WARN_BOOL_CONVERSION = YES; + CLANG_WARN_COMMA = YES; + CLANG_WARN_CONSTANT_CONVERSION = YES; + CLANG_WARN_DIRECT_OBJC_ISA_USAGE = YES_ERROR; + CLANG_WARN_DOCUMENTATION_COMMENTS = YES; + CLANG_WARN_EMPTY_BODY = YES; + CLANG_WARN_ENUM_CONVERSION = YES; + CLANG_WARN_INFINITE_RECURSION = YES; + CLANG_WARN_INT_CONVERSION = YES; + CLANG_WARN_NON_LITERAL_NULL_CONVERSION = YES; + CLANG_WARN_OBJC_LITERAL_CONVERSION = YES; + CLANG_WARN_OBJC_ROOT_CLASS = YES_ERROR; + CLANG_WARN_RANGE_LOOP_ANALYSIS = YES; + CLANG_WARN_STRICT_PROTOTYPES = YES; + CLANG_WARN_SUSPICIOUS_MOVE = YES; + CLANG_WARN_UNGUARDED_AVAILABILITY = YES_AGGRESSIVE; + CLANG_WARN_UNREACHABLE_CODE = YES; + CLANG_WARN__DUPLICATE_METHOD_MATCH = YES; + CODE_SIGN_IDENTITY = "iPhone Developer"; + COPY_PHASE_STRIP = NO; + DEBUG_INFORMATION_FORMAT = "dwarf-with-dsym"; + ENABLE_NS_ASSERTIONS = NO; + ENABLE_STRICT_OBJC_MSGSEND = YES; + GCC_C_LANGUAGE_STANDARD = gnu11; + GCC_NO_COMMON_BLOCKS = YES; + GCC_WARN_64_TO_32_BIT_CONVERSION = YES; + GCC_WARN_ABOUT_RETURN_TYPE = YES_ERROR; + GCC_WARN_UNDECLARED_SELECTOR = YES; + GCC_WARN_UNINITIALIZED_AUTOS = YES_AGGRESSIVE; + GCC_WARN_UNUSED_FUNCTION = YES; + GCC_WARN_UNUSED_VARIABLE = YES; + IPHONEOS_DEPLOYMENT_TARGET = 11.0; + MTL_ENABLE_DEBUG_INFO = NO; + SDKROOT = iphoneos; + SWIFT_OPTIMIZATION_LEVEL = "-Owholemodule"; + VALIDATE_PRODUCT = YES; + }; + name = Release; + }; + AE9957801FA704B000397D38 /* Debug */ = { + isa = XCBuildConfiguration; + buildSettings = { + ASSETCATALOG_COMPILER_APPICON_NAME = AppIcon; + CODE_SIGN_STYLE = Automatic; + INFOPLIST_FILE = meetingRooms/Info.plist; + LD_RUNPATH_SEARCH_PATHS = "$(inherited) @executable_path/Frameworks"; + PRODUCT_BUNDLE_IDENTIFIER = "--------.meetingRooms"; + PRODUCT_NAME = "$(TARGET_NAME)"; + SWIFT_VERSION = 4.0; + TARGETED_DEVICE_FAMILY = "1,2"; + }; + name = Debug; + }; + AE9957811FA704B000397D38 /* Release */ = { + isa = XCBuildConfiguration; + buildSettings = { + ASSETCATALOG_COMPILER_APPICON_NAME = AppIcon; + CODE_SIGN_STYLE = Automatic; + INFOPLIST_FILE = meetingRooms/Info.plist; + LD_RUNPATH_SEARCH_PATHS = "$(inherited) @executable_path/Frameworks"; + PRODUCT_BUNDLE_IDENTIFIER = "--------.meetingRooms"; + PRODUCT_NAME = "$(TARGET_NAME)"; + SWIFT_VERSION = 4.0; + TARGETED_DEVICE_FAMILY = "1,2"; + }; + name = Release; + }; + AE9957831FA704B000397D38 /* Debug */ = { + isa = XCBuildConfiguration; + buildSettings = { + ALWAYS_EMBED_SWIFT_STANDARD_LIBRARIES = YES; + BUNDLE_LOADER = "$(TEST_HOST)"; + CODE_SIGN_STYLE = Automatic; + INFOPLIST_FILE = meetingRoomsTests/Info.plist; + LD_RUNPATH_SEARCH_PATHS = "$(inherited) @executable_path/Frameworks @loader_path/Frameworks"; + PRODUCT_BUNDLE_IDENTIFIER = "--------.meetingRoomsTests"; + PRODUCT_NAME = "$(TARGET_NAME)"; + SWIFT_VERSION = 4.0; + TARGETED_DEVICE_FAMILY = "1,2"; + TEST_HOST = "$(BUILT_PRODUCTS_DIR)/meetingRooms.app/meetingRooms"; + }; + name = Debug; + }; + AE9957841FA704B000397D38 /* Release */ = { + isa = XCBuildConfiguration; + buildSettings = { + ALWAYS_EMBED_SWIFT_STANDARD_LIBRARIES = YES; + BUNDLE_LOADER = "$(TEST_HOST)"; + CODE_SIGN_STYLE = Automatic; + INFOPLIST_FILE = meetingRoomsTests/Info.plist; + LD_RUNPATH_SEARCH_PATHS = "$(inherited) @executable_path/Frameworks @loader_path/Frameworks"; + PRODUCT_BUNDLE_IDENTIFIER = "--------.meetingRoomsTests"; + PRODUCT_NAME = "$(TARGET_NAME)"; + SWIFT_VERSION = 4.0; + TARGETED_DEVICE_FAMILY = "1,2"; + TEST_HOST = "$(BUILT_PRODUCTS_DIR)/meetingRooms.app/meetingRooms"; + }; + name = Release; + }; + AE9957861FA704B000397D38 /* Debug */ = { + isa = XCBuildConfiguration; + buildSettings = { + ALWAYS_EMBED_SWIFT_STANDARD_LIBRARIES = YES; + CODE_SIGN_STYLE = Automatic; + INFOPLIST_FILE = meetingRoomsUITests/Info.plist; + LD_RUNPATH_SEARCH_PATHS = "$(inherited) @executable_path/Frameworks @loader_path/Frameworks"; + PRODUCT_BUNDLE_IDENTIFIER = "--------.meetingRoomsUITests"; + PRODUCT_NAME = "$(TARGET_NAME)"; + SWIFT_VERSION = 4.0; + TARGETED_DEVICE_FAMILY = "1,2"; + TEST_TARGET_NAME = meetingRooms; + }; + name = Debug; + }; + AE9957871FA704B000397D38 /* Release */ = { + isa = XCBuildConfiguration; + buildSettings = { + ALWAYS_EMBED_SWIFT_STANDARD_LIBRARIES = YES; + CODE_SIGN_STYLE = Automatic; + INFOPLIST_FILE = meetingRoomsUITests/Info.plist; + LD_RUNPATH_SEARCH_PATHS = "$(inherited) @executable_path/Frameworks @loader_path/Frameworks"; + PRODUCT_BUNDLE_IDENTIFIER = "--------.meetingRoomsUITests"; + PRODUCT_NAME = "$(TARGET_NAME)"; + SWIFT_VERSION = 4.0; + TARGETED_DEVICE_FAMILY = "1,2"; + TEST_TARGET_NAME = meetingRooms; + }; + name = Release; + }; +/* End XCBuildConfiguration section */ + +/* Begin XCConfigurationList section */ + AE9957521FA704AF00397D38 /* Build configuration list for PBXProject "meetingRooms" */ = { + isa = XCConfigurationList; + buildConfigurations = ( + AE99577D1FA704B000397D38 /* Debug */, + AE99577E1FA704B000397D38 /* Release */, + ); + defaultConfigurationIsVisible = 0; + defaultConfigurationName = Release; + }; + AE99577F1FA704B000397D38 /* Build configuration list for PBXNativeTarget "meetingRooms" */ = { + isa = XCConfigurationList; + buildConfigurations = ( + AE9957801FA704B000397D38 /* Debug */, + AE9957811FA704B000397D38 /* Release */, + ); + defaultConfigurationIsVisible = 0; + defaultConfigurationName = Release; + }; + AE9957821FA704B000397D38 /* Build configuration list for PBXNativeTarget "meetingRoomsTests" */ = { + isa = XCConfigurationList; + buildConfigurations = ( + AE9957831FA704B000397D38 /* Debug */, + AE9957841FA704B000397D38 /* Release */, + ); + defaultConfigurationIsVisible = 0; + defaultConfigurationName = Release; + }; + AE9957851FA704B000397D38 /* Build configuration list for PBXNativeTarget "meetingRoomsUITests" */ = { + isa = XCConfigurationList; + buildConfigurations = ( + AE9957861FA704B000397D38 /* Debug */, + AE9957871FA704B000397D38 /* Release */, + ); + defaultConfigurationIsVisible = 0; + defaultConfigurationName = Release; + }; +/* End XCConfigurationList section */ + }; + rootObject = AE99574F1FA704AF00397D38 /* Project object */; +} diff --git "a/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/meetingRooms_3/meetingRooms.xcodeproj/project.xcworkspace/contents.xcworkspacedata" "b/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/meetingRooms_3/meetingRooms.xcodeproj/project.xcworkspace/contents.xcworkspacedata" new file mode 100644 index 0000000..8491799 --- /dev/null +++ "b/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/meetingRooms_3/meetingRooms.xcodeproj/project.xcworkspace/contents.xcworkspacedata" @@ -0,0 +1,7 @@ + + + + + diff --git "a/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/meetingRooms_3/meetingRooms/AppDelegate.swift" "b/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/meetingRooms_3/meetingRooms/AppDelegate.swift" new file mode 100644 index 0000000..fc60321 --- /dev/null +++ "b/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/meetingRooms_3/meetingRooms/AppDelegate.swift" @@ -0,0 +1,46 @@ +// +// AppDelegate.swift +// meetingRooms +// +// Created by 황도증 on 2017. 10. 30.. +// Copyright © 2017년 황도증. All rights reserved. +// + +import UIKit + +@UIApplicationMain +class AppDelegate: UIResponder, UIApplicationDelegate { + + var window: UIWindow? + + + func application(_ application: UIApplication, didFinishLaunchingWithOptions launchOptions: [UIApplicationLaunchOptionsKey: Any]?) -> Bool { + // Override point for customization after application launch. + return true + } + + func applicationWillResignActive(_ application: UIApplication) { + // Sent when the application is about to move from active to inactive state. This can occur for certain types of temporary interruptions (such as an incoming phone call or SMS message) or when the user quits the application and it begins the transition to the background state. + // Use this method to pause ongoing tasks, disable timers, and invalidate graphics rendering callbacks. Games should use this method to pause the game. + } + + func applicationDidEnterBackground(_ application: UIApplication) { + // Use this method to release shared resources, save user data, invalidate timers, and store enough application state information to restore your application to its current state in case it is terminated later. + // If your application supports background execution, this method is called instead of applicationWillTerminate: when the user quits. + } + + func applicationWillEnterForeground(_ application: UIApplication) { + // Called as part of the transition from the background to the active state; here you can undo many of the changes made on entering the background. + } + + func applicationDidBecomeActive(_ application: UIApplication) { + // Restart any tasks that were paused (or not yet started) while the application was inactive. If the application was previously in the background, optionally refresh the user interface. + } + + func applicationWillTerminate(_ application: UIApplication) { + // Called when the application is about to terminate. Save data if appropriate. See also applicationDidEnterBackground:. + } + + +} + diff --git "a/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/meetingRooms_3/meetingRooms/Assets.xcassets/AppIcon.appiconset/Contents.json" "b/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/meetingRooms_3/meetingRooms/Assets.xcassets/AppIcon.appiconset/Contents.json" new file mode 100644 index 0000000..d8db8d6 --- /dev/null +++ "b/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/meetingRooms_3/meetingRooms/Assets.xcassets/AppIcon.appiconset/Contents.json" @@ -0,0 +1,98 @@ +{ + "images" : [ + { + "idiom" : "iphone", + "size" : "20x20", + "scale" : "2x" + }, + { + "idiom" : "iphone", + "size" : "20x20", + "scale" : "3x" + }, + { + "idiom" : "iphone", + "size" : "29x29", + "scale" : "2x" + }, + { + "idiom" : "iphone", + "size" : "29x29", + "scale" : "3x" + }, + { + "idiom" : "iphone", + "size" : "40x40", + "scale" : "2x" + }, + { + "idiom" : "iphone", + "size" : "40x40", + "scale" : "3x" + }, + { + "idiom" : "iphone", + "size" : "60x60", + "scale" : "2x" + }, + { + "idiom" : "iphone", + "size" : "60x60", + "scale" : "3x" + }, + { + "idiom" : "ipad", + "size" : "20x20", + "scale" : "1x" + }, + { + "idiom" : "ipad", + "size" : "20x20", + "scale" : "2x" + }, + { + "idiom" : "ipad", + "size" : "29x29", + "scale" : "1x" + }, + { + "idiom" : "ipad", + "size" : "29x29", + "scale" : "2x" + }, + { + "idiom" : "ipad", + "size" : "40x40", + "scale" : "1x" + }, + { + "idiom" : "ipad", + "size" : "40x40", + "scale" : "2x" + }, + { + "idiom" : "ipad", + "size" : "76x76", + "scale" : "1x" + }, + { + "idiom" : "ipad", + "size" : "76x76", + "scale" : "2x" + }, + { + "idiom" : "ipad", + "size" : "83.5x83.5", + "scale" : "2x" + }, + { + "idiom" : "ios-marketing", + "size" : "1024x1024", + "scale" : "1x" + } + ], + "info" : { + "version" : 1, + "author" : "xcode" + } +} \ No newline at end of file diff --git "a/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/meetingRooms_3/meetingRooms/Base.lproj/LaunchScreen.storyboard" "b/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/meetingRooms_3/meetingRooms/Base.lproj/LaunchScreen.storyboard" new file mode 100644 index 0000000..f83f6fd --- /dev/null +++ "b/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/meetingRooms_3/meetingRooms/Base.lproj/LaunchScreen.storyboard" @@ -0,0 +1,25 @@ + + + + + + + + + + + + + + + + + + + + + + + + + diff --git "a/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/meetingRooms_3/meetingRooms/Base.lproj/Main.storyboard" "b/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/meetingRooms_3/meetingRooms/Base.lproj/Main.storyboard" new file mode 100644 index 0000000..ff29a4c --- /dev/null +++ "b/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/meetingRooms_3/meetingRooms/Base.lproj/Main.storyboard" @@ -0,0 +1,56 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + diff --git "a/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/meetingRooms_3/meetingRooms/Info.plist" "b/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/meetingRooms_3/meetingRooms/Info.plist" new file mode 100644 index 0000000..16be3b6 --- /dev/null +++ "b/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/meetingRooms_3/meetingRooms/Info.plist" @@ -0,0 +1,45 @@ + + + + + CFBundleDevelopmentRegion + $(DEVELOPMENT_LANGUAGE) + CFBundleExecutable + $(EXECUTABLE_NAME) + CFBundleIdentifier + $(PRODUCT_BUNDLE_IDENTIFIER) + CFBundleInfoDictionaryVersion + 6.0 + CFBundleName + $(PRODUCT_NAME) + CFBundlePackageType + APPL + CFBundleShortVersionString + 1.0 + CFBundleVersion + 1 + LSRequiresIPhoneOS + + UILaunchStoryboardName + LaunchScreen + UIMainStoryboardFile + Main + UIRequiredDeviceCapabilities + + armv7 + + UISupportedInterfaceOrientations + + UIInterfaceOrientationPortrait + UIInterfaceOrientationLandscapeLeft + UIInterfaceOrientationLandscapeRight + + UISupportedInterfaceOrientations~ipad + + UIInterfaceOrientationPortrait + UIInterfaceOrientationPortraitUpsideDown + UIInterfaceOrientationLandscapeLeft + UIInterfaceOrientationLandscapeRight + + + diff --git "a/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/meetingRooms_3/meetingRooms/MeetingRoomListViewController.swift" "b/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/meetingRooms_3/meetingRooms/MeetingRoomListViewController.swift" new file mode 100644 index 0000000..9bf0ea4 --- /dev/null +++ "b/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/meetingRooms_3/meetingRooms/MeetingRoomListViewController.swift" @@ -0,0 +1,112 @@ +// +// MeetingRoomListViewController.swift +// meetingRooms +// +// Created by 황도증 on 2017. 10. 30.. +// Copyright © 2017년 황도증. All rights reserved. +// + +import UIKit + +class MeetingRoomListViewController: UITableViewController { + + var meetingRooms:[String:[String:Int]] = ["Meeting":["Banksy":4, "Rivera":8, "Kahlo":10], "Seminar":["Cezanne":20, "Matisse":30, "Renoir":40]] + + override func viewDidLoad() { + super.viewDidLoad() + + // Uncomment the following line to preserve selection between presentations + // self.clearsSelectionOnViewWillAppear = false + + // Uncomment the following line to display an Edit button in the navigation bar for this view controller. + // self.navigationItem.rightBarButtonItem = self.editButtonItem + } + + override func didReceiveMemoryWarning() { + super.didReceiveMemoryWarning() + // Dispose of any resources that can be recreated. + } + + // MARK: - Table view data source + + override func numberOfSections(in tableView: UITableView) -> Int { + // #warning Incomplete implementation, return the number of sections + return meetingRooms.count + } + + override func tableView(_ tableView: UITableView, numberOfRowsInSection section: Int) -> Int { + // #warning Incomplete implementation, return the number of rows + let categoryValues = Array(meetingRooms.values)[section] + return categoryValues.count + } + + + override func tableView(_ tableView: UITableView, cellForRowAt indexPath: IndexPath) -> UITableViewCell { + let cell = tableView.dequeueReusableCell(withIdentifier: "MyCell", for: indexPath) + + // Configure the cell... + let categoryValue = Array(meetingRooms.values)[indexPath.section] + + let roomName = Array(categoryValue.keys)[indexPath.row] + let capacity = Array(categoryValue.values)[indexPath.row] + + cell.textLabel!.text = roomName + cell.detailTextLabel!.text = "\(capacity)" + return cell + } + + override func tableView(_ tableView: UITableView, titleForHeaderInSection section: Int) -> String? { + return Array(meetingRooms.keys)[section] + } + + override func tableView(_ tableView: UITableView, titleForFooterInSection section: Int) -> String? { + let rowCount = Array(meetingRooms.values)[section].count + return "\(rowCount) rooms" + } + + /* + // Override to support conditional editing of the table view. + override func tableView(_ tableView: UITableView, canEditRowAt indexPath: IndexPath) -> Bool { + // Return false if you do not want the specified item to be editable. + return true + } + */ + + /* + // Override to support editing the table view. + override func tableView(_ tableView: UITableView, commit editingStyle: UITableViewCellEditingStyle, forRowAt indexPath: IndexPath) { + if editingStyle == .delete { + // Delete the row from the data source + tableView.deleteRows(at: [indexPath], with: .fade) + } else if editingStyle == .insert { + // Create a new instance of the appropriate class, insert it into the array, and add a new row to the table view + } + } + */ + + /* + // Override to support rearranging the table view. + override func tableView(_ tableView: UITableView, moveRowAt fromIndexPath: IndexPath, to: IndexPath) { + + } + */ + + /* + // Override to support conditional rearranging of the table view. + override func tableView(_ tableView: UITableView, canMoveRowAt indexPath: IndexPath) -> Bool { + // Return false if you do not want the item to be re-orderable. + return true + } + */ + + /* + // MARK: - Navigation + + // In a storyboard-based application, you will often want to do a little preparation before navigation + override func prepare(for segue: UIStoryboardSegue, sender: Any?) { + // Get the new view controller using segue.destinationViewController. + // Pass the selected object to the new view controller. + } + */ + +} diff --git "a/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/meetingRooms_3/meetingRooms/ViewController.swift" "b/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/meetingRooms_3/meetingRooms/ViewController.swift" new file mode 100644 index 0000000..24bd9b0 --- /dev/null +++ "b/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/meetingRooms_3/meetingRooms/ViewController.swift" @@ -0,0 +1,25 @@ +// +// ViewController.swift +// meetingRooms +// +// Created by 황도증 on 2017. 10. 30.. +// Copyright © 2017년 황도증. All rights reserved. +// + +import UIKit + +class ViewController: UIViewController { + + override func viewDidLoad() { + super.viewDidLoad() + // Do any additional setup after loading the view, typically from a nib. + } + + override func didReceiveMemoryWarning() { + super.didReceiveMemoryWarning() + // Dispose of any resources that can be recreated. + } + + +} + diff --git "a/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/meetingRooms_3/meetingRoomsTests/Info.plist" "b/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/meetingRooms_3/meetingRoomsTests/Info.plist" new file mode 100644 index 0000000..6c40a6c --- /dev/null +++ "b/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/meetingRooms_3/meetingRoomsTests/Info.plist" @@ -0,0 +1,22 @@ + + + + + CFBundleDevelopmentRegion + $(DEVELOPMENT_LANGUAGE) + CFBundleExecutable + $(EXECUTABLE_NAME) + CFBundleIdentifier + $(PRODUCT_BUNDLE_IDENTIFIER) + CFBundleInfoDictionaryVersion + 6.0 + CFBundleName + $(PRODUCT_NAME) + CFBundlePackageType + BNDL + CFBundleShortVersionString + 1.0 + CFBundleVersion + 1 + + diff --git "a/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/meetingRooms_3/meetingRoomsTests/meetingRoomsTests.swift" "b/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/meetingRooms_3/meetingRoomsTests/meetingRoomsTests.swift" new file mode 100644 index 0000000..bfbd8d6 --- /dev/null +++ "b/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/meetingRooms_3/meetingRoomsTests/meetingRoomsTests.swift" @@ -0,0 +1,36 @@ +// +// meetingRoomsTests.swift +// meetingRoomsTests +// +// Created by 황도증 on 2017. 10. 30.. +// Copyright © 2017년 황도증. All rights reserved. +// + +import XCTest +@testable import meetingRooms + +class meetingRoomsTests: XCTestCase { + + override func setUp() { + super.setUp() + // Put setup code here. This method is called before the invocation of each test method in the class. + } + + override func tearDown() { + // Put teardown code here. This method is called after the invocation of each test method in the class. + super.tearDown() + } + + func testExample() { + // This is an example of a functional test case. + // Use XCTAssert and related functions to verify your tests produce the correct results. + } + + func testPerformanceExample() { + // This is an example of a performance test case. + self.measure { + // Put the code you want to measure the time of here. + } + } + +} diff --git "a/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/meetingRooms_3/meetingRoomsUITests/Info.plist" "b/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/meetingRooms_3/meetingRoomsUITests/Info.plist" new file mode 100644 index 0000000..6c40a6c --- /dev/null +++ "b/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/meetingRooms_3/meetingRoomsUITests/Info.plist" @@ -0,0 +1,22 @@ + + + + + CFBundleDevelopmentRegion + $(DEVELOPMENT_LANGUAGE) + CFBundleExecutable + $(EXECUTABLE_NAME) + CFBundleIdentifier + $(PRODUCT_BUNDLE_IDENTIFIER) + CFBundleInfoDictionaryVersion + 6.0 + CFBundleName + $(PRODUCT_NAME) + CFBundlePackageType + BNDL + CFBundleShortVersionString + 1.0 + CFBundleVersion + 1 + + diff --git "a/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/meetingRooms_3/meetingRoomsUITests/meetingRoomsUITests.swift" "b/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/meetingRooms_3/meetingRoomsUITests/meetingRoomsUITests.swift" new file mode 100644 index 0000000..4873bfa --- /dev/null +++ "b/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/meetingRooms_3/meetingRoomsUITests/meetingRoomsUITests.swift" @@ -0,0 +1,36 @@ +// +// meetingRoomsUITests.swift +// meetingRoomsUITests +// +// Created by 황도증 on 2017. 10. 30.. +// Copyright © 2017년 황도증. All rights reserved. +// + +import XCTest + +class meetingRoomsUITests: XCTestCase { + + override func setUp() { + super.setUp() + + // Put setup code here. This method is called before the invocation of each test method in the class. + + // In UI tests it is usually best to stop immediately when a failure occurs. + continueAfterFailure = false + // UI tests must launch the application that they test. Doing this in setup will make sure it happens for each test method. + XCUIApplication().launch() + + // In UI tests it’s important to set the initial state - such as interface orientation - required for your tests before they run. The setUp method is a good place to do this. + } + + override func tearDown() { + // Put teardown code here. This method is called after the invocation of each test method in the class. + super.tearDown() + } + + func testExample() { + // Use recording to get started writing UI tests. + // Use XCTAssert and related functions to verify your tests produce the correct results. + } + +} diff --git "a/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/meetingRooms_4/meetingRooms.xcodeproj/project.pbxproj" "b/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/meetingRooms_4/meetingRooms.xcodeproj/project.pbxproj" new file mode 100644 index 0000000..c09b5be --- /dev/null +++ "b/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/meetingRooms_4/meetingRooms.xcodeproj/project.pbxproj" @@ -0,0 +1,561 @@ +// !$*UTF8*$! +{ + archiveVersion = 1; + classes = { + }; + objectVersion = 48; + objects = { + +/* Begin PBXBuildFile section */ + AE99575B1FA704AF00397D38 /* AppDelegate.swift in Sources */ = {isa = PBXBuildFile; fileRef = AE99575A1FA704AF00397D38 /* AppDelegate.swift */; }; + AE99575D1FA704AF00397D38 /* ViewController.swift in Sources */ = {isa = PBXBuildFile; fileRef = AE99575C1FA704AF00397D38 /* ViewController.swift */; }; + AE9957601FA704AF00397D38 /* Main.storyboard in Resources */ = {isa = PBXBuildFile; fileRef = AE99575E1FA704AF00397D38 /* Main.storyboard */; }; + AE9957621FA704AF00397D38 /* Assets.xcassets in Resources */ = {isa = PBXBuildFile; fileRef = AE9957611FA704AF00397D38 /* Assets.xcassets */; }; + AE9957651FA704AF00397D38 /* LaunchScreen.storyboard in Resources */ = {isa = PBXBuildFile; fileRef = AE9957631FA704AF00397D38 /* LaunchScreen.storyboard */; }; + AE9957701FA704AF00397D38 /* meetingRoomsTests.swift in Sources */ = {isa = PBXBuildFile; fileRef = AE99576F1FA704AF00397D38 /* meetingRoomsTests.swift */; }; + AE99577B1FA704B000397D38 /* meetingRoomsUITests.swift in Sources */ = {isa = PBXBuildFile; fileRef = AE99577A1FA704B000397D38 /* meetingRoomsUITests.swift */; }; + AE9957891FA7054800397D38 /* MeetingRoomListViewController.swift in Sources */ = {isa = PBXBuildFile; fileRef = AE9957881FA7054800397D38 /* MeetingRoomListViewController.swift */; }; +/* End PBXBuildFile section */ + +/* Begin PBXContainerItemProxy section */ + AE99576C1FA704AF00397D38 /* PBXContainerItemProxy */ = { + isa = PBXContainerItemProxy; + containerPortal = AE99574F1FA704AF00397D38 /* Project object */; + proxyType = 1; + remoteGlobalIDString = AE9957561FA704AF00397D38; + remoteInfo = meetingRooms; + }; + AE9957771FA704B000397D38 /* PBXContainerItemProxy */ = { + isa = PBXContainerItemProxy; + containerPortal = AE99574F1FA704AF00397D38 /* Project object */; + proxyType = 1; + remoteGlobalIDString = AE9957561FA704AF00397D38; + remoteInfo = meetingRooms; + }; +/* End PBXContainerItemProxy section */ + +/* Begin PBXFileReference section */ + AE9957571FA704AF00397D38 /* meetingRooms.app */ = {isa = PBXFileReference; explicitFileType = wrapper.application; includeInIndex = 0; path = meetingRooms.app; sourceTree = BUILT_PRODUCTS_DIR; }; + AE99575A1FA704AF00397D38 /* AppDelegate.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = AppDelegate.swift; sourceTree = ""; }; + AE99575C1FA704AF00397D38 /* ViewController.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = ViewController.swift; sourceTree = ""; }; + AE99575F1FA704AF00397D38 /* Base */ = {isa = PBXFileReference; lastKnownFileType = file.storyboard; name = Base; path = Base.lproj/Main.storyboard; sourceTree = ""; }; + AE9957611FA704AF00397D38 /* Assets.xcassets */ = {isa = PBXFileReference; lastKnownFileType = folder.assetcatalog; path = Assets.xcassets; sourceTree = ""; }; + AE9957641FA704AF00397D38 /* Base */ = {isa = PBXFileReference; lastKnownFileType = file.storyboard; name = Base; path = Base.lproj/LaunchScreen.storyboard; sourceTree = ""; }; + AE9957661FA704AF00397D38 /* Info.plist */ = {isa = PBXFileReference; lastKnownFileType = text.plist.xml; path = Info.plist; sourceTree = ""; }; + AE99576B1FA704AF00397D38 /* meetingRoomsTests.xctest */ = {isa = PBXFileReference; explicitFileType = wrapper.cfbundle; includeInIndex = 0; path = meetingRoomsTests.xctest; sourceTree = BUILT_PRODUCTS_DIR; }; + AE99576F1FA704AF00397D38 /* meetingRoomsTests.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = meetingRoomsTests.swift; sourceTree = ""; }; + AE9957711FA704AF00397D38 /* Info.plist */ = {isa = PBXFileReference; lastKnownFileType = text.plist.xml; path = Info.plist; sourceTree = ""; }; + AE9957761FA704B000397D38 /* meetingRoomsUITests.xctest */ = {isa = PBXFileReference; explicitFileType = wrapper.cfbundle; includeInIndex = 0; path = meetingRoomsUITests.xctest; sourceTree = BUILT_PRODUCTS_DIR; }; + AE99577A1FA704B000397D38 /* meetingRoomsUITests.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = meetingRoomsUITests.swift; sourceTree = ""; }; + AE99577C1FA704B000397D38 /* Info.plist */ = {isa = PBXFileReference; lastKnownFileType = text.plist.xml; path = Info.plist; sourceTree = ""; }; + AE9957881FA7054800397D38 /* MeetingRoomListViewController.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = MeetingRoomListViewController.swift; sourceTree = ""; }; +/* End PBXFileReference section */ + +/* Begin PBXFrameworksBuildPhase section */ + AE9957541FA704AF00397D38 /* Frameworks */ = { + isa = PBXFrameworksBuildPhase; + buildActionMask = 2147483647; + files = ( + ); + runOnlyForDeploymentPostprocessing = 0; + }; + AE9957681FA704AF00397D38 /* Frameworks */ = { + isa = PBXFrameworksBuildPhase; + buildActionMask = 2147483647; + files = ( + ); + runOnlyForDeploymentPostprocessing = 0; + }; + AE9957731FA704B000397D38 /* Frameworks */ = { + isa = PBXFrameworksBuildPhase; + buildActionMask = 2147483647; + files = ( + ); + runOnlyForDeploymentPostprocessing = 0; + }; +/* End PBXFrameworksBuildPhase section */ + +/* Begin PBXGroup section */ + AE99574E1FA704AF00397D38 = { + isa = PBXGroup; + children = ( + AE9957591FA704AF00397D38 /* meetingRooms */, + AE99576E1FA704AF00397D38 /* meetingRoomsTests */, + AE9957791FA704B000397D38 /* meetingRoomsUITests */, + AE9957581FA704AF00397D38 /* Products */, + ); + sourceTree = ""; + }; + AE9957581FA704AF00397D38 /* Products */ = { + isa = PBXGroup; + children = ( + AE9957571FA704AF00397D38 /* meetingRooms.app */, + AE99576B1FA704AF00397D38 /* meetingRoomsTests.xctest */, + AE9957761FA704B000397D38 /* meetingRoomsUITests.xctest */, + ); + name = Products; + sourceTree = ""; + }; + AE9957591FA704AF00397D38 /* meetingRooms */ = { + isa = PBXGroup; + children = ( + AE99575A1FA704AF00397D38 /* AppDelegate.swift */, + AE99575C1FA704AF00397D38 /* ViewController.swift */, + AE99575E1FA704AF00397D38 /* Main.storyboard */, + AE9957881FA7054800397D38 /* MeetingRoomListViewController.swift */, + AE9957611FA704AF00397D38 /* Assets.xcassets */, + AE9957631FA704AF00397D38 /* LaunchScreen.storyboard */, + AE9957661FA704AF00397D38 /* Info.plist */, + ); + path = meetingRooms; + sourceTree = ""; + }; + AE99576E1FA704AF00397D38 /* meetingRoomsTests */ = { + isa = PBXGroup; + children = ( + AE99576F1FA704AF00397D38 /* meetingRoomsTests.swift */, + AE9957711FA704AF00397D38 /* Info.plist */, + ); + path = meetingRoomsTests; + sourceTree = ""; + }; + AE9957791FA704B000397D38 /* meetingRoomsUITests */ = { + isa = PBXGroup; + children = ( + AE99577A1FA704B000397D38 /* meetingRoomsUITests.swift */, + AE99577C1FA704B000397D38 /* Info.plist */, + ); + path = meetingRoomsUITests; + sourceTree = ""; + }; +/* End PBXGroup section */ + +/* Begin PBXNativeTarget section */ + AE9957561FA704AF00397D38 /* meetingRooms */ = { + isa = PBXNativeTarget; + buildConfigurationList = AE99577F1FA704B000397D38 /* Build configuration list for PBXNativeTarget "meetingRooms" */; + buildPhases = ( + AE9957531FA704AF00397D38 /* Sources */, + AE9957541FA704AF00397D38 /* Frameworks */, + AE9957551FA704AF00397D38 /* Resources */, + ); + buildRules = ( + ); + dependencies = ( + ); + name = meetingRooms; + productName = meetingRooms; + productReference = AE9957571FA704AF00397D38 /* meetingRooms.app */; + productType = "com.apple.product-type.application"; + }; + AE99576A1FA704AF00397D38 /* meetingRoomsTests */ = { + isa = PBXNativeTarget; + buildConfigurationList = AE9957821FA704B000397D38 /* Build configuration list for PBXNativeTarget "meetingRoomsTests" */; + buildPhases = ( + AE9957671FA704AF00397D38 /* Sources */, + AE9957681FA704AF00397D38 /* Frameworks */, + AE9957691FA704AF00397D38 /* Resources */, + ); + buildRules = ( + ); + dependencies = ( + AE99576D1FA704AF00397D38 /* PBXTargetDependency */, + ); + name = meetingRoomsTests; + productName = meetingRoomsTests; + productReference = AE99576B1FA704AF00397D38 /* meetingRoomsTests.xctest */; + productType = "com.apple.product-type.bundle.unit-test"; + }; + AE9957751FA704B000397D38 /* meetingRoomsUITests */ = { + isa = PBXNativeTarget; + buildConfigurationList = AE9957851FA704B000397D38 /* Build configuration list for PBXNativeTarget "meetingRoomsUITests" */; + buildPhases = ( + AE9957721FA704B000397D38 /* Sources */, + AE9957731FA704B000397D38 /* Frameworks */, + AE9957741FA704B000397D38 /* Resources */, + ); + buildRules = ( + ); + dependencies = ( + AE9957781FA704B000397D38 /* PBXTargetDependency */, + ); + name = meetingRoomsUITests; + productName = meetingRoomsUITests; + productReference = AE9957761FA704B000397D38 /* meetingRoomsUITests.xctest */; + productType = "com.apple.product-type.bundle.ui-testing"; + }; +/* End PBXNativeTarget section */ + +/* Begin PBXProject section */ + AE99574F1FA704AF00397D38 /* Project object */ = { + isa = PBXProject; + attributes = { + LastSwiftUpdateCheck = 0900; + LastUpgradeCheck = 0900; + ORGANIZATIONNAME = "황도증"; + TargetAttributes = { + AE9957561FA704AF00397D38 = { + CreatedOnToolsVersion = 9.0.1; + ProvisioningStyle = Automatic; + }; + AE99576A1FA704AF00397D38 = { + CreatedOnToolsVersion = 9.0.1; + ProvisioningStyle = Automatic; + TestTargetID = AE9957561FA704AF00397D38; + }; + AE9957751FA704B000397D38 = { + CreatedOnToolsVersion = 9.0.1; + ProvisioningStyle = Automatic; + TestTargetID = AE9957561FA704AF00397D38; + }; + }; + }; + buildConfigurationList = AE9957521FA704AF00397D38 /* Build configuration list for PBXProject "meetingRooms" */; + compatibilityVersion = "Xcode 8.0"; + developmentRegion = en; + hasScannedForEncodings = 0; + knownRegions = ( + en, + Base, + ); + mainGroup = AE99574E1FA704AF00397D38; + productRefGroup = AE9957581FA704AF00397D38 /* Products */; + projectDirPath = ""; + projectRoot = ""; + targets = ( + AE9957561FA704AF00397D38 /* meetingRooms */, + AE99576A1FA704AF00397D38 /* meetingRoomsTests */, + AE9957751FA704B000397D38 /* meetingRoomsUITests */, + ); + }; +/* End PBXProject section */ + +/* Begin PBXResourcesBuildPhase section */ + AE9957551FA704AF00397D38 /* Resources */ = { + isa = PBXResourcesBuildPhase; + buildActionMask = 2147483647; + files = ( + AE9957651FA704AF00397D38 /* LaunchScreen.storyboard in Resources */, + AE9957621FA704AF00397D38 /* Assets.xcassets in Resources */, + AE9957601FA704AF00397D38 /* Main.storyboard in Resources */, + ); + runOnlyForDeploymentPostprocessing = 0; + }; + AE9957691FA704AF00397D38 /* Resources */ = { + isa = PBXResourcesBuildPhase; + buildActionMask = 2147483647; + files = ( + ); + runOnlyForDeploymentPostprocessing = 0; + }; + AE9957741FA704B000397D38 /* Resources */ = { + isa = PBXResourcesBuildPhase; + buildActionMask = 2147483647; + files = ( + ); + runOnlyForDeploymentPostprocessing = 0; + }; +/* End PBXResourcesBuildPhase section */ + +/* Begin PBXSourcesBuildPhase section */ + AE9957531FA704AF00397D38 /* Sources */ = { + isa = PBXSourcesBuildPhase; + buildActionMask = 2147483647; + files = ( + AE99575D1FA704AF00397D38 /* ViewController.swift in Sources */, + AE99575B1FA704AF00397D38 /* AppDelegate.swift in Sources */, + AE9957891FA7054800397D38 /* MeetingRoomListViewController.swift in Sources */, + ); + runOnlyForDeploymentPostprocessing = 0; + }; + AE9957671FA704AF00397D38 /* Sources */ = { + isa = PBXSourcesBuildPhase; + buildActionMask = 2147483647; + files = ( + AE9957701FA704AF00397D38 /* meetingRoomsTests.swift in Sources */, + ); + runOnlyForDeploymentPostprocessing = 0; + }; + AE9957721FA704B000397D38 /* Sources */ = { + isa = PBXSourcesBuildPhase; + buildActionMask = 2147483647; + files = ( + AE99577B1FA704B000397D38 /* meetingRoomsUITests.swift in Sources */, + ); + runOnlyForDeploymentPostprocessing = 0; + }; +/* End PBXSourcesBuildPhase section */ + +/* Begin PBXTargetDependency section */ + AE99576D1FA704AF00397D38 /* PBXTargetDependency */ = { + isa = PBXTargetDependency; + target = AE9957561FA704AF00397D38 /* meetingRooms */; + targetProxy = AE99576C1FA704AF00397D38 /* PBXContainerItemProxy */; + }; + AE9957781FA704B000397D38 /* PBXTargetDependency */ = { + isa = PBXTargetDependency; + target = AE9957561FA704AF00397D38 /* meetingRooms */; + targetProxy = AE9957771FA704B000397D38 /* PBXContainerItemProxy */; + }; +/* End PBXTargetDependency section */ + +/* Begin PBXVariantGroup section */ + AE99575E1FA704AF00397D38 /* Main.storyboard */ = { + isa = PBXVariantGroup; + children = ( + AE99575F1FA704AF00397D38 /* Base */, + ); + name = Main.storyboard; + sourceTree = ""; + }; + AE9957631FA704AF00397D38 /* LaunchScreen.storyboard */ = { + isa = PBXVariantGroup; + children = ( + AE9957641FA704AF00397D38 /* Base */, + ); + name = LaunchScreen.storyboard; + sourceTree = ""; + }; +/* End PBXVariantGroup section */ + +/* Begin XCBuildConfiguration section */ + AE99577D1FA704B000397D38 /* Debug */ = { + isa = XCBuildConfiguration; + buildSettings = { + ALWAYS_SEARCH_USER_PATHS = NO; + CLANG_ANALYZER_NONNULL = YES; + CLANG_ANALYZER_NUMBER_OBJECT_CONVERSION = YES_AGGRESSIVE; + CLANG_CXX_LANGUAGE_STANDARD = "gnu++14"; + CLANG_CXX_LIBRARY = "libc++"; + CLANG_ENABLE_MODULES = YES; + CLANG_ENABLE_OBJC_ARC = YES; + CLANG_WARN_BLOCK_CAPTURE_AUTORELEASING = YES; + CLANG_WARN_BOOL_CONVERSION = YES; + CLANG_WARN_COMMA = YES; + CLANG_WARN_CONSTANT_CONVERSION = YES; + CLANG_WARN_DIRECT_OBJC_ISA_USAGE = YES_ERROR; + CLANG_WARN_DOCUMENTATION_COMMENTS = YES; + CLANG_WARN_EMPTY_BODY = YES; + CLANG_WARN_ENUM_CONVERSION = YES; + CLANG_WARN_INFINITE_RECURSION = YES; + CLANG_WARN_INT_CONVERSION = YES; + CLANG_WARN_NON_LITERAL_NULL_CONVERSION = YES; + CLANG_WARN_OBJC_LITERAL_CONVERSION = YES; + CLANG_WARN_OBJC_ROOT_CLASS = YES_ERROR; + CLANG_WARN_RANGE_LOOP_ANALYSIS = YES; + CLANG_WARN_STRICT_PROTOTYPES = YES; + CLANG_WARN_SUSPICIOUS_MOVE = YES; + CLANG_WARN_UNGUARDED_AVAILABILITY = YES_AGGRESSIVE; + CLANG_WARN_UNREACHABLE_CODE = YES; + CLANG_WARN__DUPLICATE_METHOD_MATCH = YES; + CODE_SIGN_IDENTITY = "iPhone Developer"; + COPY_PHASE_STRIP = NO; + DEBUG_INFORMATION_FORMAT = dwarf; + ENABLE_STRICT_OBJC_MSGSEND = YES; + ENABLE_TESTABILITY = YES; + GCC_C_LANGUAGE_STANDARD = gnu11; + GCC_DYNAMIC_NO_PIC = NO; + GCC_NO_COMMON_BLOCKS = YES; + GCC_OPTIMIZATION_LEVEL = 0; + GCC_PREPROCESSOR_DEFINITIONS = ( + "DEBUG=1", + "$(inherited)", + ); + GCC_WARN_64_TO_32_BIT_CONVERSION = YES; + GCC_WARN_ABOUT_RETURN_TYPE = YES_ERROR; + GCC_WARN_UNDECLARED_SELECTOR = YES; + GCC_WARN_UNINITIALIZED_AUTOS = YES_AGGRESSIVE; + GCC_WARN_UNUSED_FUNCTION = YES; + GCC_WARN_UNUSED_VARIABLE = YES; + IPHONEOS_DEPLOYMENT_TARGET = 11.0; + MTL_ENABLE_DEBUG_INFO = YES; + ONLY_ACTIVE_ARCH = YES; + SDKROOT = iphoneos; + SWIFT_ACTIVE_COMPILATION_CONDITIONS = DEBUG; + SWIFT_OPTIMIZATION_LEVEL = "-Onone"; + }; + name = Debug; + }; + AE99577E1FA704B000397D38 /* Release */ = { + isa = XCBuildConfiguration; + buildSettings = { + ALWAYS_SEARCH_USER_PATHS = NO; + CLANG_ANALYZER_NONNULL = YES; + CLANG_ANALYZER_NUMBER_OBJECT_CONVERSION = YES_AGGRESSIVE; + CLANG_CXX_LANGUAGE_STANDARD = "gnu++14"; + CLANG_CXX_LIBRARY = "libc++"; + CLANG_ENABLE_MODULES = YES; + CLANG_ENABLE_OBJC_ARC = YES; + CLANG_WARN_BLOCK_CAPTURE_AUTORELEASING = YES; + CLANG_WARN_BOOL_CONVERSION = YES; + CLANG_WARN_COMMA = YES; + CLANG_WARN_CONSTANT_CONVERSION = YES; + CLANG_WARN_DIRECT_OBJC_ISA_USAGE = YES_ERROR; + CLANG_WARN_DOCUMENTATION_COMMENTS = YES; + CLANG_WARN_EMPTY_BODY = YES; + CLANG_WARN_ENUM_CONVERSION = YES; + CLANG_WARN_INFINITE_RECURSION = YES; + CLANG_WARN_INT_CONVERSION = YES; + CLANG_WARN_NON_LITERAL_NULL_CONVERSION = YES; + CLANG_WARN_OBJC_LITERAL_CONVERSION = YES; + CLANG_WARN_OBJC_ROOT_CLASS = YES_ERROR; + CLANG_WARN_RANGE_LOOP_ANALYSIS = YES; + CLANG_WARN_STRICT_PROTOTYPES = YES; + CLANG_WARN_SUSPICIOUS_MOVE = YES; + CLANG_WARN_UNGUARDED_AVAILABILITY = YES_AGGRESSIVE; + CLANG_WARN_UNREACHABLE_CODE = YES; + CLANG_WARN__DUPLICATE_METHOD_MATCH = YES; + CODE_SIGN_IDENTITY = "iPhone Developer"; + COPY_PHASE_STRIP = NO; + DEBUG_INFORMATION_FORMAT = "dwarf-with-dsym"; + ENABLE_NS_ASSERTIONS = NO; + ENABLE_STRICT_OBJC_MSGSEND = YES; + GCC_C_LANGUAGE_STANDARD = gnu11; + GCC_NO_COMMON_BLOCKS = YES; + GCC_WARN_64_TO_32_BIT_CONVERSION = YES; + GCC_WARN_ABOUT_RETURN_TYPE = YES_ERROR; + GCC_WARN_UNDECLARED_SELECTOR = YES; + GCC_WARN_UNINITIALIZED_AUTOS = YES_AGGRESSIVE; + GCC_WARN_UNUSED_FUNCTION = YES; + GCC_WARN_UNUSED_VARIABLE = YES; + IPHONEOS_DEPLOYMENT_TARGET = 11.0; + MTL_ENABLE_DEBUG_INFO = NO; + SDKROOT = iphoneos; + SWIFT_OPTIMIZATION_LEVEL = "-Owholemodule"; + VALIDATE_PRODUCT = YES; + }; + name = Release; + }; + AE9957801FA704B000397D38 /* Debug */ = { + isa = XCBuildConfiguration; + buildSettings = { + ASSETCATALOG_COMPILER_APPICON_NAME = AppIcon; + CODE_SIGN_STYLE = Automatic; + INFOPLIST_FILE = meetingRooms/Info.plist; + LD_RUNPATH_SEARCH_PATHS = "$(inherited) @executable_path/Frameworks"; + PRODUCT_BUNDLE_IDENTIFIER = "--------.meetingRooms"; + PRODUCT_NAME = "$(TARGET_NAME)"; + SWIFT_VERSION = 4.0; + TARGETED_DEVICE_FAMILY = "1,2"; + }; + name = Debug; + }; + AE9957811FA704B000397D38 /* Release */ = { + isa = XCBuildConfiguration; + buildSettings = { + ASSETCATALOG_COMPILER_APPICON_NAME = AppIcon; + CODE_SIGN_STYLE = Automatic; + INFOPLIST_FILE = meetingRooms/Info.plist; + LD_RUNPATH_SEARCH_PATHS = "$(inherited) @executable_path/Frameworks"; + PRODUCT_BUNDLE_IDENTIFIER = "--------.meetingRooms"; + PRODUCT_NAME = "$(TARGET_NAME)"; + SWIFT_VERSION = 4.0; + TARGETED_DEVICE_FAMILY = "1,2"; + }; + name = Release; + }; + AE9957831FA704B000397D38 /* Debug */ = { + isa = XCBuildConfiguration; + buildSettings = { + ALWAYS_EMBED_SWIFT_STANDARD_LIBRARIES = YES; + BUNDLE_LOADER = "$(TEST_HOST)"; + CODE_SIGN_STYLE = Automatic; + INFOPLIST_FILE = meetingRoomsTests/Info.plist; + LD_RUNPATH_SEARCH_PATHS = "$(inherited) @executable_path/Frameworks @loader_path/Frameworks"; + PRODUCT_BUNDLE_IDENTIFIER = "--------.meetingRoomsTests"; + PRODUCT_NAME = "$(TARGET_NAME)"; + SWIFT_VERSION = 4.0; + TARGETED_DEVICE_FAMILY = "1,2"; + TEST_HOST = "$(BUILT_PRODUCTS_DIR)/meetingRooms.app/meetingRooms"; + }; + name = Debug; + }; + AE9957841FA704B000397D38 /* Release */ = { + isa = XCBuildConfiguration; + buildSettings = { + ALWAYS_EMBED_SWIFT_STANDARD_LIBRARIES = YES; + BUNDLE_LOADER = "$(TEST_HOST)"; + CODE_SIGN_STYLE = Automatic; + INFOPLIST_FILE = meetingRoomsTests/Info.plist; + LD_RUNPATH_SEARCH_PATHS = "$(inherited) @executable_path/Frameworks @loader_path/Frameworks"; + PRODUCT_BUNDLE_IDENTIFIER = "--------.meetingRoomsTests"; + PRODUCT_NAME = "$(TARGET_NAME)"; + SWIFT_VERSION = 4.0; + TARGETED_DEVICE_FAMILY = "1,2"; + TEST_HOST = "$(BUILT_PRODUCTS_DIR)/meetingRooms.app/meetingRooms"; + }; + name = Release; + }; + AE9957861FA704B000397D38 /* Debug */ = { + isa = XCBuildConfiguration; + buildSettings = { + ALWAYS_EMBED_SWIFT_STANDARD_LIBRARIES = YES; + CODE_SIGN_STYLE = Automatic; + INFOPLIST_FILE = meetingRoomsUITests/Info.plist; + LD_RUNPATH_SEARCH_PATHS = "$(inherited) @executable_path/Frameworks @loader_path/Frameworks"; + PRODUCT_BUNDLE_IDENTIFIER = "--------.meetingRoomsUITests"; + PRODUCT_NAME = "$(TARGET_NAME)"; + SWIFT_VERSION = 4.0; + TARGETED_DEVICE_FAMILY = "1,2"; + TEST_TARGET_NAME = meetingRooms; + }; + name = Debug; + }; + AE9957871FA704B000397D38 /* Release */ = { + isa = XCBuildConfiguration; + buildSettings = { + ALWAYS_EMBED_SWIFT_STANDARD_LIBRARIES = YES; + CODE_SIGN_STYLE = Automatic; + INFOPLIST_FILE = meetingRoomsUITests/Info.plist; + LD_RUNPATH_SEARCH_PATHS = "$(inherited) @executable_path/Frameworks @loader_path/Frameworks"; + PRODUCT_BUNDLE_IDENTIFIER = "--------.meetingRoomsUITests"; + PRODUCT_NAME = "$(TARGET_NAME)"; + SWIFT_VERSION = 4.0; + TARGETED_DEVICE_FAMILY = "1,2"; + TEST_TARGET_NAME = meetingRooms; + }; + name = Release; + }; +/* End XCBuildConfiguration section */ + +/* Begin XCConfigurationList section */ + AE9957521FA704AF00397D38 /* Build configuration list for PBXProject "meetingRooms" */ = { + isa = XCConfigurationList; + buildConfigurations = ( + AE99577D1FA704B000397D38 /* Debug */, + AE99577E1FA704B000397D38 /* Release */, + ); + defaultConfigurationIsVisible = 0; + defaultConfigurationName = Release; + }; + AE99577F1FA704B000397D38 /* Build configuration list for PBXNativeTarget "meetingRooms" */ = { + isa = XCConfigurationList; + buildConfigurations = ( + AE9957801FA704B000397D38 /* Debug */, + AE9957811FA704B000397D38 /* Release */, + ); + defaultConfigurationIsVisible = 0; + defaultConfigurationName = Release; + }; + AE9957821FA704B000397D38 /* Build configuration list for PBXNativeTarget "meetingRoomsTests" */ = { + isa = XCConfigurationList; + buildConfigurations = ( + AE9957831FA704B000397D38 /* Debug */, + AE9957841FA704B000397D38 /* Release */, + ); + defaultConfigurationIsVisible = 0; + defaultConfigurationName = Release; + }; + AE9957851FA704B000397D38 /* Build configuration list for PBXNativeTarget "meetingRoomsUITests" */ = { + isa = XCConfigurationList; + buildConfigurations = ( + AE9957861FA704B000397D38 /* Debug */, + AE9957871FA704B000397D38 /* Release */, + ); + defaultConfigurationIsVisible = 0; + defaultConfigurationName = Release; + }; +/* End XCConfigurationList section */ + }; + rootObject = AE99574F1FA704AF00397D38 /* Project object */; +} diff --git "a/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/meetingRooms_4/meetingRooms.xcodeproj/project.xcworkspace/contents.xcworkspacedata" "b/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/meetingRooms_4/meetingRooms.xcodeproj/project.xcworkspace/contents.xcworkspacedata" new file mode 100644 index 0000000..8491799 --- /dev/null +++ "b/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/meetingRooms_4/meetingRooms.xcodeproj/project.xcworkspace/contents.xcworkspacedata" @@ -0,0 +1,7 @@ + + + + + diff --git "a/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/meetingRooms_4/meetingRooms/AppDelegate.swift" "b/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/meetingRooms_4/meetingRooms/AppDelegate.swift" new file mode 100644 index 0000000..fc60321 --- /dev/null +++ "b/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/meetingRooms_4/meetingRooms/AppDelegate.swift" @@ -0,0 +1,46 @@ +// +// AppDelegate.swift +// meetingRooms +// +// Created by 황도증 on 2017. 10. 30.. +// Copyright © 2017년 황도증. All rights reserved. +// + +import UIKit + +@UIApplicationMain +class AppDelegate: UIResponder, UIApplicationDelegate { + + var window: UIWindow? + + + func application(_ application: UIApplication, didFinishLaunchingWithOptions launchOptions: [UIApplicationLaunchOptionsKey: Any]?) -> Bool { + // Override point for customization after application launch. + return true + } + + func applicationWillResignActive(_ application: UIApplication) { + // Sent when the application is about to move from active to inactive state. This can occur for certain types of temporary interruptions (such as an incoming phone call or SMS message) or when the user quits the application and it begins the transition to the background state. + // Use this method to pause ongoing tasks, disable timers, and invalidate graphics rendering callbacks. Games should use this method to pause the game. + } + + func applicationDidEnterBackground(_ application: UIApplication) { + // Use this method to release shared resources, save user data, invalidate timers, and store enough application state information to restore your application to its current state in case it is terminated later. + // If your application supports background execution, this method is called instead of applicationWillTerminate: when the user quits. + } + + func applicationWillEnterForeground(_ application: UIApplication) { + // Called as part of the transition from the background to the active state; here you can undo many of the changes made on entering the background. + } + + func applicationDidBecomeActive(_ application: UIApplication) { + // Restart any tasks that were paused (or not yet started) while the application was inactive. If the application was previously in the background, optionally refresh the user interface. + } + + func applicationWillTerminate(_ application: UIApplication) { + // Called when the application is about to terminate. Save data if appropriate. See also applicationDidEnterBackground:. + } + + +} + diff --git "a/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/meetingRooms_4/meetingRooms/Assets.xcassets/AppIcon.appiconset/Contents.json" "b/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/meetingRooms_4/meetingRooms/Assets.xcassets/AppIcon.appiconset/Contents.json" new file mode 100644 index 0000000..d8db8d6 --- /dev/null +++ "b/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/meetingRooms_4/meetingRooms/Assets.xcassets/AppIcon.appiconset/Contents.json" @@ -0,0 +1,98 @@ +{ + "images" : [ + { + "idiom" : "iphone", + "size" : "20x20", + "scale" : "2x" + }, + { + "idiom" : "iphone", + "size" : "20x20", + "scale" : "3x" + }, + { + "idiom" : "iphone", + "size" : "29x29", + "scale" : "2x" + }, + { + "idiom" : "iphone", + "size" : "29x29", + "scale" : "3x" + }, + { + "idiom" : "iphone", + "size" : "40x40", + "scale" : "2x" + }, + { + "idiom" : "iphone", + "size" : "40x40", + "scale" : "3x" + }, + { + "idiom" : "iphone", + "size" : "60x60", + "scale" : "2x" + }, + { + "idiom" : "iphone", + "size" : "60x60", + "scale" : "3x" + }, + { + "idiom" : "ipad", + "size" : "20x20", + "scale" : "1x" + }, + { + "idiom" : "ipad", + "size" : "20x20", + "scale" : "2x" + }, + { + "idiom" : "ipad", + "size" : "29x29", + "scale" : "1x" + }, + { + "idiom" : "ipad", + "size" : "29x29", + "scale" : "2x" + }, + { + "idiom" : "ipad", + "size" : "40x40", + "scale" : "1x" + }, + { + "idiom" : "ipad", + "size" : "40x40", + "scale" : "2x" + }, + { + "idiom" : "ipad", + "size" : "76x76", + "scale" : "1x" + }, + { + "idiom" : "ipad", + "size" : "76x76", + "scale" : "2x" + }, + { + "idiom" : "ipad", + "size" : "83.5x83.5", + "scale" : "2x" + }, + { + "idiom" : "ios-marketing", + "size" : "1024x1024", + "scale" : "1x" + } + ], + "info" : { + "version" : 1, + "author" : "xcode" + } +} \ No newline at end of file diff --git "a/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/meetingRooms_4/meetingRooms/Base.lproj/LaunchScreen.storyboard" "b/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/meetingRooms_4/meetingRooms/Base.lproj/LaunchScreen.storyboard" new file mode 100644 index 0000000..f83f6fd --- /dev/null +++ "b/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/meetingRooms_4/meetingRooms/Base.lproj/LaunchScreen.storyboard" @@ -0,0 +1,25 @@ + + + + + + + + + + + + + + + + + + + + + + + + + diff --git "a/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/meetingRooms_4/meetingRooms/Base.lproj/Main.storyboard" "b/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/meetingRooms_4/meetingRooms/Base.lproj/Main.storyboard" new file mode 100644 index 0000000..ff29a4c --- /dev/null +++ "b/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/meetingRooms_4/meetingRooms/Base.lproj/Main.storyboard" @@ -0,0 +1,56 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + diff --git "a/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/meetingRooms_4/meetingRooms/Info.plist" "b/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/meetingRooms_4/meetingRooms/Info.plist" new file mode 100644 index 0000000..16be3b6 --- /dev/null +++ "b/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/meetingRooms_4/meetingRooms/Info.plist" @@ -0,0 +1,45 @@ + + + + + CFBundleDevelopmentRegion + $(DEVELOPMENT_LANGUAGE) + CFBundleExecutable + $(EXECUTABLE_NAME) + CFBundleIdentifier + $(PRODUCT_BUNDLE_IDENTIFIER) + CFBundleInfoDictionaryVersion + 6.0 + CFBundleName + $(PRODUCT_NAME) + CFBundlePackageType + APPL + CFBundleShortVersionString + 1.0 + CFBundleVersion + 1 + LSRequiresIPhoneOS + + UILaunchStoryboardName + LaunchScreen + UIMainStoryboardFile + Main + UIRequiredDeviceCapabilities + + armv7 + + UISupportedInterfaceOrientations + + UIInterfaceOrientationPortrait + UIInterfaceOrientationLandscapeLeft + UIInterfaceOrientationLandscapeRight + + UISupportedInterfaceOrientations~ipad + + UIInterfaceOrientationPortrait + UIInterfaceOrientationPortraitUpsideDown + UIInterfaceOrientationLandscapeLeft + UIInterfaceOrientationLandscapeRight + + + diff --git "a/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/meetingRooms_4/meetingRooms/MeetingRoomListViewController.swift" "b/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/meetingRooms_4/meetingRooms/MeetingRoomListViewController.swift" new file mode 100644 index 0000000..472ffce --- /dev/null +++ "b/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/meetingRooms_4/meetingRooms/MeetingRoomListViewController.swift" @@ -0,0 +1,125 @@ +// +// MeetingRoomListViewController.swift +// meetingRooms +// +// Created by 황도증 on 2017. 10. 30.. +// Copyright © 2017년 황도증. All rights reserved. +// + +import UIKit + +class MeetingRoomListViewController: UITableViewController { + + var meetingRooms:[String:[String:Int]] = ["Meeting":["Banksy":4, "Rivera":8, "Kahlo":10], "Seminar":["Cezanne":20, "Matisse":30, "Renoir":40]] + + func meetingRoomsAtIndex (index:Int) -> (key:String, value:[String:Int]) { + let orderMeetingRoooms = meetingRooms.sorted(by: {$0.1.first!.1 < $1.1.first!.1}) + return orderMeetingRoooms[index] + } + + override func viewDidLoad() { + super.viewDidLoad() + + // Uncomment the following line to preserve selection between presentations + // self.clearsSelectionOnViewWillAppear = false + + // Uncomment the following line to display an Edit button in the navigation bar for this view controller. + // self.navigationItem.rightBarButtonItem = self.editButtonItem + } + + override func didReceiveMemoryWarning() { + super.didReceiveMemoryWarning() + // Dispose of any resources that can be recreated. + } + + // MARK: - Table view data source + + override func numberOfSections(in tableView: UITableView) -> Int { + // #warning Incomplete implementation, return the number of sections + return meetingRooms.count + } + + override func tableView(_ tableView: UITableView, numberOfRowsInSection section: Int) -> Int { + // #warning Incomplete implementation, return the number of rows + //let categoryValues = Array(meetingRooms.values)[section] + //let orderMeetingRoooms = meetingRooms.sorted(by: {$0.1.first!.1 < $1.1.first!.1}) + let rowCount = meetingRoomsAtIndex(index: section).value.count + return rowCount + } + + + override func tableView(_ tableView: UITableView, cellForRowAt indexPath: IndexPath) -> UITableViewCell { + let cell = tableView.dequeueReusableCell(withIdentifier: "MyCell", for: indexPath) + + //let orderMeetingRoooms = meetingRooms.sorted(by: {$0.1.first!.1 < $1.1.first!.1}) + // Configure the cell... + //let categoryValue = Array(meetingRooms.values)[indexPath.section] + let categoryValue = meetingRoomsAtIndex(index: indexPath.section).value + let orderCategoryValue = categoryValue.sorted(by: {$0.1 < $1.1}) + let roomName = orderCategoryValue[indexPath.row].key + let capacity = orderCategoryValue[indexPath.row].value + + cell.textLabel!.text = roomName + cell.detailTextLabel!.text = "\(capacity)" + return cell + } + + override func tableView(_ tableView: UITableView, titleForHeaderInSection section: Int) -> String? { + + //let orderMeetingRoooms = meetingRooms.sorted(by: {$0.1.first!.1 < $1.1.first!.1}) + + return meetingRoomsAtIndex(index: section).key + } + + override func tableView(_ tableView: UITableView, titleForFooterInSection section: Int) -> String? { + //let orderMeetingRoooms = meetingRooms.sorted(by: {$0.1.first!.1 < $1.1.first!.1}) + let rowCount = meetingRoomsAtIndex(index: section).value.count + return "\(rowCount) rooms" + } + + /* + // Override to support conditional editing of the table view. + override func tableView(_ tableView: UITableView, canEditRowAt indexPath: IndexPath) -> Bool { + // Return false if you do not want the specified item to be editable. + return true + } + */ + + /* + // Override to support editing the table view. + override func tableView(_ tableView: UITableView, commit editingStyle: UITableViewCellEditingStyle, forRowAt indexPath: IndexPath) { + if editingStyle == .delete { + // Delete the row from the data source + tableView.deleteRows(at: [indexPath], with: .fade) + } else if editingStyle == .insert { + // Create a new instance of the appropriate class, insert it into the array, and add a new row to the table view + } + } + */ + + /* + // Override to support rearranging the table view. + override func tableView(_ tableView: UITableView, moveRowAt fromIndexPath: IndexPath, to: IndexPath) { + + } + */ + + /* + // Override to support conditional rearranging of the table view. + override func tableView(_ tableView: UITableView, canMoveRowAt indexPath: IndexPath) -> Bool { + // Return false if you do not want the item to be re-orderable. + return true + } + */ + + /* + // MARK: - Navigation + + // In a storyboard-based application, you will often want to do a little preparation before navigation + override func prepare(for segue: UIStoryboardSegue, sender: Any?) { + // Get the new view controller using segue.destinationViewController. + // Pass the selected object to the new view controller. + } + */ + +} diff --git "a/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/meetingRooms_4/meetingRooms/ViewController.swift" "b/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/meetingRooms_4/meetingRooms/ViewController.swift" new file mode 100644 index 0000000..24bd9b0 --- /dev/null +++ "b/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/meetingRooms_4/meetingRooms/ViewController.swift" @@ -0,0 +1,25 @@ +// +// ViewController.swift +// meetingRooms +// +// Created by 황도증 on 2017. 10. 30.. +// Copyright © 2017년 황도증. All rights reserved. +// + +import UIKit + +class ViewController: UIViewController { + + override func viewDidLoad() { + super.viewDidLoad() + // Do any additional setup after loading the view, typically from a nib. + } + + override func didReceiveMemoryWarning() { + super.didReceiveMemoryWarning() + // Dispose of any resources that can be recreated. + } + + +} + diff --git "a/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/meetingRooms_4/meetingRoomsTests/Info.plist" "b/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/meetingRooms_4/meetingRoomsTests/Info.plist" new file mode 100644 index 0000000..6c40a6c --- /dev/null +++ "b/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/meetingRooms_4/meetingRoomsTests/Info.plist" @@ -0,0 +1,22 @@ + + + + + CFBundleDevelopmentRegion + $(DEVELOPMENT_LANGUAGE) + CFBundleExecutable + $(EXECUTABLE_NAME) + CFBundleIdentifier + $(PRODUCT_BUNDLE_IDENTIFIER) + CFBundleInfoDictionaryVersion + 6.0 + CFBundleName + $(PRODUCT_NAME) + CFBundlePackageType + BNDL + CFBundleShortVersionString + 1.0 + CFBundleVersion + 1 + + diff --git "a/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/meetingRooms_4/meetingRoomsTests/meetingRoomsTests.swift" "b/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/meetingRooms_4/meetingRoomsTests/meetingRoomsTests.swift" new file mode 100644 index 0000000..bfbd8d6 --- /dev/null +++ "b/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/meetingRooms_4/meetingRoomsTests/meetingRoomsTests.swift" @@ -0,0 +1,36 @@ +// +// meetingRoomsTests.swift +// meetingRoomsTests +// +// Created by 황도증 on 2017. 10. 30.. +// Copyright © 2017년 황도증. All rights reserved. +// + +import XCTest +@testable import meetingRooms + +class meetingRoomsTests: XCTestCase { + + override func setUp() { + super.setUp() + // Put setup code here. This method is called before the invocation of each test method in the class. + } + + override func tearDown() { + // Put teardown code here. This method is called after the invocation of each test method in the class. + super.tearDown() + } + + func testExample() { + // This is an example of a functional test case. + // Use XCTAssert and related functions to verify your tests produce the correct results. + } + + func testPerformanceExample() { + // This is an example of a performance test case. + self.measure { + // Put the code you want to measure the time of here. + } + } + +} diff --git "a/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/meetingRooms_4/meetingRoomsUITests/Info.plist" "b/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/meetingRooms_4/meetingRoomsUITests/Info.plist" new file mode 100644 index 0000000..6c40a6c --- /dev/null +++ "b/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/meetingRooms_4/meetingRoomsUITests/Info.plist" @@ -0,0 +1,22 @@ + + + + + CFBundleDevelopmentRegion + $(DEVELOPMENT_LANGUAGE) + CFBundleExecutable + $(EXECUTABLE_NAME) + CFBundleIdentifier + $(PRODUCT_BUNDLE_IDENTIFIER) + CFBundleInfoDictionaryVersion + 6.0 + CFBundleName + $(PRODUCT_NAME) + CFBundlePackageType + BNDL + CFBundleShortVersionString + 1.0 + CFBundleVersion + 1 + + diff --git "a/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/meetingRooms_4/meetingRoomsUITests/meetingRoomsUITests.swift" "b/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/meetingRooms_4/meetingRoomsUITests/meetingRoomsUITests.swift" new file mode 100644 index 0000000..4873bfa --- /dev/null +++ "b/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/meetingRooms_4/meetingRoomsUITests/meetingRoomsUITests.swift" @@ -0,0 +1,36 @@ +// +// meetingRoomsUITests.swift +// meetingRoomsUITests +// +// Created by 황도증 on 2017. 10. 30.. +// Copyright © 2017년 황도증. All rights reserved. +// + +import XCTest + +class meetingRoomsUITests: XCTestCase { + + override func setUp() { + super.setUp() + + // Put setup code here. This method is called before the invocation of each test method in the class. + + // In UI tests it is usually best to stop immediately when a failure occurs. + continueAfterFailure = false + // UI tests must launch the application that they test. Doing this in setup will make sure it happens for each test method. + XCUIApplication().launch() + + // In UI tests it’s important to set the initial state - such as interface orientation - required for your tests before they run. The setUp method is a good place to do this. + } + + override func tearDown() { + // Put teardown code here. This method is called after the invocation of each test method in the class. + super.tearDown() + } + + func testExample() { + // Use recording to get started writing UI tests. + // Use XCTAssert and related functions to verify your tests produce the correct results. + } + +} diff --git "a/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/meetingRooms_alert&action/meetingRooms.xcodeproj/project.pbxproj" "b/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/meetingRooms_alert&action/meetingRooms.xcodeproj/project.pbxproj" new file mode 100644 index 0000000..d0ea954 --- /dev/null +++ "b/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/meetingRooms_alert&action/meetingRooms.xcodeproj/project.pbxproj" @@ -0,0 +1,573 @@ +// !$*UTF8*$! +{ + archiveVersion = 1; + classes = { + }; + objectVersion = 48; + objects = { + +/* Begin PBXBuildFile section */ + AE99575B1FA704AF00397D38 /* AppDelegate.swift in Sources */ = {isa = PBXBuildFile; fileRef = AE99575A1FA704AF00397D38 /* AppDelegate.swift */; }; + AE99575D1FA704AF00397D38 /* ViewController.swift in Sources */ = {isa = PBXBuildFile; fileRef = AE99575C1FA704AF00397D38 /* ViewController.swift */; }; + AE9957601FA704AF00397D38 /* Main.storyboard in Resources */ = {isa = PBXBuildFile; fileRef = AE99575E1FA704AF00397D38 /* Main.storyboard */; }; + AE9957621FA704AF00397D38 /* Assets.xcassets in Resources */ = {isa = PBXBuildFile; fileRef = AE9957611FA704AF00397D38 /* Assets.xcassets */; }; + AE9957651FA704AF00397D38 /* LaunchScreen.storyboard in Resources */ = {isa = PBXBuildFile; fileRef = AE9957631FA704AF00397D38 /* LaunchScreen.storyboard */; }; + AE9957701FA704AF00397D38 /* meetingRoomsTests.swift in Sources */ = {isa = PBXBuildFile; fileRef = AE99576F1FA704AF00397D38 /* meetingRoomsTests.swift */; }; + AE99577B1FA704B000397D38 /* meetingRoomsUITests.swift in Sources */ = {isa = PBXBuildFile; fileRef = AE99577A1FA704B000397D38 /* meetingRoomsUITests.swift */; }; + AE9957891FA7054800397D38 /* MeetingRoomListViewController.swift in Sources */ = {isa = PBXBuildFile; fileRef = AE9957881FA7054800397D38 /* MeetingRoomListViewController.swift */; }; + AEB3189D1FB4641000AEB094 /* DataCenter.swift in Sources */ = {isa = PBXBuildFile; fileRef = AEB3189C1FB4641000AEB094 /* DataCenter.swift */; }; + AEB3189F1FB4684600AEB094 /* BranchListViewController.swift in Sources */ = {isa = PBXBuildFile; fileRef = AEB3189E1FB4684600AEB094 /* BranchListViewController.swift */; }; + AEB318A11FB4685800AEB094 /* ServiceListViewController.swift in Sources */ = {isa = PBXBuildFile; fileRef = AEB318A01FB4685800AEB094 /* ServiceListViewController.swift */; }; +/* End PBXBuildFile section */ + +/* Begin PBXContainerItemProxy section */ + AE99576C1FA704AF00397D38 /* PBXContainerItemProxy */ = { + isa = PBXContainerItemProxy; + containerPortal = AE99574F1FA704AF00397D38 /* Project object */; + proxyType = 1; + remoteGlobalIDString = AE9957561FA704AF00397D38; + remoteInfo = meetingRooms; + }; + AE9957771FA704B000397D38 /* PBXContainerItemProxy */ = { + isa = PBXContainerItemProxy; + containerPortal = AE99574F1FA704AF00397D38 /* Project object */; + proxyType = 1; + remoteGlobalIDString = AE9957561FA704AF00397D38; + remoteInfo = meetingRooms; + }; +/* End PBXContainerItemProxy section */ + +/* Begin PBXFileReference section */ + AE9957571FA704AF00397D38 /* meetingRooms.app */ = {isa = PBXFileReference; explicitFileType = wrapper.application; includeInIndex = 0; path = meetingRooms.app; sourceTree = BUILT_PRODUCTS_DIR; }; + AE99575A1FA704AF00397D38 /* AppDelegate.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = AppDelegate.swift; sourceTree = ""; }; + AE99575C1FA704AF00397D38 /* ViewController.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = ViewController.swift; sourceTree = ""; }; + AE99575F1FA704AF00397D38 /* Base */ = {isa = PBXFileReference; lastKnownFileType = file.storyboard; name = Base; path = Base.lproj/Main.storyboard; sourceTree = ""; }; + AE9957611FA704AF00397D38 /* Assets.xcassets */ = {isa = PBXFileReference; lastKnownFileType = folder.assetcatalog; path = Assets.xcassets; sourceTree = ""; }; + AE9957641FA704AF00397D38 /* Base */ = {isa = PBXFileReference; lastKnownFileType = file.storyboard; name = Base; path = Base.lproj/LaunchScreen.storyboard; sourceTree = ""; }; + AE9957661FA704AF00397D38 /* Info.plist */ = {isa = PBXFileReference; lastKnownFileType = text.plist.xml; path = Info.plist; sourceTree = ""; }; + AE99576B1FA704AF00397D38 /* meetingRoomsTests.xctest */ = {isa = PBXFileReference; explicitFileType = wrapper.cfbundle; includeInIndex = 0; path = meetingRoomsTests.xctest; sourceTree = BUILT_PRODUCTS_DIR; }; + AE99576F1FA704AF00397D38 /* meetingRoomsTests.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = meetingRoomsTests.swift; sourceTree = ""; }; + AE9957711FA704AF00397D38 /* Info.plist */ = {isa = PBXFileReference; lastKnownFileType = text.plist.xml; path = Info.plist; sourceTree = ""; }; + AE9957761FA704B000397D38 /* meetingRoomsUITests.xctest */ = {isa = PBXFileReference; explicitFileType = wrapper.cfbundle; includeInIndex = 0; path = meetingRoomsUITests.xctest; sourceTree = BUILT_PRODUCTS_DIR; }; + AE99577A1FA704B000397D38 /* meetingRoomsUITests.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = meetingRoomsUITests.swift; sourceTree = ""; }; + AE99577C1FA704B000397D38 /* Info.plist */ = {isa = PBXFileReference; lastKnownFileType = text.plist.xml; path = Info.plist; sourceTree = ""; }; + AE9957881FA7054800397D38 /* MeetingRoomListViewController.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = MeetingRoomListViewController.swift; sourceTree = ""; }; + AEB3189C1FB4641000AEB094 /* DataCenter.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = DataCenter.swift; sourceTree = ""; }; + AEB3189E1FB4684600AEB094 /* BranchListViewController.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = BranchListViewController.swift; sourceTree = ""; }; + AEB318A01FB4685800AEB094 /* ServiceListViewController.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = ServiceListViewController.swift; sourceTree = ""; }; +/* End PBXFileReference section */ + +/* Begin PBXFrameworksBuildPhase section */ + AE9957541FA704AF00397D38 /* Frameworks */ = { + isa = PBXFrameworksBuildPhase; + buildActionMask = 2147483647; + files = ( + ); + runOnlyForDeploymentPostprocessing = 0; + }; + AE9957681FA704AF00397D38 /* Frameworks */ = { + isa = PBXFrameworksBuildPhase; + buildActionMask = 2147483647; + files = ( + ); + runOnlyForDeploymentPostprocessing = 0; + }; + AE9957731FA704B000397D38 /* Frameworks */ = { + isa = PBXFrameworksBuildPhase; + buildActionMask = 2147483647; + files = ( + ); + runOnlyForDeploymentPostprocessing = 0; + }; +/* End PBXFrameworksBuildPhase section */ + +/* Begin PBXGroup section */ + AE99574E1FA704AF00397D38 = { + isa = PBXGroup; + children = ( + AE9957591FA704AF00397D38 /* meetingRooms */, + AE99576E1FA704AF00397D38 /* meetingRoomsTests */, + AE9957791FA704B000397D38 /* meetingRoomsUITests */, + AE9957581FA704AF00397D38 /* Products */, + ); + sourceTree = ""; + }; + AE9957581FA704AF00397D38 /* Products */ = { + isa = PBXGroup; + children = ( + AE9957571FA704AF00397D38 /* meetingRooms.app */, + AE99576B1FA704AF00397D38 /* meetingRoomsTests.xctest */, + AE9957761FA704B000397D38 /* meetingRoomsUITests.xctest */, + ); + name = Products; + sourceTree = ""; + }; + AE9957591FA704AF00397D38 /* meetingRooms */ = { + isa = PBXGroup; + children = ( + AE99575A1FA704AF00397D38 /* AppDelegate.swift */, + AE99575C1FA704AF00397D38 /* ViewController.swift */, + AE99575E1FA704AF00397D38 /* Main.storyboard */, + AEB3189C1FB4641000AEB094 /* DataCenter.swift */, + AEB3189E1FB4684600AEB094 /* BranchListViewController.swift */, + AEB318A01FB4685800AEB094 /* ServiceListViewController.swift */, + AE9957881FA7054800397D38 /* MeetingRoomListViewController.swift */, + AE9957611FA704AF00397D38 /* Assets.xcassets */, + AE9957631FA704AF00397D38 /* LaunchScreen.storyboard */, + AE9957661FA704AF00397D38 /* Info.plist */, + ); + path = meetingRooms; + sourceTree = ""; + }; + AE99576E1FA704AF00397D38 /* meetingRoomsTests */ = { + isa = PBXGroup; + children = ( + AE99576F1FA704AF00397D38 /* meetingRoomsTests.swift */, + AE9957711FA704AF00397D38 /* Info.plist */, + ); + path = meetingRoomsTests; + sourceTree = ""; + }; + AE9957791FA704B000397D38 /* meetingRoomsUITests */ = { + isa = PBXGroup; + children = ( + AE99577A1FA704B000397D38 /* meetingRoomsUITests.swift */, + AE99577C1FA704B000397D38 /* Info.plist */, + ); + path = meetingRoomsUITests; + sourceTree = ""; + }; +/* End PBXGroup section */ + +/* Begin PBXNativeTarget section */ + AE9957561FA704AF00397D38 /* meetingRooms */ = { + isa = PBXNativeTarget; + buildConfigurationList = AE99577F1FA704B000397D38 /* Build configuration list for PBXNativeTarget "meetingRooms" */; + buildPhases = ( + AE9957531FA704AF00397D38 /* Sources */, + AE9957541FA704AF00397D38 /* Frameworks */, + AE9957551FA704AF00397D38 /* Resources */, + ); + buildRules = ( + ); + dependencies = ( + ); + name = meetingRooms; + productName = meetingRooms; + productReference = AE9957571FA704AF00397D38 /* meetingRooms.app */; + productType = "com.apple.product-type.application"; + }; + AE99576A1FA704AF00397D38 /* meetingRoomsTests */ = { + isa = PBXNativeTarget; + buildConfigurationList = AE9957821FA704B000397D38 /* Build configuration list for PBXNativeTarget "meetingRoomsTests" */; + buildPhases = ( + AE9957671FA704AF00397D38 /* Sources */, + AE9957681FA704AF00397D38 /* Frameworks */, + AE9957691FA704AF00397D38 /* Resources */, + ); + buildRules = ( + ); + dependencies = ( + AE99576D1FA704AF00397D38 /* PBXTargetDependency */, + ); + name = meetingRoomsTests; + productName = meetingRoomsTests; + productReference = AE99576B1FA704AF00397D38 /* meetingRoomsTests.xctest */; + productType = "com.apple.product-type.bundle.unit-test"; + }; + AE9957751FA704B000397D38 /* meetingRoomsUITests */ = { + isa = PBXNativeTarget; + buildConfigurationList = AE9957851FA704B000397D38 /* Build configuration list for PBXNativeTarget "meetingRoomsUITests" */; + buildPhases = ( + AE9957721FA704B000397D38 /* Sources */, + AE9957731FA704B000397D38 /* Frameworks */, + AE9957741FA704B000397D38 /* Resources */, + ); + buildRules = ( + ); + dependencies = ( + AE9957781FA704B000397D38 /* PBXTargetDependency */, + ); + name = meetingRoomsUITests; + productName = meetingRoomsUITests; + productReference = AE9957761FA704B000397D38 /* meetingRoomsUITests.xctest */; + productType = "com.apple.product-type.bundle.ui-testing"; + }; +/* End PBXNativeTarget section */ + +/* Begin PBXProject section */ + AE99574F1FA704AF00397D38 /* Project object */ = { + isa = PBXProject; + attributes = { + LastSwiftUpdateCheck = 0900; + LastUpgradeCheck = 0900; + ORGANIZATIONNAME = "황도증"; + TargetAttributes = { + AE9957561FA704AF00397D38 = { + CreatedOnToolsVersion = 9.0.1; + ProvisioningStyle = Automatic; + }; + AE99576A1FA704AF00397D38 = { + CreatedOnToolsVersion = 9.0.1; + ProvisioningStyle = Automatic; + TestTargetID = AE9957561FA704AF00397D38; + }; + AE9957751FA704B000397D38 = { + CreatedOnToolsVersion = 9.0.1; + ProvisioningStyle = Automatic; + TestTargetID = AE9957561FA704AF00397D38; + }; + }; + }; + buildConfigurationList = AE9957521FA704AF00397D38 /* Build configuration list for PBXProject "meetingRooms" */; + compatibilityVersion = "Xcode 8.0"; + developmentRegion = en; + hasScannedForEncodings = 0; + knownRegions = ( + en, + Base, + ); + mainGroup = AE99574E1FA704AF00397D38; + productRefGroup = AE9957581FA704AF00397D38 /* Products */; + projectDirPath = ""; + projectRoot = ""; + targets = ( + AE9957561FA704AF00397D38 /* meetingRooms */, + AE99576A1FA704AF00397D38 /* meetingRoomsTests */, + AE9957751FA704B000397D38 /* meetingRoomsUITests */, + ); + }; +/* End PBXProject section */ + +/* Begin PBXResourcesBuildPhase section */ + AE9957551FA704AF00397D38 /* Resources */ = { + isa = PBXResourcesBuildPhase; + buildActionMask = 2147483647; + files = ( + AE9957651FA704AF00397D38 /* LaunchScreen.storyboard in Resources */, + AE9957621FA704AF00397D38 /* Assets.xcassets in Resources */, + AE9957601FA704AF00397D38 /* Main.storyboard in Resources */, + ); + runOnlyForDeploymentPostprocessing = 0; + }; + AE9957691FA704AF00397D38 /* Resources */ = { + isa = PBXResourcesBuildPhase; + buildActionMask = 2147483647; + files = ( + ); + runOnlyForDeploymentPostprocessing = 0; + }; + AE9957741FA704B000397D38 /* Resources */ = { + isa = PBXResourcesBuildPhase; + buildActionMask = 2147483647; + files = ( + ); + runOnlyForDeploymentPostprocessing = 0; + }; +/* End PBXResourcesBuildPhase section */ + +/* Begin PBXSourcesBuildPhase section */ + AE9957531FA704AF00397D38 /* Sources */ = { + isa = PBXSourcesBuildPhase; + buildActionMask = 2147483647; + files = ( + AE99575D1FA704AF00397D38 /* ViewController.swift in Sources */, + AE99575B1FA704AF00397D38 /* AppDelegate.swift in Sources */, + AEB3189D1FB4641000AEB094 /* DataCenter.swift in Sources */, + AEB3189F1FB4684600AEB094 /* BranchListViewController.swift in Sources */, + AEB318A11FB4685800AEB094 /* ServiceListViewController.swift in Sources */, + AE9957891FA7054800397D38 /* MeetingRoomListViewController.swift in Sources */, + ); + runOnlyForDeploymentPostprocessing = 0; + }; + AE9957671FA704AF00397D38 /* Sources */ = { + isa = PBXSourcesBuildPhase; + buildActionMask = 2147483647; + files = ( + AE9957701FA704AF00397D38 /* meetingRoomsTests.swift in Sources */, + ); + runOnlyForDeploymentPostprocessing = 0; + }; + AE9957721FA704B000397D38 /* Sources */ = { + isa = PBXSourcesBuildPhase; + buildActionMask = 2147483647; + files = ( + AE99577B1FA704B000397D38 /* meetingRoomsUITests.swift in Sources */, + ); + runOnlyForDeploymentPostprocessing = 0; + }; +/* End PBXSourcesBuildPhase section */ + +/* Begin PBXTargetDependency section */ + AE99576D1FA704AF00397D38 /* PBXTargetDependency */ = { + isa = PBXTargetDependency; + target = AE9957561FA704AF00397D38 /* meetingRooms */; + targetProxy = AE99576C1FA704AF00397D38 /* PBXContainerItemProxy */; + }; + AE9957781FA704B000397D38 /* PBXTargetDependency */ = { + isa = PBXTargetDependency; + target = AE9957561FA704AF00397D38 /* meetingRooms */; + targetProxy = AE9957771FA704B000397D38 /* PBXContainerItemProxy */; + }; +/* End PBXTargetDependency section */ + +/* Begin PBXVariantGroup section */ + AE99575E1FA704AF00397D38 /* Main.storyboard */ = { + isa = PBXVariantGroup; + children = ( + AE99575F1FA704AF00397D38 /* Base */, + ); + name = Main.storyboard; + sourceTree = ""; + }; + AE9957631FA704AF00397D38 /* LaunchScreen.storyboard */ = { + isa = PBXVariantGroup; + children = ( + AE9957641FA704AF00397D38 /* Base */, + ); + name = LaunchScreen.storyboard; + sourceTree = ""; + }; +/* End PBXVariantGroup section */ + +/* Begin XCBuildConfiguration section */ + AE99577D1FA704B000397D38 /* Debug */ = { + isa = XCBuildConfiguration; + buildSettings = { + ALWAYS_SEARCH_USER_PATHS = NO; + CLANG_ANALYZER_NONNULL = YES; + CLANG_ANALYZER_NUMBER_OBJECT_CONVERSION = YES_AGGRESSIVE; + CLANG_CXX_LANGUAGE_STANDARD = "gnu++14"; + CLANG_CXX_LIBRARY = "libc++"; + CLANG_ENABLE_MODULES = YES; + CLANG_ENABLE_OBJC_ARC = YES; + CLANG_WARN_BLOCK_CAPTURE_AUTORELEASING = YES; + CLANG_WARN_BOOL_CONVERSION = YES; + CLANG_WARN_COMMA = YES; + CLANG_WARN_CONSTANT_CONVERSION = YES; + CLANG_WARN_DIRECT_OBJC_ISA_USAGE = YES_ERROR; + CLANG_WARN_DOCUMENTATION_COMMENTS = YES; + CLANG_WARN_EMPTY_BODY = YES; + CLANG_WARN_ENUM_CONVERSION = YES; + CLANG_WARN_INFINITE_RECURSION = YES; + CLANG_WARN_INT_CONVERSION = YES; + CLANG_WARN_NON_LITERAL_NULL_CONVERSION = YES; + CLANG_WARN_OBJC_LITERAL_CONVERSION = YES; + CLANG_WARN_OBJC_ROOT_CLASS = YES_ERROR; + CLANG_WARN_RANGE_LOOP_ANALYSIS = YES; + CLANG_WARN_STRICT_PROTOTYPES = YES; + CLANG_WARN_SUSPICIOUS_MOVE = YES; + CLANG_WARN_UNGUARDED_AVAILABILITY = YES_AGGRESSIVE; + CLANG_WARN_UNREACHABLE_CODE = YES; + CLANG_WARN__DUPLICATE_METHOD_MATCH = YES; + CODE_SIGN_IDENTITY = "iPhone Developer"; + COPY_PHASE_STRIP = NO; + DEBUG_INFORMATION_FORMAT = dwarf; + ENABLE_STRICT_OBJC_MSGSEND = YES; + ENABLE_TESTABILITY = YES; + GCC_C_LANGUAGE_STANDARD = gnu11; + GCC_DYNAMIC_NO_PIC = NO; + GCC_NO_COMMON_BLOCKS = YES; + GCC_OPTIMIZATION_LEVEL = 0; + GCC_PREPROCESSOR_DEFINITIONS = ( + "DEBUG=1", + "$(inherited)", + ); + GCC_WARN_64_TO_32_BIT_CONVERSION = YES; + GCC_WARN_ABOUT_RETURN_TYPE = YES_ERROR; + GCC_WARN_UNDECLARED_SELECTOR = YES; + GCC_WARN_UNINITIALIZED_AUTOS = YES_AGGRESSIVE; + GCC_WARN_UNUSED_FUNCTION = YES; + GCC_WARN_UNUSED_VARIABLE = YES; + IPHONEOS_DEPLOYMENT_TARGET = 11.0; + MTL_ENABLE_DEBUG_INFO = YES; + ONLY_ACTIVE_ARCH = YES; + SDKROOT = iphoneos; + SWIFT_ACTIVE_COMPILATION_CONDITIONS = DEBUG; + SWIFT_OPTIMIZATION_LEVEL = "-Onone"; + }; + name = Debug; + }; + AE99577E1FA704B000397D38 /* Release */ = { + isa = XCBuildConfiguration; + buildSettings = { + ALWAYS_SEARCH_USER_PATHS = NO; + CLANG_ANALYZER_NONNULL = YES; + CLANG_ANALYZER_NUMBER_OBJECT_CONVERSION = YES_AGGRESSIVE; + CLANG_CXX_LANGUAGE_STANDARD = "gnu++14"; + CLANG_CXX_LIBRARY = "libc++"; + CLANG_ENABLE_MODULES = YES; + CLANG_ENABLE_OBJC_ARC = YES; + CLANG_WARN_BLOCK_CAPTURE_AUTORELEASING = YES; + CLANG_WARN_BOOL_CONVERSION = YES; + CLANG_WARN_COMMA = YES; + CLANG_WARN_CONSTANT_CONVERSION = YES; + CLANG_WARN_DIRECT_OBJC_ISA_USAGE = YES_ERROR; + CLANG_WARN_DOCUMENTATION_COMMENTS = YES; + CLANG_WARN_EMPTY_BODY = YES; + CLANG_WARN_ENUM_CONVERSION = YES; + CLANG_WARN_INFINITE_RECURSION = YES; + CLANG_WARN_INT_CONVERSION = YES; + CLANG_WARN_NON_LITERAL_NULL_CONVERSION = YES; + CLANG_WARN_OBJC_LITERAL_CONVERSION = YES; + CLANG_WARN_OBJC_ROOT_CLASS = YES_ERROR; + CLANG_WARN_RANGE_LOOP_ANALYSIS = YES; + CLANG_WARN_STRICT_PROTOTYPES = YES; + CLANG_WARN_SUSPICIOUS_MOVE = YES; + CLANG_WARN_UNGUARDED_AVAILABILITY = YES_AGGRESSIVE; + CLANG_WARN_UNREACHABLE_CODE = YES; + CLANG_WARN__DUPLICATE_METHOD_MATCH = YES; + CODE_SIGN_IDENTITY = "iPhone Developer"; + COPY_PHASE_STRIP = NO; + DEBUG_INFORMATION_FORMAT = "dwarf-with-dsym"; + ENABLE_NS_ASSERTIONS = NO; + ENABLE_STRICT_OBJC_MSGSEND = YES; + GCC_C_LANGUAGE_STANDARD = gnu11; + GCC_NO_COMMON_BLOCKS = YES; + GCC_WARN_64_TO_32_BIT_CONVERSION = YES; + GCC_WARN_ABOUT_RETURN_TYPE = YES_ERROR; + GCC_WARN_UNDECLARED_SELECTOR = YES; + GCC_WARN_UNINITIALIZED_AUTOS = YES_AGGRESSIVE; + GCC_WARN_UNUSED_FUNCTION = YES; + GCC_WARN_UNUSED_VARIABLE = YES; + IPHONEOS_DEPLOYMENT_TARGET = 11.0; + MTL_ENABLE_DEBUG_INFO = NO; + SDKROOT = iphoneos; + SWIFT_OPTIMIZATION_LEVEL = "-Owholemodule"; + VALIDATE_PRODUCT = YES; + }; + name = Release; + }; + AE9957801FA704B000397D38 /* Debug */ = { + isa = XCBuildConfiguration; + buildSettings = { + ASSETCATALOG_COMPILER_APPICON_NAME = AppIcon; + CODE_SIGN_STYLE = Automatic; + INFOPLIST_FILE = meetingRooms/Info.plist; + LD_RUNPATH_SEARCH_PATHS = "$(inherited) @executable_path/Frameworks"; + PRODUCT_BUNDLE_IDENTIFIER = "--------.meetingRooms"; + PRODUCT_NAME = "$(TARGET_NAME)"; + SWIFT_VERSION = 4.0; + TARGETED_DEVICE_FAMILY = "1,2"; + }; + name = Debug; + }; + AE9957811FA704B000397D38 /* Release */ = { + isa = XCBuildConfiguration; + buildSettings = { + ASSETCATALOG_COMPILER_APPICON_NAME = AppIcon; + CODE_SIGN_STYLE = Automatic; + INFOPLIST_FILE = meetingRooms/Info.plist; + LD_RUNPATH_SEARCH_PATHS = "$(inherited) @executable_path/Frameworks"; + PRODUCT_BUNDLE_IDENTIFIER = "--------.meetingRooms"; + PRODUCT_NAME = "$(TARGET_NAME)"; + SWIFT_VERSION = 4.0; + TARGETED_DEVICE_FAMILY = "1,2"; + }; + name = Release; + }; + AE9957831FA704B000397D38 /* Debug */ = { + isa = XCBuildConfiguration; + buildSettings = { + ALWAYS_EMBED_SWIFT_STANDARD_LIBRARIES = YES; + BUNDLE_LOADER = "$(TEST_HOST)"; + CODE_SIGN_STYLE = Automatic; + INFOPLIST_FILE = meetingRoomsTests/Info.plist; + LD_RUNPATH_SEARCH_PATHS = "$(inherited) @executable_path/Frameworks @loader_path/Frameworks"; + PRODUCT_BUNDLE_IDENTIFIER = "--------.meetingRoomsTests"; + PRODUCT_NAME = "$(TARGET_NAME)"; + SWIFT_VERSION = 4.0; + TARGETED_DEVICE_FAMILY = "1,2"; + TEST_HOST = "$(BUILT_PRODUCTS_DIR)/meetingRooms.app/meetingRooms"; + }; + name = Debug; + }; + AE9957841FA704B000397D38 /* Release */ = { + isa = XCBuildConfiguration; + buildSettings = { + ALWAYS_EMBED_SWIFT_STANDARD_LIBRARIES = YES; + BUNDLE_LOADER = "$(TEST_HOST)"; + CODE_SIGN_STYLE = Automatic; + INFOPLIST_FILE = meetingRoomsTests/Info.plist; + LD_RUNPATH_SEARCH_PATHS = "$(inherited) @executable_path/Frameworks @loader_path/Frameworks"; + PRODUCT_BUNDLE_IDENTIFIER = "--------.meetingRoomsTests"; + PRODUCT_NAME = "$(TARGET_NAME)"; + SWIFT_VERSION = 4.0; + TARGETED_DEVICE_FAMILY = "1,2"; + TEST_HOST = "$(BUILT_PRODUCTS_DIR)/meetingRooms.app/meetingRooms"; + }; + name = Release; + }; + AE9957861FA704B000397D38 /* Debug */ = { + isa = XCBuildConfiguration; + buildSettings = { + ALWAYS_EMBED_SWIFT_STANDARD_LIBRARIES = YES; + CODE_SIGN_STYLE = Automatic; + INFOPLIST_FILE = meetingRoomsUITests/Info.plist; + LD_RUNPATH_SEARCH_PATHS = "$(inherited) @executable_path/Frameworks @loader_path/Frameworks"; + PRODUCT_BUNDLE_IDENTIFIER = "--------.meetingRoomsUITests"; + PRODUCT_NAME = "$(TARGET_NAME)"; + SWIFT_VERSION = 4.0; + TARGETED_DEVICE_FAMILY = "1,2"; + TEST_TARGET_NAME = meetingRooms; + }; + name = Debug; + }; + AE9957871FA704B000397D38 /* Release */ = { + isa = XCBuildConfiguration; + buildSettings = { + ALWAYS_EMBED_SWIFT_STANDARD_LIBRARIES = YES; + CODE_SIGN_STYLE = Automatic; + INFOPLIST_FILE = meetingRoomsUITests/Info.plist; + LD_RUNPATH_SEARCH_PATHS = "$(inherited) @executable_path/Frameworks @loader_path/Frameworks"; + PRODUCT_BUNDLE_IDENTIFIER = "--------.meetingRoomsUITests"; + PRODUCT_NAME = "$(TARGET_NAME)"; + SWIFT_VERSION = 4.0; + TARGETED_DEVICE_FAMILY = "1,2"; + TEST_TARGET_NAME = meetingRooms; + }; + name = Release; + }; +/* End XCBuildConfiguration section */ + +/* Begin XCConfigurationList section */ + AE9957521FA704AF00397D38 /* Build configuration list for PBXProject "meetingRooms" */ = { + isa = XCConfigurationList; + buildConfigurations = ( + AE99577D1FA704B000397D38 /* Debug */, + AE99577E1FA704B000397D38 /* Release */, + ); + defaultConfigurationIsVisible = 0; + defaultConfigurationName = Release; + }; + AE99577F1FA704B000397D38 /* Build configuration list for PBXNativeTarget "meetingRooms" */ = { + isa = XCConfigurationList; + buildConfigurations = ( + AE9957801FA704B000397D38 /* Debug */, + AE9957811FA704B000397D38 /* Release */, + ); + defaultConfigurationIsVisible = 0; + defaultConfigurationName = Release; + }; + AE9957821FA704B000397D38 /* Build configuration list for PBXNativeTarget "meetingRoomsTests" */ = { + isa = XCConfigurationList; + buildConfigurations = ( + AE9957831FA704B000397D38 /* Debug */, + AE9957841FA704B000397D38 /* Release */, + ); + defaultConfigurationIsVisible = 0; + defaultConfigurationName = Release; + }; + AE9957851FA704B000397D38 /* Build configuration list for PBXNativeTarget "meetingRoomsUITests" */ = { + isa = XCConfigurationList; + buildConfigurations = ( + AE9957861FA704B000397D38 /* Debug */, + AE9957871FA704B000397D38 /* Release */, + ); + defaultConfigurationIsVisible = 0; + defaultConfigurationName = Release; + }; +/* End XCConfigurationList section */ + }; + rootObject = AE99574F1FA704AF00397D38 /* Project object */; +} diff --git "a/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/meetingRooms_alert&action/meetingRooms.xcodeproj/project.xcworkspace/contents.xcworkspacedata" "b/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/meetingRooms_alert&action/meetingRooms.xcodeproj/project.xcworkspace/contents.xcworkspacedata" new file mode 100644 index 0000000..8491799 --- /dev/null +++ "b/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/meetingRooms_alert&action/meetingRooms.xcodeproj/project.xcworkspace/contents.xcworkspacedata" @@ -0,0 +1,7 @@ + + + + + diff --git "a/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/meetingRooms_alert&action/meetingRooms/AppDelegate.swift" "b/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/meetingRooms_alert&action/meetingRooms/AppDelegate.swift" new file mode 100644 index 0000000..fc60321 --- /dev/null +++ "b/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/meetingRooms_alert&action/meetingRooms/AppDelegate.swift" @@ -0,0 +1,46 @@ +// +// AppDelegate.swift +// meetingRooms +// +// Created by 황도증 on 2017. 10. 30.. +// Copyright © 2017년 황도증. All rights reserved. +// + +import UIKit + +@UIApplicationMain +class AppDelegate: UIResponder, UIApplicationDelegate { + + var window: UIWindow? + + + func application(_ application: UIApplication, didFinishLaunchingWithOptions launchOptions: [UIApplicationLaunchOptionsKey: Any]?) -> Bool { + // Override point for customization after application launch. + return true + } + + func applicationWillResignActive(_ application: UIApplication) { + // Sent when the application is about to move from active to inactive state. This can occur for certain types of temporary interruptions (such as an incoming phone call or SMS message) or when the user quits the application and it begins the transition to the background state. + // Use this method to pause ongoing tasks, disable timers, and invalidate graphics rendering callbacks. Games should use this method to pause the game. + } + + func applicationDidEnterBackground(_ application: UIApplication) { + // Use this method to release shared resources, save user data, invalidate timers, and store enough application state information to restore your application to its current state in case it is terminated later. + // If your application supports background execution, this method is called instead of applicationWillTerminate: when the user quits. + } + + func applicationWillEnterForeground(_ application: UIApplication) { + // Called as part of the transition from the background to the active state; here you can undo many of the changes made on entering the background. + } + + func applicationDidBecomeActive(_ application: UIApplication) { + // Restart any tasks that were paused (or not yet started) while the application was inactive. If the application was previously in the background, optionally refresh the user interface. + } + + func applicationWillTerminate(_ application: UIApplication) { + // Called when the application is about to terminate. Save data if appropriate. See also applicationDidEnterBackground:. + } + + +} + diff --git "a/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/meetingRooms_alert&action/meetingRooms/Assets.xcassets/AppIcon.appiconset/Contents.json" "b/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/meetingRooms_alert&action/meetingRooms/Assets.xcassets/AppIcon.appiconset/Contents.json" new file mode 100644 index 0000000..d8db8d6 --- /dev/null +++ "b/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/meetingRooms_alert&action/meetingRooms/Assets.xcassets/AppIcon.appiconset/Contents.json" @@ -0,0 +1,98 @@ +{ + "images" : [ + { + "idiom" : "iphone", + "size" : "20x20", + "scale" : "2x" + }, + { + "idiom" : "iphone", + "size" : "20x20", + "scale" : "3x" + }, + { + "idiom" : "iphone", + "size" : "29x29", + "scale" : "2x" + }, + { + "idiom" : "iphone", + "size" : "29x29", + "scale" : "3x" + }, + { + "idiom" : "iphone", + "size" : "40x40", + "scale" : "2x" + }, + { + "idiom" : "iphone", + "size" : "40x40", + "scale" : "3x" + }, + { + "idiom" : "iphone", + "size" : "60x60", + "scale" : "2x" + }, + { + "idiom" : "iphone", + "size" : "60x60", + "scale" : "3x" + }, + { + "idiom" : "ipad", + "size" : "20x20", + "scale" : "1x" + }, + { + "idiom" : "ipad", + "size" : "20x20", + "scale" : "2x" + }, + { + "idiom" : "ipad", + "size" : "29x29", + "scale" : "1x" + }, + { + "idiom" : "ipad", + "size" : "29x29", + "scale" : "2x" + }, + { + "idiom" : "ipad", + "size" : "40x40", + "scale" : "1x" + }, + { + "idiom" : "ipad", + "size" : "40x40", + "scale" : "2x" + }, + { + "idiom" : "ipad", + "size" : "76x76", + "scale" : "1x" + }, + { + "idiom" : "ipad", + "size" : "76x76", + "scale" : "2x" + }, + { + "idiom" : "ipad", + "size" : "83.5x83.5", + "scale" : "2x" + }, + { + "idiom" : "ios-marketing", + "size" : "1024x1024", + "scale" : "1x" + } + ], + "info" : { + "version" : 1, + "author" : "xcode" + } +} \ No newline at end of file diff --git "a/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/meetingRooms_alert&action/meetingRooms/Base.lproj/LaunchScreen.storyboard" "b/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/meetingRooms_alert&action/meetingRooms/Base.lproj/LaunchScreen.storyboard" new file mode 100644 index 0000000..f83f6fd --- /dev/null +++ "b/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/meetingRooms_alert&action/meetingRooms/Base.lproj/LaunchScreen.storyboard" @@ -0,0 +1,25 @@ + + + + + + + + + + + + + + + + + + + + + + + + + diff --git "a/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/meetingRooms_alert&action/meetingRooms/Base.lproj/Main.storyboard" "b/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/meetingRooms_alert&action/meetingRooms/Base.lproj/Main.storyboard" new file mode 100644 index 0000000..f5e009b --- /dev/null +++ "b/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/meetingRooms_alert&action/meetingRooms/Base.lproj/Main.storyboard" @@ -0,0 +1,259 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + diff --git "a/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/meetingRooms_alert&action/meetingRooms/BranchListViewController.swift" "b/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/meetingRooms_alert&action/meetingRooms/BranchListViewController.swift" new file mode 100644 index 0000000..fa28525 --- /dev/null +++ "b/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/meetingRooms_alert&action/meetingRooms/BranchListViewController.swift" @@ -0,0 +1,119 @@ +// +// BranchListViewController.swift +// meetingRooms +// +// Created by 황도증 on 2017. 11. 9.. +// Copyright © 2017년 황도증. All rights reserved. +// + +import UIKit + +class BranchListViewController: UITableViewController { + + override func viewDidLoad() { + super.viewDidLoad() + + // Uncomment the following line to preserve selection between presentations + // self.clearsSelectionOnViewWillAppear = false + + // Uncomment the following line to display an Edit button in the navigation bar for this view controller. + // self.navigationItem.rightBarButtonItem = self.editButtonItem + + self.navigationController?.isToolbarHidden = true + } + + override func didReceiveMemoryWarning() { + super.didReceiveMemoryWarning() + // Dispose of any resources that can be recreated. + } + + // MARK: - Table view data source + + override func numberOfSections(in tableView: UITableView) -> Int { + // #warning Incomplete implementation, return the number of sections + return 1 + } + + @IBAction func locationTurnOn(_ sender: Any) { + let locationAlert = UIAlertController(title:"위치정보요청", message: "위치정보를 기반으로 가까운 지점을 자동으로 선택할 수 있습니다.", preferredStyle: .actionSheet) + + let locationAction = UIAlertAction(title: "위치정보켜기", style: .default, handler: {(action:UIAlertAction) -> Void in print("위치정보켜기 선택")}) + + let openMapAction = UIAlertAction(title: "지도에서 열기", style: .default, handler: {(action:UIAlertAction) -> Void in print("지도앱에서 열기 선택")}) + + locationAlert.addAction(locationAction) + locationAlert.addAction(openMapAction) + + self.present(locationAlert, animated: true, completion: nil) + } + override func tableView(_ tableView: UITableView, numberOfRowsInSection section: Int) -> Int { + // #warning Incomplete implementation, return the number of rows + let rowCount = dataCenter.branches.count + return rowCount + } + + + override func tableView(_ tableView: UITableView, cellForRowAt indexPath: IndexPath) -> UITableViewCell { + let cell = tableView.dequeueReusableCell(withIdentifier: "BranchCell", for: indexPath) + + // Configure the cell... + let branch = dataCenter.branches[indexPath.row] + cell.textLabel?.text = branch.name + + return cell + } + + + /* + // Override to support conditional editing of the table view. + override func tableView(_ tableView: UITableView, canEditRowAt indexPath: IndexPath) -> Bool { + // Return false if you do not want the specified item to be editable. + return true + } + */ + + /* + // Override to support editing the table view. + override func tableView(_ tableView: UITableView, commit editingStyle: UITableViewCellEditingStyle, forRowAt indexPath: IndexPath) { + if editingStyle == .delete { + // Delete the row from the data source + tableView.deleteRows(at: [indexPath], with: .fade) + } else if editingStyle == .insert { + // Create a new instance of the appropriate class, insert it into the array, and add a new row to the table view + } + } + */ + + /* + // Override to support rearranging the table view. + override func tableView(_ tableView: UITableView, moveRowAt fromIndexPath: IndexPath, to: IndexPath) { + + } + */ + + /* + // Override to support conditional rearranging of the table view. + override func tableView(_ tableView: UITableView, canMoveRowAt indexPath: IndexPath) -> Bool { + // Return false if you do not want the item to be re-orderable. + return true + } + */ + + + // MARK: - Navigation + + // In a storyboard-based application, you will often want to do a little preparation before navigation + override func prepare(for segue: UIStoryboardSegue, sender: Any?) { + // Get the new view controller using segue.destinationViewController. + // Pass the selected object to the new view controller. + + if segue.identifier == "ServiceSegue" { + if let destination = segue.destination as? ServiceListViewController { + if let selectedIndex = self.tableView.indexPathForSelectedRow?.row { + destination.branch = dataCenter.branches[selectedIndex] as Branch + } + } + } + + } +} diff --git "a/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/meetingRooms_alert&action/meetingRooms/DataCenter.swift" "b/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/meetingRooms_alert&action/meetingRooms/DataCenter.swift" new file mode 100644 index 0000000..4231269 --- /dev/null +++ "b/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/meetingRooms_alert&action/meetingRooms/DataCenter.swift" @@ -0,0 +1,66 @@ +// +// DataCenter.swift +// meetingRooms +// +// Created by 황도증 on 2017. 11. 9.. +// Copyright © 2017년 황도증. All rights reserved. +// + +import Foundation + +let dataCenter:DataCenter = DataCenter() + +class DataCenter { + var branches:[Branch] = [] + + init (){ + let banksyRoom = MeetingRoom(name:"Banksy", capacity: 4) + let kahloRoom = MeetingRoom(name:"Kahlo", capacity: 8) + let riveraRoom = MeetingRoom(name:"Rivera", capacity: 8) + let picasoRoom = MeetingRoom(name:"Picaso", capacity: 10) + + let vehicleService = Service(name: "차량예약") + let meetingRoomService = Service(name: "회의실예약") + let visitorService = Service(name: "방문자예약") + let deskService = Service(name: "데스크예약") + meetingRoomService.items = [banksyRoom, kahloRoom, riveraRoom, picasoRoom] + + let pangyoBranch = Branch(name: "판교점") + let samsungBranch = Branch(name: "삼성점") + let yeoksamBranch = Branch(name: "역삼점") + let sinrimBranch = Branch(name: "신림점") + let songdooBranch = Branch(name: "송도점") + let anamBranch = Branch(name: "안암점") + pangyoBranch.services = [vehicleService, meetingRoomService, visitorService, deskService] + + branches += [pangyoBranch, samsungBranch, yeoksamBranch, sinrimBranch, songdooBranch, anamBranch] + } +} + +class Branch { + let name:String + var services:[Service]? + + init(name:String) { + self.name = name + } +} + +class Service { + let name:String + var items:[MeetingRoom]? + + init(name:String) { + self.name = name + } +} + +class MeetingRoom { + let name:String + let capacity:Int + + init(name:String, capacity:Int) { + self.name = name + self.capacity = capacity + } +} diff --git "a/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/meetingRooms_alert&action/meetingRooms/Info.plist" "b/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/meetingRooms_alert&action/meetingRooms/Info.plist" new file mode 100644 index 0000000..16be3b6 --- /dev/null +++ "b/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/meetingRooms_alert&action/meetingRooms/Info.plist" @@ -0,0 +1,45 @@ + + + + + CFBundleDevelopmentRegion + $(DEVELOPMENT_LANGUAGE) + CFBundleExecutable + $(EXECUTABLE_NAME) + CFBundleIdentifier + $(PRODUCT_BUNDLE_IDENTIFIER) + CFBundleInfoDictionaryVersion + 6.0 + CFBundleName + $(PRODUCT_NAME) + CFBundlePackageType + APPL + CFBundleShortVersionString + 1.0 + CFBundleVersion + 1 + LSRequiresIPhoneOS + + UILaunchStoryboardName + LaunchScreen + UIMainStoryboardFile + Main + UIRequiredDeviceCapabilities + + armv7 + + UISupportedInterfaceOrientations + + UIInterfaceOrientationPortrait + UIInterfaceOrientationLandscapeLeft + UIInterfaceOrientationLandscapeRight + + UISupportedInterfaceOrientations~ipad + + UIInterfaceOrientationPortrait + UIInterfaceOrientationPortraitUpsideDown + UIInterfaceOrientationLandscapeLeft + UIInterfaceOrientationLandscapeRight + + + diff --git "a/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/meetingRooms_alert&action/meetingRooms/MeetingRoomListViewController.swift" "b/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/meetingRooms_alert&action/meetingRooms/MeetingRoomListViewController.swift" new file mode 100644 index 0000000..0d523b3 --- /dev/null +++ "b/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/meetingRooms_alert&action/meetingRooms/MeetingRoomListViewController.swift" @@ -0,0 +1,111 @@ +// +// MeetingRoomListViewController.swift +// meetingRooms +// +// Created by 황도증 on 2017. 10. 30.. +// Copyright © 2017년 황도증. All rights reserved. +// + +import UIKit + +class MeetingRoomListViewController: UITableViewController { + + var service:Service? + + override func viewDidLoad() { + super.viewDidLoad() + + // Uncomment the following line to preserve selection between presentations + // self.clearsSelectionOnViewWillAppear = false + + // Uncomment the following line to display an Edit button in the navigation bar for this view controller. + // self.navigationItem.rightBarButtonItem = self.editButtonItem + + self.title = service?.name + } + + override func didReceiveMemoryWarning() { + super.didReceiveMemoryWarning() + // Dispose of any resources that can be recreated. + } + + // MARK: - Table view data source + + override func numberOfSections(in tableView: UITableView) -> Int { + // #warning Incomplete implementation, return the number of sections + return 1 + } + + override func tableView(_ tableView: UITableView, numberOfRowsInSection section: Int) -> Int { + // #warning Incomplete implementation, return the number of rows + //let categoryValues = Array(meetingRooms.values)[section] + //let orderMeetingRoooms = meetingRooms.sorted(by: {$0.1.first!.1 < $1.1.first!.1}) + guard let rowCount = service?.items?.count else { + return 0 + } + return rowCount + } + + + override func tableView(_ tableView: UITableView, cellForRowAt indexPath: IndexPath) -> UITableViewCell { + let cell = tableView.dequeueReusableCell(withIdentifier: "ItemCell", for: indexPath) + + //let orderMeetingRoooms = meetingRooms.sorted(by: {$0.1.first!.1 < $1.1.first!.1}) + // Configure the cell... + //let categoryValue = Array(meetingRooms.values)[indexPath.section] + + guard let meetingRoom = service?.items?[indexPath.row] else { + return cell + } + + cell.textLabel!.text = meetingRoom.name + cell.detailTextLabel!.text = String(meetingRoom.capacity) + return cell + } + + /* + // Override to support conditional editing of the table view. + override func tableView(_ tableView: UITableView, canEditRowAt indexPath: IndexPath) -> Bool { + // Return false if you do not want the specified item to be editable. + return true + } + */ + + /* + // Override to support editing the table view. + override func tableView(_ tableView: UITableView, commit editingStyle: UITableViewCellEditingStyle, forRowAt indexPath: IndexPath) { + if editingStyle == .delete { + // Delete the row from the data source + tableView.deleteRows(at: [indexPath], with: .fade) + } else if editingStyle == .insert { + // Create a new instance of the appropriate class, insert it into the array, and add a new row to the table view + } + } + */ + + /* + // Override to support rearranging the table view. + override func tableView(_ tableView: UITableView, moveRowAt fromIndexPath: IndexPath, to: IndexPath) { + + } + */ + + /* + // Override to support conditional rearranging of the table view. + override func tableView(_ tableView: UITableView, canMoveRowAt indexPath: IndexPath) -> Bool { + // Return false if you do not want the item to be re-orderable. + return true + } + */ + + + // MARK: - Navigation +/* + // In a storyboard-based application, you will often want to do a little preparation before navigation + override func prepare(for segue: UIStoryboardSegue, sender: Any?) { + // Get the new view controller using segue.destinationViewController. + // Pass the selected object to the new view controller. + + } + */ +} diff --git "a/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/meetingRooms_alert&action/meetingRooms/ServiceListViewController.swift" "b/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/meetingRooms_alert&action/meetingRooms/ServiceListViewController.swift" new file mode 100644 index 0000000..091d906 --- /dev/null +++ "b/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/meetingRooms_alert&action/meetingRooms/ServiceListViewController.swift" @@ -0,0 +1,113 @@ +// +// ServiceListViewController.swift +// meetingRooms +// +// Created by 황도증 on 2017. 11. 9.. +// Copyright © 2017년 황도증. All rights reserved. +// + +import UIKit + +class ServiceListViewController: UITableViewController { + + var branch:Branch? + + override func viewDidLoad() { + super.viewDidLoad() + + // Uncomment the following line to preserve selection between presentations + // self.clearsSelectionOnViewWillAppear = false + + // Uncomment the following line to display an Edit button in the navigation bar for this view controller. + // self.navigationItem.rightBarButtonItem = self.editButtonItem + self.title = branch?.name + self.navigationController?.isToolbarHidden = false + } + + override func didReceiveMemoryWarning() { + super.didReceiveMemoryWarning() + // Dispose of any resources that can be recreated. + } + + // MARK: - Table view data source + + override func numberOfSections(in tableView: UITableView) -> Int { + // #warning Incomplete implementation, return the number of sections + return 1 + } + + override func tableView(_ tableView: UITableView, numberOfRowsInSection section: Int) -> Int { + // #warning Incomplete implementation, return the number of rows + guard let rowCount = branch?.services?.count else { + return 0 + } + return rowCount + } + + + override func tableView(_ tableView: UITableView, cellForRowAt indexPath: IndexPath) -> UITableViewCell { + let cell = tableView.dequeueReusableCell(withIdentifier: "ServiceCell", for: indexPath) + + // Configure the cell... + guard let service = branch?.services?[indexPath.row] else { + return cell + } + + cell.textLabel?.text = service.name + + return cell + } + + + /* + // Override to support conditional editing of the table view. + override func tableView(_ tableView: UITableView, canEditRowAt indexPath: IndexPath) -> Bool { + // Return false if you do not want the specified item to be editable. + return true + } + */ + + /* + // Override to support editing the table view. + override func tableView(_ tableView: UITableView, commit editingStyle: UITableViewCellEditingStyle, forRowAt indexPath: IndexPath) { + if editingStyle == .delete { + // Delete the row from the data source + tableView.deleteRows(at: [indexPath], with: .fade) + } else if editingStyle == .insert { + // Create a new instance of the appropriate class, insert it into the array, and add a new row to the table view + } + } + */ + + /* + // Override to support rearranging the table view. + override func tableView(_ tableView: UITableView, moveRowAt fromIndexPath: IndexPath, to: IndexPath) { + + } + */ + + /* + // Override to support conditional rearranging of the table view. + override func tableView(_ tableView: UITableView, canMoveRowAt indexPath: IndexPath) -> Bool { + // Return false if you do not want the item to be re-orderable. + return true + } + */ + + + // MARK: - Navigation + + // In a storyboard-based application, you will often want to do a little preparation before navigation + override func prepare(for segue: UIStoryboardSegue, sender: Any?) { + // Get the new view controller using segue.destinationViewController. + // Pass the selected object to the new view controller. + if segue.identifier == "MeetingRoomSegue" { + guard let destination = segue.destination as? MeetingRoomListViewController, let selectedIndex = self.tableView.indexPathForSelectedRow?.row, let service = branch?.services?[selectedIndex] else { + return + } + destination.service = service + } + } + + +} diff --git "a/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/meetingRooms_alert&action/meetingRooms/ViewController.swift" "b/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/meetingRooms_alert&action/meetingRooms/ViewController.swift" new file mode 100644 index 0000000..24bd9b0 --- /dev/null +++ "b/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/meetingRooms_alert&action/meetingRooms/ViewController.swift" @@ -0,0 +1,25 @@ +// +// ViewController.swift +// meetingRooms +// +// Created by 황도증 on 2017. 10. 30.. +// Copyright © 2017년 황도증. All rights reserved. +// + +import UIKit + +class ViewController: UIViewController { + + override func viewDidLoad() { + super.viewDidLoad() + // Do any additional setup after loading the view, typically from a nib. + } + + override func didReceiveMemoryWarning() { + super.didReceiveMemoryWarning() + // Dispose of any resources that can be recreated. + } + + +} + diff --git "a/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/meetingRooms_alert&action/meetingRoomsTests/Info.plist" "b/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/meetingRooms_alert&action/meetingRoomsTests/Info.plist" new file mode 100644 index 0000000..6c40a6c --- /dev/null +++ "b/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/meetingRooms_alert&action/meetingRoomsTests/Info.plist" @@ -0,0 +1,22 @@ + + + + + CFBundleDevelopmentRegion + $(DEVELOPMENT_LANGUAGE) + CFBundleExecutable + $(EXECUTABLE_NAME) + CFBundleIdentifier + $(PRODUCT_BUNDLE_IDENTIFIER) + CFBundleInfoDictionaryVersion + 6.0 + CFBundleName + $(PRODUCT_NAME) + CFBundlePackageType + BNDL + CFBundleShortVersionString + 1.0 + CFBundleVersion + 1 + + diff --git "a/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/meetingRooms_alert&action/meetingRoomsTests/meetingRoomsTests.swift" "b/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/meetingRooms_alert&action/meetingRoomsTests/meetingRoomsTests.swift" new file mode 100644 index 0000000..bfbd8d6 --- /dev/null +++ "b/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/meetingRooms_alert&action/meetingRoomsTests/meetingRoomsTests.swift" @@ -0,0 +1,36 @@ +// +// meetingRoomsTests.swift +// meetingRoomsTests +// +// Created by 황도증 on 2017. 10. 30.. +// Copyright © 2017년 황도증. All rights reserved. +// + +import XCTest +@testable import meetingRooms + +class meetingRoomsTests: XCTestCase { + + override func setUp() { + super.setUp() + // Put setup code here. This method is called before the invocation of each test method in the class. + } + + override func tearDown() { + // Put teardown code here. This method is called after the invocation of each test method in the class. + super.tearDown() + } + + func testExample() { + // This is an example of a functional test case. + // Use XCTAssert and related functions to verify your tests produce the correct results. + } + + func testPerformanceExample() { + // This is an example of a performance test case. + self.measure { + // Put the code you want to measure the time of here. + } + } + +} diff --git "a/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/meetingRooms_alert&action/meetingRoomsUITests/Info.plist" "b/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/meetingRooms_alert&action/meetingRoomsUITests/Info.plist" new file mode 100644 index 0000000..6c40a6c --- /dev/null +++ "b/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/meetingRooms_alert&action/meetingRoomsUITests/Info.plist" @@ -0,0 +1,22 @@ + + + + + CFBundleDevelopmentRegion + $(DEVELOPMENT_LANGUAGE) + CFBundleExecutable + $(EXECUTABLE_NAME) + CFBundleIdentifier + $(PRODUCT_BUNDLE_IDENTIFIER) + CFBundleInfoDictionaryVersion + 6.0 + CFBundleName + $(PRODUCT_NAME) + CFBundlePackageType + BNDL + CFBundleShortVersionString + 1.0 + CFBundleVersion + 1 + + diff --git "a/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/meetingRooms_alert&action/meetingRoomsUITests/meetingRoomsUITests.swift" "b/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/meetingRooms_alert&action/meetingRoomsUITests/meetingRoomsUITests.swift" new file mode 100644 index 0000000..4873bfa --- /dev/null +++ "b/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/meetingRooms_alert&action/meetingRoomsUITests/meetingRoomsUITests.swift" @@ -0,0 +1,36 @@ +// +// meetingRoomsUITests.swift +// meetingRoomsUITests +// +// Created by 황도증 on 2017. 10. 30.. +// Copyright © 2017년 황도증. All rights reserved. +// + +import XCTest + +class meetingRoomsUITests: XCTestCase { + + override func setUp() { + super.setUp() + + // Put setup code here. This method is called before the invocation of each test method in the class. + + // In UI tests it is usually best to stop immediately when a failure occurs. + continueAfterFailure = false + // UI tests must launch the application that they test. Doing this in setup will make sure it happens for each test method. + XCUIApplication().launch() + + // In UI tests it’s important to set the initial state - such as interface orientation - required for your tests before they run. The setUp method is a good place to do this. + } + + override func tearDown() { + // Put teardown code here. This method is called after the invocation of each test method in the class. + super.tearDown() + } + + func testExample() { + // Use recording to get started writing UI tests. + // Use XCTAssert and related functions to verify your tests produce the correct results. + } + +} diff --git "a/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/meetingRooms_archive/meetingRooms.xcodeproj/project.pbxproj" "b/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/meetingRooms_archive/meetingRooms.xcodeproj/project.pbxproj" new file mode 100644 index 0000000..b4485a0 --- /dev/null +++ "b/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/meetingRooms_archive/meetingRooms.xcodeproj/project.pbxproj" @@ -0,0 +1,597 @@ +// !$*UTF8*$! +{ + archiveVersion = 1; + classes = { + }; + objectVersion = 48; + objects = { + +/* Begin PBXBuildFile section */ + AE99575B1FA704AF00397D38 /* AppDelegate.swift in Sources */ = {isa = PBXBuildFile; fileRef = AE99575A1FA704AF00397D38 /* AppDelegate.swift */; }; + AE99575D1FA704AF00397D38 /* ViewController.swift in Sources */ = {isa = PBXBuildFile; fileRef = AE99575C1FA704AF00397D38 /* ViewController.swift */; }; + AE9957601FA704AF00397D38 /* Main.storyboard in Resources */ = {isa = PBXBuildFile; fileRef = AE99575E1FA704AF00397D38 /* Main.storyboard */; }; + AE9957621FA704AF00397D38 /* Assets.xcassets in Resources */ = {isa = PBXBuildFile; fileRef = AE9957611FA704AF00397D38 /* Assets.xcassets */; }; + AE9957651FA704AF00397D38 /* LaunchScreen.storyboard in Resources */ = {isa = PBXBuildFile; fileRef = AE9957631FA704AF00397D38 /* LaunchScreen.storyboard */; }; + AE9957701FA704AF00397D38 /* meetingRoomsTests.swift in Sources */ = {isa = PBXBuildFile; fileRef = AE99576F1FA704AF00397D38 /* meetingRoomsTests.swift */; }; + AE99577B1FA704B000397D38 /* meetingRoomsUITests.swift in Sources */ = {isa = PBXBuildFile; fileRef = AE99577A1FA704B000397D38 /* meetingRoomsUITests.swift */; }; + AE9957891FA7054800397D38 /* MeetingRoomListViewController.swift in Sources */ = {isa = PBXBuildFile; fileRef = AE9957881FA7054800397D38 /* MeetingRoomListViewController.swift */; }; + AEB3189D1FB4641000AEB094 /* DataCenter.swift in Sources */ = {isa = PBXBuildFile; fileRef = AEB3189C1FB4641000AEB094 /* DataCenter.swift */; }; + AEB3189F1FB4684600AEB094 /* BranchListViewController.swift in Sources */ = {isa = PBXBuildFile; fileRef = AEB3189E1FB4684600AEB094 /* BranchListViewController.swift */; }; + AEB318A11FB4685800AEB094 /* ServiceListViewController.swift in Sources */ = {isa = PBXBuildFile; fileRef = AEB318A01FB4685800AEB094 /* ServiceListViewController.swift */; }; + AEB318A31FB4807F00AEB094 /* RoomInfoViewController.swift in Sources */ = {isa = PBXBuildFile; fileRef = AEB318A21FB4807F00AEB094 /* RoomInfoViewController.swift */; }; + AEB318A51FB485D300AEB094 /* ReservationListViewController.swift in Sources */ = {isa = PBXBuildFile; fileRef = AEB318A41FB485D300AEB094 /* ReservationListViewController.swift */; }; + AEB318A71FB4861600AEB094 /* ReserveRoomViewController.swift in Sources */ = {isa = PBXBuildFile; fileRef = AEB318A61FB4861600AEB094 /* ReserveRoomViewController.swift */; }; + AEB318A91FB4975F00AEB094 /* TintColorViewController.swift in Sources */ = {isa = PBXBuildFile; fileRef = AEB318A81FB4975F00AEB094 /* TintColorViewController.swift */; }; + AEB318AB1FB49D1900AEB094 /* EquipmentDefault.plist in Resources */ = {isa = PBXBuildFile; fileRef = AEB318AA1FB49D1900AEB094 /* EquipmentDefault.plist */; }; + AEB318AD1FB4C41A00AEB094 /* EquipmentsListViewController.swift in Sources */ = {isa = PBXBuildFile; fileRef = AEB318AC1FB4C41A00AEB094 /* EquipmentsListViewController.swift */; }; +/* End PBXBuildFile section */ + +/* Begin PBXContainerItemProxy section */ + AE99576C1FA704AF00397D38 /* PBXContainerItemProxy */ = { + isa = PBXContainerItemProxy; + containerPortal = AE99574F1FA704AF00397D38 /* Project object */; + proxyType = 1; + remoteGlobalIDString = AE9957561FA704AF00397D38; + remoteInfo = meetingRooms; + }; + AE9957771FA704B000397D38 /* PBXContainerItemProxy */ = { + isa = PBXContainerItemProxy; + containerPortal = AE99574F1FA704AF00397D38 /* Project object */; + proxyType = 1; + remoteGlobalIDString = AE9957561FA704AF00397D38; + remoteInfo = meetingRooms; + }; +/* End PBXContainerItemProxy section */ + +/* Begin PBXFileReference section */ + AE9957571FA704AF00397D38 /* meetingRooms.app */ = {isa = PBXFileReference; explicitFileType = wrapper.application; includeInIndex = 0; path = meetingRooms.app; sourceTree = BUILT_PRODUCTS_DIR; }; + AE99575A1FA704AF00397D38 /* AppDelegate.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = AppDelegate.swift; sourceTree = ""; }; + AE99575C1FA704AF00397D38 /* ViewController.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = ViewController.swift; sourceTree = ""; }; + AE99575F1FA704AF00397D38 /* Base */ = {isa = PBXFileReference; lastKnownFileType = file.storyboard; name = Base; path = Base.lproj/Main.storyboard; sourceTree = ""; }; + AE9957611FA704AF00397D38 /* Assets.xcassets */ = {isa = PBXFileReference; lastKnownFileType = folder.assetcatalog; path = Assets.xcassets; sourceTree = ""; }; + AE9957641FA704AF00397D38 /* Base */ = {isa = PBXFileReference; lastKnownFileType = file.storyboard; name = Base; path = Base.lproj/LaunchScreen.storyboard; sourceTree = ""; }; + AE9957661FA704AF00397D38 /* Info.plist */ = {isa = PBXFileReference; lastKnownFileType = text.plist.xml; path = Info.plist; sourceTree = ""; }; + AE99576B1FA704AF00397D38 /* meetingRoomsTests.xctest */ = {isa = PBXFileReference; explicitFileType = wrapper.cfbundle; includeInIndex = 0; path = meetingRoomsTests.xctest; sourceTree = BUILT_PRODUCTS_DIR; }; + AE99576F1FA704AF00397D38 /* meetingRoomsTests.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = meetingRoomsTests.swift; sourceTree = ""; }; + AE9957711FA704AF00397D38 /* Info.plist */ = {isa = PBXFileReference; lastKnownFileType = text.plist.xml; path = Info.plist; sourceTree = ""; }; + AE9957761FA704B000397D38 /* meetingRoomsUITests.xctest */ = {isa = PBXFileReference; explicitFileType = wrapper.cfbundle; includeInIndex = 0; path = meetingRoomsUITests.xctest; sourceTree = BUILT_PRODUCTS_DIR; }; + AE99577A1FA704B000397D38 /* meetingRoomsUITests.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = meetingRoomsUITests.swift; sourceTree = ""; }; + AE99577C1FA704B000397D38 /* Info.plist */ = {isa = PBXFileReference; lastKnownFileType = text.plist.xml; path = Info.plist; sourceTree = ""; }; + AE9957881FA7054800397D38 /* MeetingRoomListViewController.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = MeetingRoomListViewController.swift; sourceTree = ""; }; + AEB3189C1FB4641000AEB094 /* DataCenter.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = DataCenter.swift; sourceTree = ""; }; + AEB3189E1FB4684600AEB094 /* BranchListViewController.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = BranchListViewController.swift; sourceTree = ""; }; + AEB318A01FB4685800AEB094 /* ServiceListViewController.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = ServiceListViewController.swift; sourceTree = ""; }; + AEB318A21FB4807F00AEB094 /* RoomInfoViewController.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = RoomInfoViewController.swift; sourceTree = ""; }; + AEB318A41FB485D300AEB094 /* ReservationListViewController.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = ReservationListViewController.swift; sourceTree = ""; }; + AEB318A61FB4861600AEB094 /* ReserveRoomViewController.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = ReserveRoomViewController.swift; sourceTree = ""; }; + AEB318A81FB4975F00AEB094 /* TintColorViewController.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = TintColorViewController.swift; sourceTree = ""; }; + AEB318AA1FB49D1900AEB094 /* EquipmentDefault.plist */ = {isa = PBXFileReference; lastKnownFileType = text.plist.xml; path = EquipmentDefault.plist; sourceTree = ""; }; + AEB318AC1FB4C41A00AEB094 /* EquipmentsListViewController.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = EquipmentsListViewController.swift; sourceTree = ""; }; +/* End PBXFileReference section */ + +/* Begin PBXFrameworksBuildPhase section */ + AE9957541FA704AF00397D38 /* Frameworks */ = { + isa = PBXFrameworksBuildPhase; + buildActionMask = 2147483647; + files = ( + ); + runOnlyForDeploymentPostprocessing = 0; + }; + AE9957681FA704AF00397D38 /* Frameworks */ = { + isa = PBXFrameworksBuildPhase; + buildActionMask = 2147483647; + files = ( + ); + runOnlyForDeploymentPostprocessing = 0; + }; + AE9957731FA704B000397D38 /* Frameworks */ = { + isa = PBXFrameworksBuildPhase; + buildActionMask = 2147483647; + files = ( + ); + runOnlyForDeploymentPostprocessing = 0; + }; +/* End PBXFrameworksBuildPhase section */ + +/* Begin PBXGroup section */ + AE99574E1FA704AF00397D38 = { + isa = PBXGroup; + children = ( + AE9957591FA704AF00397D38 /* meetingRooms */, + AE99576E1FA704AF00397D38 /* meetingRoomsTests */, + AE9957791FA704B000397D38 /* meetingRoomsUITests */, + AE9957581FA704AF00397D38 /* Products */, + ); + sourceTree = ""; + }; + AE9957581FA704AF00397D38 /* Products */ = { + isa = PBXGroup; + children = ( + AE9957571FA704AF00397D38 /* meetingRooms.app */, + AE99576B1FA704AF00397D38 /* meetingRoomsTests.xctest */, + AE9957761FA704B000397D38 /* meetingRoomsUITests.xctest */, + ); + name = Products; + sourceTree = ""; + }; + AE9957591FA704AF00397D38 /* meetingRooms */ = { + isa = PBXGroup; + children = ( + AE99575A1FA704AF00397D38 /* AppDelegate.swift */, + AEB318AA1FB49D1900AEB094 /* EquipmentDefault.plist */, + AEB318AC1FB4C41A00AEB094 /* EquipmentsListViewController.swift */, + AE99575C1FA704AF00397D38 /* ViewController.swift */, + AE99575E1FA704AF00397D38 /* Main.storyboard */, + AEB318A81FB4975F00AEB094 /* TintColorViewController.swift */, + AEB318A61FB4861600AEB094 /* ReserveRoomViewController.swift */, + AEB318A41FB485D300AEB094 /* ReservationListViewController.swift */, + AEB318A21FB4807F00AEB094 /* RoomInfoViewController.swift */, + AEB3189C1FB4641000AEB094 /* DataCenter.swift */, + AEB3189E1FB4684600AEB094 /* BranchListViewController.swift */, + AEB318A01FB4685800AEB094 /* ServiceListViewController.swift */, + AE9957881FA7054800397D38 /* MeetingRoomListViewController.swift */, + AE9957611FA704AF00397D38 /* Assets.xcassets */, + AE9957631FA704AF00397D38 /* LaunchScreen.storyboard */, + AE9957661FA704AF00397D38 /* Info.plist */, + ); + path = meetingRooms; + sourceTree = ""; + }; + AE99576E1FA704AF00397D38 /* meetingRoomsTests */ = { + isa = PBXGroup; + children = ( + AE99576F1FA704AF00397D38 /* meetingRoomsTests.swift */, + AE9957711FA704AF00397D38 /* Info.plist */, + ); + path = meetingRoomsTests; + sourceTree = ""; + }; + AE9957791FA704B000397D38 /* meetingRoomsUITests */ = { + isa = PBXGroup; + children = ( + AE99577A1FA704B000397D38 /* meetingRoomsUITests.swift */, + AE99577C1FA704B000397D38 /* Info.plist */, + ); + path = meetingRoomsUITests; + sourceTree = ""; + }; +/* End PBXGroup section */ + +/* Begin PBXNativeTarget section */ + AE9957561FA704AF00397D38 /* meetingRooms */ = { + isa = PBXNativeTarget; + buildConfigurationList = AE99577F1FA704B000397D38 /* Build configuration list for PBXNativeTarget "meetingRooms" */; + buildPhases = ( + AE9957531FA704AF00397D38 /* Sources */, + AE9957541FA704AF00397D38 /* Frameworks */, + AE9957551FA704AF00397D38 /* Resources */, + ); + buildRules = ( + ); + dependencies = ( + ); + name = meetingRooms; + productName = meetingRooms; + productReference = AE9957571FA704AF00397D38 /* meetingRooms.app */; + productType = "com.apple.product-type.application"; + }; + AE99576A1FA704AF00397D38 /* meetingRoomsTests */ = { + isa = PBXNativeTarget; + buildConfigurationList = AE9957821FA704B000397D38 /* Build configuration list for PBXNativeTarget "meetingRoomsTests" */; + buildPhases = ( + AE9957671FA704AF00397D38 /* Sources */, + AE9957681FA704AF00397D38 /* Frameworks */, + AE9957691FA704AF00397D38 /* Resources */, + ); + buildRules = ( + ); + dependencies = ( + AE99576D1FA704AF00397D38 /* PBXTargetDependency */, + ); + name = meetingRoomsTests; + productName = meetingRoomsTests; + productReference = AE99576B1FA704AF00397D38 /* meetingRoomsTests.xctest */; + productType = "com.apple.product-type.bundle.unit-test"; + }; + AE9957751FA704B000397D38 /* meetingRoomsUITests */ = { + isa = PBXNativeTarget; + buildConfigurationList = AE9957851FA704B000397D38 /* Build configuration list for PBXNativeTarget "meetingRoomsUITests" */; + buildPhases = ( + AE9957721FA704B000397D38 /* Sources */, + AE9957731FA704B000397D38 /* Frameworks */, + AE9957741FA704B000397D38 /* Resources */, + ); + buildRules = ( + ); + dependencies = ( + AE9957781FA704B000397D38 /* PBXTargetDependency */, + ); + name = meetingRoomsUITests; + productName = meetingRoomsUITests; + productReference = AE9957761FA704B000397D38 /* meetingRoomsUITests.xctest */; + productType = "com.apple.product-type.bundle.ui-testing"; + }; +/* End PBXNativeTarget section */ + +/* Begin PBXProject section */ + AE99574F1FA704AF00397D38 /* Project object */ = { + isa = PBXProject; + attributes = { + LastSwiftUpdateCheck = 0900; + LastUpgradeCheck = 0900; + ORGANIZATIONNAME = "황도증"; + TargetAttributes = { + AE9957561FA704AF00397D38 = { + CreatedOnToolsVersion = 9.0.1; + ProvisioningStyle = Automatic; + }; + AE99576A1FA704AF00397D38 = { + CreatedOnToolsVersion = 9.0.1; + ProvisioningStyle = Automatic; + TestTargetID = AE9957561FA704AF00397D38; + }; + AE9957751FA704B000397D38 = { + CreatedOnToolsVersion = 9.0.1; + ProvisioningStyle = Automatic; + TestTargetID = AE9957561FA704AF00397D38; + }; + }; + }; + buildConfigurationList = AE9957521FA704AF00397D38 /* Build configuration list for PBXProject "meetingRooms" */; + compatibilityVersion = "Xcode 8.0"; + developmentRegion = en; + hasScannedForEncodings = 0; + knownRegions = ( + en, + Base, + ); + mainGroup = AE99574E1FA704AF00397D38; + productRefGroup = AE9957581FA704AF00397D38 /* Products */; + projectDirPath = ""; + projectRoot = ""; + targets = ( + AE9957561FA704AF00397D38 /* meetingRooms */, + AE99576A1FA704AF00397D38 /* meetingRoomsTests */, + AE9957751FA704B000397D38 /* meetingRoomsUITests */, + ); + }; +/* End PBXProject section */ + +/* Begin PBXResourcesBuildPhase section */ + AE9957551FA704AF00397D38 /* Resources */ = { + isa = PBXResourcesBuildPhase; + buildActionMask = 2147483647; + files = ( + AE9957651FA704AF00397D38 /* LaunchScreen.storyboard in Resources */, + AEB318AB1FB49D1900AEB094 /* EquipmentDefault.plist in Resources */, + AE9957621FA704AF00397D38 /* Assets.xcassets in Resources */, + AE9957601FA704AF00397D38 /* Main.storyboard in Resources */, + ); + runOnlyForDeploymentPostprocessing = 0; + }; + AE9957691FA704AF00397D38 /* Resources */ = { + isa = PBXResourcesBuildPhase; + buildActionMask = 2147483647; + files = ( + ); + runOnlyForDeploymentPostprocessing = 0; + }; + AE9957741FA704B000397D38 /* Resources */ = { + isa = PBXResourcesBuildPhase; + buildActionMask = 2147483647; + files = ( + ); + runOnlyForDeploymentPostprocessing = 0; + }; +/* End PBXResourcesBuildPhase section */ + +/* Begin PBXSourcesBuildPhase section */ + AE9957531FA704AF00397D38 /* Sources */ = { + isa = PBXSourcesBuildPhase; + buildActionMask = 2147483647; + files = ( + AEB318A31FB4807F00AEB094 /* RoomInfoViewController.swift in Sources */, + AE99575D1FA704AF00397D38 /* ViewController.swift in Sources */, + AE99575B1FA704AF00397D38 /* AppDelegate.swift in Sources */, + AEB318AD1FB4C41A00AEB094 /* EquipmentsListViewController.swift in Sources */, + AEB318A51FB485D300AEB094 /* ReservationListViewController.swift in Sources */, + AEB3189D1FB4641000AEB094 /* DataCenter.swift in Sources */, + AEB3189F1FB4684600AEB094 /* BranchListViewController.swift in Sources */, + AEB318A11FB4685800AEB094 /* ServiceListViewController.swift in Sources */, + AE9957891FA7054800397D38 /* MeetingRoomListViewController.swift in Sources */, + AEB318A71FB4861600AEB094 /* ReserveRoomViewController.swift in Sources */, + AEB318A91FB4975F00AEB094 /* TintColorViewController.swift in Sources */, + ); + runOnlyForDeploymentPostprocessing = 0; + }; + AE9957671FA704AF00397D38 /* Sources */ = { + isa = PBXSourcesBuildPhase; + buildActionMask = 2147483647; + files = ( + AE9957701FA704AF00397D38 /* meetingRoomsTests.swift in Sources */, + ); + runOnlyForDeploymentPostprocessing = 0; + }; + AE9957721FA704B000397D38 /* Sources */ = { + isa = PBXSourcesBuildPhase; + buildActionMask = 2147483647; + files = ( + AE99577B1FA704B000397D38 /* meetingRoomsUITests.swift in Sources */, + ); + runOnlyForDeploymentPostprocessing = 0; + }; +/* End PBXSourcesBuildPhase section */ + +/* Begin PBXTargetDependency section */ + AE99576D1FA704AF00397D38 /* PBXTargetDependency */ = { + isa = PBXTargetDependency; + target = AE9957561FA704AF00397D38 /* meetingRooms */; + targetProxy = AE99576C1FA704AF00397D38 /* PBXContainerItemProxy */; + }; + AE9957781FA704B000397D38 /* PBXTargetDependency */ = { + isa = PBXTargetDependency; + target = AE9957561FA704AF00397D38 /* meetingRooms */; + targetProxy = AE9957771FA704B000397D38 /* PBXContainerItemProxy */; + }; +/* End PBXTargetDependency section */ + +/* Begin PBXVariantGroup section */ + AE99575E1FA704AF00397D38 /* Main.storyboard */ = { + isa = PBXVariantGroup; + children = ( + AE99575F1FA704AF00397D38 /* Base */, + ); + name = Main.storyboard; + sourceTree = ""; + }; + AE9957631FA704AF00397D38 /* LaunchScreen.storyboard */ = { + isa = PBXVariantGroup; + children = ( + AE9957641FA704AF00397D38 /* Base */, + ); + name = LaunchScreen.storyboard; + sourceTree = ""; + }; +/* End PBXVariantGroup section */ + +/* Begin XCBuildConfiguration section */ + AE99577D1FA704B000397D38 /* Debug */ = { + isa = XCBuildConfiguration; + buildSettings = { + ALWAYS_SEARCH_USER_PATHS = NO; + CLANG_ANALYZER_NONNULL = YES; + CLANG_ANALYZER_NUMBER_OBJECT_CONVERSION = YES_AGGRESSIVE; + CLANG_CXX_LANGUAGE_STANDARD = "gnu++14"; + CLANG_CXX_LIBRARY = "libc++"; + CLANG_ENABLE_MODULES = YES; + CLANG_ENABLE_OBJC_ARC = YES; + CLANG_WARN_BLOCK_CAPTURE_AUTORELEASING = YES; + CLANG_WARN_BOOL_CONVERSION = YES; + CLANG_WARN_COMMA = YES; + CLANG_WARN_CONSTANT_CONVERSION = YES; + CLANG_WARN_DIRECT_OBJC_ISA_USAGE = YES_ERROR; + CLANG_WARN_DOCUMENTATION_COMMENTS = YES; + CLANG_WARN_EMPTY_BODY = YES; + CLANG_WARN_ENUM_CONVERSION = YES; + CLANG_WARN_INFINITE_RECURSION = YES; + CLANG_WARN_INT_CONVERSION = YES; + CLANG_WARN_NON_LITERAL_NULL_CONVERSION = YES; + CLANG_WARN_OBJC_LITERAL_CONVERSION = YES; + CLANG_WARN_OBJC_ROOT_CLASS = YES_ERROR; + CLANG_WARN_RANGE_LOOP_ANALYSIS = YES; + CLANG_WARN_STRICT_PROTOTYPES = YES; + CLANG_WARN_SUSPICIOUS_MOVE = YES; + CLANG_WARN_UNGUARDED_AVAILABILITY = YES_AGGRESSIVE; + CLANG_WARN_UNREACHABLE_CODE = YES; + CLANG_WARN__DUPLICATE_METHOD_MATCH = YES; + CODE_SIGN_IDENTITY = "iPhone Developer"; + COPY_PHASE_STRIP = NO; + DEBUG_INFORMATION_FORMAT = dwarf; + ENABLE_STRICT_OBJC_MSGSEND = YES; + ENABLE_TESTABILITY = YES; + GCC_C_LANGUAGE_STANDARD = gnu11; + GCC_DYNAMIC_NO_PIC = NO; + GCC_NO_COMMON_BLOCKS = YES; + GCC_OPTIMIZATION_LEVEL = 0; + GCC_PREPROCESSOR_DEFINITIONS = ( + "DEBUG=1", + "$(inherited)", + ); + GCC_WARN_64_TO_32_BIT_CONVERSION = YES; + GCC_WARN_ABOUT_RETURN_TYPE = YES_ERROR; + GCC_WARN_UNDECLARED_SELECTOR = YES; + GCC_WARN_UNINITIALIZED_AUTOS = YES_AGGRESSIVE; + GCC_WARN_UNUSED_FUNCTION = YES; + GCC_WARN_UNUSED_VARIABLE = YES; + IPHONEOS_DEPLOYMENT_TARGET = 11.0; + MTL_ENABLE_DEBUG_INFO = YES; + ONLY_ACTIVE_ARCH = YES; + SDKROOT = iphoneos; + SWIFT_ACTIVE_COMPILATION_CONDITIONS = DEBUG; + SWIFT_OPTIMIZATION_LEVEL = "-Onone"; + }; + name = Debug; + }; + AE99577E1FA704B000397D38 /* Release */ = { + isa = XCBuildConfiguration; + buildSettings = { + ALWAYS_SEARCH_USER_PATHS = NO; + CLANG_ANALYZER_NONNULL = YES; + CLANG_ANALYZER_NUMBER_OBJECT_CONVERSION = YES_AGGRESSIVE; + CLANG_CXX_LANGUAGE_STANDARD = "gnu++14"; + CLANG_CXX_LIBRARY = "libc++"; + CLANG_ENABLE_MODULES = YES; + CLANG_ENABLE_OBJC_ARC = YES; + CLANG_WARN_BLOCK_CAPTURE_AUTORELEASING = YES; + CLANG_WARN_BOOL_CONVERSION = YES; + CLANG_WARN_COMMA = YES; + CLANG_WARN_CONSTANT_CONVERSION = YES; + CLANG_WARN_DIRECT_OBJC_ISA_USAGE = YES_ERROR; + CLANG_WARN_DOCUMENTATION_COMMENTS = YES; + CLANG_WARN_EMPTY_BODY = YES; + CLANG_WARN_ENUM_CONVERSION = YES; + CLANG_WARN_INFINITE_RECURSION = YES; + CLANG_WARN_INT_CONVERSION = YES; + CLANG_WARN_NON_LITERAL_NULL_CONVERSION = YES; + CLANG_WARN_OBJC_LITERAL_CONVERSION = YES; + CLANG_WARN_OBJC_ROOT_CLASS = YES_ERROR; + CLANG_WARN_RANGE_LOOP_ANALYSIS = YES; + CLANG_WARN_STRICT_PROTOTYPES = YES; + CLANG_WARN_SUSPICIOUS_MOVE = YES; + CLANG_WARN_UNGUARDED_AVAILABILITY = YES_AGGRESSIVE; + CLANG_WARN_UNREACHABLE_CODE = YES; + CLANG_WARN__DUPLICATE_METHOD_MATCH = YES; + CODE_SIGN_IDENTITY = "iPhone Developer"; + COPY_PHASE_STRIP = NO; + DEBUG_INFORMATION_FORMAT = "dwarf-with-dsym"; + ENABLE_NS_ASSERTIONS = NO; + ENABLE_STRICT_OBJC_MSGSEND = YES; + GCC_C_LANGUAGE_STANDARD = gnu11; + GCC_NO_COMMON_BLOCKS = YES; + GCC_WARN_64_TO_32_BIT_CONVERSION = YES; + GCC_WARN_ABOUT_RETURN_TYPE = YES_ERROR; + GCC_WARN_UNDECLARED_SELECTOR = YES; + GCC_WARN_UNINITIALIZED_AUTOS = YES_AGGRESSIVE; + GCC_WARN_UNUSED_FUNCTION = YES; + GCC_WARN_UNUSED_VARIABLE = YES; + IPHONEOS_DEPLOYMENT_TARGET = 11.0; + MTL_ENABLE_DEBUG_INFO = NO; + SDKROOT = iphoneos; + SWIFT_OPTIMIZATION_LEVEL = "-Owholemodule"; + VALIDATE_PRODUCT = YES; + }; + name = Release; + }; + AE9957801FA704B000397D38 /* Debug */ = { + isa = XCBuildConfiguration; + buildSettings = { + ASSETCATALOG_COMPILER_APPICON_NAME = AppIcon; + CODE_SIGN_STYLE = Automatic; + INFOPLIST_FILE = meetingRooms/Info.plist; + LD_RUNPATH_SEARCH_PATHS = "$(inherited) @executable_path/Frameworks"; + PRODUCT_BUNDLE_IDENTIFIER = "--------.meetingRooms"; + PRODUCT_NAME = "$(TARGET_NAME)"; + SWIFT_VERSION = 4.0; + TARGETED_DEVICE_FAMILY = "1,2"; + }; + name = Debug; + }; + AE9957811FA704B000397D38 /* Release */ = { + isa = XCBuildConfiguration; + buildSettings = { + ASSETCATALOG_COMPILER_APPICON_NAME = AppIcon; + CODE_SIGN_STYLE = Automatic; + INFOPLIST_FILE = meetingRooms/Info.plist; + LD_RUNPATH_SEARCH_PATHS = "$(inherited) @executable_path/Frameworks"; + PRODUCT_BUNDLE_IDENTIFIER = "--------.meetingRooms"; + PRODUCT_NAME = "$(TARGET_NAME)"; + SWIFT_VERSION = 4.0; + TARGETED_DEVICE_FAMILY = "1,2"; + }; + name = Release; + }; + AE9957831FA704B000397D38 /* Debug */ = { + isa = XCBuildConfiguration; + buildSettings = { + ALWAYS_EMBED_SWIFT_STANDARD_LIBRARIES = YES; + BUNDLE_LOADER = "$(TEST_HOST)"; + CODE_SIGN_STYLE = Automatic; + INFOPLIST_FILE = meetingRoomsTests/Info.plist; + LD_RUNPATH_SEARCH_PATHS = "$(inherited) @executable_path/Frameworks @loader_path/Frameworks"; + PRODUCT_BUNDLE_IDENTIFIER = "--------.meetingRoomsTests"; + PRODUCT_NAME = "$(TARGET_NAME)"; + SWIFT_VERSION = 4.0; + TARGETED_DEVICE_FAMILY = "1,2"; + TEST_HOST = "$(BUILT_PRODUCTS_DIR)/meetingRooms.app/meetingRooms"; + }; + name = Debug; + }; + AE9957841FA704B000397D38 /* Release */ = { + isa = XCBuildConfiguration; + buildSettings = { + ALWAYS_EMBED_SWIFT_STANDARD_LIBRARIES = YES; + BUNDLE_LOADER = "$(TEST_HOST)"; + CODE_SIGN_STYLE = Automatic; + INFOPLIST_FILE = meetingRoomsTests/Info.plist; + LD_RUNPATH_SEARCH_PATHS = "$(inherited) @executable_path/Frameworks @loader_path/Frameworks"; + PRODUCT_BUNDLE_IDENTIFIER = "--------.meetingRoomsTests"; + PRODUCT_NAME = "$(TARGET_NAME)"; + SWIFT_VERSION = 4.0; + TARGETED_DEVICE_FAMILY = "1,2"; + TEST_HOST = "$(BUILT_PRODUCTS_DIR)/meetingRooms.app/meetingRooms"; + }; + name = Release; + }; + AE9957861FA704B000397D38 /* Debug */ = { + isa = XCBuildConfiguration; + buildSettings = { + ALWAYS_EMBED_SWIFT_STANDARD_LIBRARIES = YES; + CODE_SIGN_STYLE = Automatic; + INFOPLIST_FILE = meetingRoomsUITests/Info.plist; + LD_RUNPATH_SEARCH_PATHS = "$(inherited) @executable_path/Frameworks @loader_path/Frameworks"; + PRODUCT_BUNDLE_IDENTIFIER = "--------.meetingRoomsUITests"; + PRODUCT_NAME = "$(TARGET_NAME)"; + SWIFT_VERSION = 4.0; + TARGETED_DEVICE_FAMILY = "1,2"; + TEST_TARGET_NAME = meetingRooms; + }; + name = Debug; + }; + AE9957871FA704B000397D38 /* Release */ = { + isa = XCBuildConfiguration; + buildSettings = { + ALWAYS_EMBED_SWIFT_STANDARD_LIBRARIES = YES; + CODE_SIGN_STYLE = Automatic; + INFOPLIST_FILE = meetingRoomsUITests/Info.plist; + LD_RUNPATH_SEARCH_PATHS = "$(inherited) @executable_path/Frameworks @loader_path/Frameworks"; + PRODUCT_BUNDLE_IDENTIFIER = "--------.meetingRoomsUITests"; + PRODUCT_NAME = "$(TARGET_NAME)"; + SWIFT_VERSION = 4.0; + TARGETED_DEVICE_FAMILY = "1,2"; + TEST_TARGET_NAME = meetingRooms; + }; + name = Release; + }; +/* End XCBuildConfiguration section */ + +/* Begin XCConfigurationList section */ + AE9957521FA704AF00397D38 /* Build configuration list for PBXProject "meetingRooms" */ = { + isa = XCConfigurationList; + buildConfigurations = ( + AE99577D1FA704B000397D38 /* Debug */, + AE99577E1FA704B000397D38 /* Release */, + ); + defaultConfigurationIsVisible = 0; + defaultConfigurationName = Release; + }; + AE99577F1FA704B000397D38 /* Build configuration list for PBXNativeTarget "meetingRooms" */ = { + isa = XCConfigurationList; + buildConfigurations = ( + AE9957801FA704B000397D38 /* Debug */, + AE9957811FA704B000397D38 /* Release */, + ); + defaultConfigurationIsVisible = 0; + defaultConfigurationName = Release; + }; + AE9957821FA704B000397D38 /* Build configuration list for PBXNativeTarget "meetingRoomsTests" */ = { + isa = XCConfigurationList; + buildConfigurations = ( + AE9957831FA704B000397D38 /* Debug */, + AE9957841FA704B000397D38 /* Release */, + ); + defaultConfigurationIsVisible = 0; + defaultConfigurationName = Release; + }; + AE9957851FA704B000397D38 /* Build configuration list for PBXNativeTarget "meetingRoomsUITests" */ = { + isa = XCConfigurationList; + buildConfigurations = ( + AE9957861FA704B000397D38 /* Debug */, + AE9957871FA704B000397D38 /* Release */, + ); + defaultConfigurationIsVisible = 0; + defaultConfigurationName = Release; + }; +/* End XCConfigurationList section */ + }; + rootObject = AE99574F1FA704AF00397D38 /* Project object */; +} diff --git "a/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/meetingRooms_archive/meetingRooms.xcodeproj/project.xcworkspace/contents.xcworkspacedata" "b/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/meetingRooms_archive/meetingRooms.xcodeproj/project.xcworkspace/contents.xcworkspacedata" new file mode 100644 index 0000000..8491799 --- /dev/null +++ "b/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/meetingRooms_archive/meetingRooms.xcodeproj/project.xcworkspace/contents.xcworkspacedata" @@ -0,0 +1,7 @@ + + + + + diff --git "a/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/meetingRooms_archive/meetingRooms/AppDelegate.swift" "b/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/meetingRooms_archive/meetingRooms/AppDelegate.swift" new file mode 100644 index 0000000..eb06959 --- /dev/null +++ "b/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/meetingRooms_archive/meetingRooms/AppDelegate.swift" @@ -0,0 +1,52 @@ +// +// AppDelegate.swift +// meetingRooms +// +// Created by 황도증 on 2017. 10. 30.. +// Copyright © 2017년 황도증. All rights reserved. +// + +import UIKit + +@UIApplicationMain +class AppDelegate: UIResponder, UIApplicationDelegate { + + var window: UIWindow? + + func application(_ application: UIApplication, didFinishLaunchingWithOptions launchOptions: [UIApplicationLaunchOptionsKey: Any]?) -> Bool { + // Override point for customization after application launch. + return true + } + + func applicationWillResignActive(_ application: UIApplication) { + // Sent when the application is about to move from active to inactive state. This can occur for certain types of temporary interruptions (such as an incoming phone call or SMS message) or when the user quits the application and it begins the transition to the background state. + // Use this method to pause ongoing tasks, disable timers, and invalidate graphics rendering callbacks. Games should use this method to pause the game. + } + + func applicationDidEnterBackground(_ application: UIApplication) { + // Use this method to release shared resources, save user data, invalidate timers, and store enough application state information to restore your application to its current state in case it is terminated later. + // If your application supports background execution, this method is called instead of applicationWillTerminate: when the user quits. + dataCenter.save() + } + + func applicationWillEnterForeground(_ application: UIApplication) { + // Called as part of the transition from the background to the active state; here you can undo many of the changes made on entering the background. + } + + func applicationDidBecomeActive(_ application: UIApplication) { + // Restart any tasks that were paused (or not yet started) while the application was inactive. If the application was previously in the background, optionally refresh the user interface. + let userDefaultColor = UserDefaults.standard.integer(forKey: TintColorKey) + guard let defaultColor = TintColor(rawValue: userDefaultColor)?.color else { + return + } + applyTintColor(color: defaultColor) + } + + func applicationWillTerminate(_ application: UIApplication) { + // Called when the application is about to terminate. Save data if appropriate. See also applicationDidEnterBackground:. + dataCenter.save() + } + + +} + diff --git "a/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/meetingRooms_archive/meetingRooms/Assets.xcassets/AppIcon.appiconset/Contents.json" "b/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/meetingRooms_archive/meetingRooms/Assets.xcassets/AppIcon.appiconset/Contents.json" new file mode 100644 index 0000000..d8db8d6 --- /dev/null +++ "b/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/meetingRooms_archive/meetingRooms/Assets.xcassets/AppIcon.appiconset/Contents.json" @@ -0,0 +1,98 @@ +{ + "images" : [ + { + "idiom" : "iphone", + "size" : "20x20", + "scale" : "2x" + }, + { + "idiom" : "iphone", + "size" : "20x20", + "scale" : "3x" + }, + { + "idiom" : "iphone", + "size" : "29x29", + "scale" : "2x" + }, + { + "idiom" : "iphone", + "size" : "29x29", + "scale" : "3x" + }, + { + "idiom" : "iphone", + "size" : "40x40", + "scale" : "2x" + }, + { + "idiom" : "iphone", + "size" : "40x40", + "scale" : "3x" + }, + { + "idiom" : "iphone", + "size" : "60x60", + "scale" : "2x" + }, + { + "idiom" : "iphone", + "size" : "60x60", + "scale" : "3x" + }, + { + "idiom" : "ipad", + "size" : "20x20", + "scale" : "1x" + }, + { + "idiom" : "ipad", + "size" : "20x20", + "scale" : "2x" + }, + { + "idiom" : "ipad", + "size" : "29x29", + "scale" : "1x" + }, + { + "idiom" : "ipad", + "size" : "29x29", + "scale" : "2x" + }, + { + "idiom" : "ipad", + "size" : "40x40", + "scale" : "1x" + }, + { + "idiom" : "ipad", + "size" : "40x40", + "scale" : "2x" + }, + { + "idiom" : "ipad", + "size" : "76x76", + "scale" : "1x" + }, + { + "idiom" : "ipad", + "size" : "76x76", + "scale" : "2x" + }, + { + "idiom" : "ipad", + "size" : "83.5x83.5", + "scale" : "2x" + }, + { + "idiom" : "ios-marketing", + "size" : "1024x1024", + "scale" : "1x" + } + ], + "info" : { + "version" : 1, + "author" : "xcode" + } +} \ No newline at end of file diff --git "a/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/meetingRooms_archive/meetingRooms/Base.lproj/LaunchScreen.storyboard" "b/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/meetingRooms_archive/meetingRooms/Base.lproj/LaunchScreen.storyboard" new file mode 100644 index 0000000..f83f6fd --- /dev/null +++ "b/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/meetingRooms_archive/meetingRooms/Base.lproj/LaunchScreen.storyboard" @@ -0,0 +1,25 @@ + + + + + + + + + + + + + + + + + + + + + + + + + diff --git "a/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/meetingRooms_archive/meetingRooms/Base.lproj/Main.storyboard" "b/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/meetingRooms_archive/meetingRooms/Base.lproj/Main.storyboard" new file mode 100644 index 0000000..639f10e --- /dev/null +++ "b/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/meetingRooms_archive/meetingRooms/Base.lproj/Main.storyboard" @@ -0,0 +1,632 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + diff --git "a/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/meetingRooms_archive/meetingRooms/BranchListViewController.swift" "b/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/meetingRooms_archive/meetingRooms/BranchListViewController.swift" new file mode 100644 index 0000000..fa28525 --- /dev/null +++ "b/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/meetingRooms_archive/meetingRooms/BranchListViewController.swift" @@ -0,0 +1,119 @@ +// +// BranchListViewController.swift +// meetingRooms +// +// Created by 황도증 on 2017. 11. 9.. +// Copyright © 2017년 황도증. All rights reserved. +// + +import UIKit + +class BranchListViewController: UITableViewController { + + override func viewDidLoad() { + super.viewDidLoad() + + // Uncomment the following line to preserve selection between presentations + // self.clearsSelectionOnViewWillAppear = false + + // Uncomment the following line to display an Edit button in the navigation bar for this view controller. + // self.navigationItem.rightBarButtonItem = self.editButtonItem + + self.navigationController?.isToolbarHidden = true + } + + override func didReceiveMemoryWarning() { + super.didReceiveMemoryWarning() + // Dispose of any resources that can be recreated. + } + + // MARK: - Table view data source + + override func numberOfSections(in tableView: UITableView) -> Int { + // #warning Incomplete implementation, return the number of sections + return 1 + } + + @IBAction func locationTurnOn(_ sender: Any) { + let locationAlert = UIAlertController(title:"위치정보요청", message: "위치정보를 기반으로 가까운 지점을 자동으로 선택할 수 있습니다.", preferredStyle: .actionSheet) + + let locationAction = UIAlertAction(title: "위치정보켜기", style: .default, handler: {(action:UIAlertAction) -> Void in print("위치정보켜기 선택")}) + + let openMapAction = UIAlertAction(title: "지도에서 열기", style: .default, handler: {(action:UIAlertAction) -> Void in print("지도앱에서 열기 선택")}) + + locationAlert.addAction(locationAction) + locationAlert.addAction(openMapAction) + + self.present(locationAlert, animated: true, completion: nil) + } + override func tableView(_ tableView: UITableView, numberOfRowsInSection section: Int) -> Int { + // #warning Incomplete implementation, return the number of rows + let rowCount = dataCenter.branches.count + return rowCount + } + + + override func tableView(_ tableView: UITableView, cellForRowAt indexPath: IndexPath) -> UITableViewCell { + let cell = tableView.dequeueReusableCell(withIdentifier: "BranchCell", for: indexPath) + + // Configure the cell... + let branch = dataCenter.branches[indexPath.row] + cell.textLabel?.text = branch.name + + return cell + } + + + /* + // Override to support conditional editing of the table view. + override func tableView(_ tableView: UITableView, canEditRowAt indexPath: IndexPath) -> Bool { + // Return false if you do not want the specified item to be editable. + return true + } + */ + + /* + // Override to support editing the table view. + override func tableView(_ tableView: UITableView, commit editingStyle: UITableViewCellEditingStyle, forRowAt indexPath: IndexPath) { + if editingStyle == .delete { + // Delete the row from the data source + tableView.deleteRows(at: [indexPath], with: .fade) + } else if editingStyle == .insert { + // Create a new instance of the appropriate class, insert it into the array, and add a new row to the table view + } + } + */ + + /* + // Override to support rearranging the table view. + override func tableView(_ tableView: UITableView, moveRowAt fromIndexPath: IndexPath, to: IndexPath) { + + } + */ + + /* + // Override to support conditional rearranging of the table view. + override func tableView(_ tableView: UITableView, canMoveRowAt indexPath: IndexPath) -> Bool { + // Return false if you do not want the item to be re-orderable. + return true + } + */ + + + // MARK: - Navigation + + // In a storyboard-based application, you will often want to do a little preparation before navigation + override func prepare(for segue: UIStoryboardSegue, sender: Any?) { + // Get the new view controller using segue.destinationViewController. + // Pass the selected object to the new view controller. + + if segue.identifier == "ServiceSegue" { + if let destination = segue.destination as? ServiceListViewController { + if let selectedIndex = self.tableView.indexPathForSelectedRow?.row { + destination.branch = dataCenter.branches[selectedIndex] as Branch + } + } + } + + } +} diff --git "a/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/meetingRooms_archive/meetingRooms/DataCenter.swift" "b/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/meetingRooms_archive/meetingRooms/DataCenter.swift" new file mode 100644 index 0000000..ea62bf8 --- /dev/null +++ "b/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/meetingRooms_archive/meetingRooms/DataCenter.swift" @@ -0,0 +1,154 @@ +// +// DataCenter.swift +// meetingRooms +// +// Created by 황도증 on 2017. 11. 9.. +// Copyright © 2017년 황도증. All rights reserved. +// + +import Foundation + +let dataCenter:DataCenter = DataCenter() +let fileName = "branch.brch" + +class DataCenter { + var branches:[Branch] = [] + var filePath:String { get { + let documentDirectory = NSSearchPathForDirectoriesInDomains(.documentDirectory, .userDomainMask, true).first! + return documentDirectory + "/" + fileName + }} + + init (){ + + if FileManager.default.fileExists(atPath: self.filePath) { + //read + if let unarchArray = NSKeyedUnarchiver.unarchiveObject(withFile: self.filePath) as? [Branch] { + branches += unarchArray + } + } else { + //create + branches += defualtData() + } + } + + func save() { + NSKeyedArchiver.archiveRootObject(self.branches, toFile: self.filePath) + } + + func defualtData() -> Array { + let banksyRoom = MeetingRoom(name:"Banksy", capacity: 4) + let kahloRoom = MeetingRoom(name:"Kahlo", capacity: 8) + let riveraRoom = MeetingRoom(name:"Rivera", capacity: 8) + let picasoRoom = MeetingRoom(name:"Picaso", capacity: 10) + + let vehicleService = Service(name: "차량예약") + let meetingRoomService = Service(name: "회의실예약") + let visitorService = Service(name: "방문자예약") + let deskService = Service(name: "데스크예약") + meetingRoomService.items = [banksyRoom, kahloRoom, riveraRoom, picasoRoom] + + let pangyoBranch = Branch(name: "판교점") + let samsungBranch = Branch(name: "삼성점") + let yeoksamBranch = Branch(name: "역삼점") + let sinrimBranch = Branch(name: "신림점") + let songdooBranch = Branch(name: "송도점") + let anamBranch = Branch(name: "안암점") + pangyoBranch.services = [vehicleService, meetingRoomService, visitorService, deskService] + + return [pangyoBranch, samsungBranch, yeoksamBranch, sinrimBranch, songdooBranch, anamBranch] + } +} + +class Branch:NSObject, NSCoding { + let name:String + var services:[Service]? + + init(name:String) { + self.name = name + } + + required init?(coder aDecoder: NSCoder) { + self.name = aDecoder.decodeObject(forKey: "name") as! String + self.services = aDecoder.decodeObject(forKey: "services") as? [Service] + } + + func encode(with aCoder: NSCoder) { + aCoder.encode(self.name, forKey: "name") + aCoder.encode(self.services, forKey: "services") + } +} + +class Service:NSObject, NSCoding { + let name:String + var items:[MeetingRoom]? + + init(name:String) { + self.name = name + } + + required init?(coder aDecoder: NSCoder) { + self.name = aDecoder.decodeObject(forKey: "name") as! String + self.items = aDecoder.decodeObject(forKey: "items") as? [MeetingRoom] + } + + func encode(with aCoder: NSCoder) { + aCoder.encode(self.name, forKey: "name") + aCoder.encode(self.items, forKey: "items") + } +} + +class MeetingRoom:NSObject, NSCoding { + let name:String + let capacity:Int + var reservations:[Reservation]? + + init(name:String, capacity:Int) { + self.name = name + self.capacity = capacity + } + + required init?(coder aDecoder: NSCoder) { + self.name = aDecoder.decodeObject(forKey: "name") as! String + self.capacity = aDecoder.decodeInteger(forKey: "capacity") + self.reservations = aDecoder.decodeObject(forKey: "reservations") as? [Reservation] + } + + func encode(with aCoder: NSCoder) { + aCoder.encode(self.name, forKey: "name") + aCoder.encode(self.capacity, forKey: "capacity") + aCoder.encode(self.reservations, forKey: "reservations") + } +} + +class Reservation:NSObject, NSCoding { + var hostName:String + var date:NSDate + var attendees:Int + var equipments:[String] + var catering:Bool + + override init() { + self.hostName = "host of meeting" + self.date = NSDate() + self.attendees = 1 + self.equipments = [] + self.catering = false + } + + required init?(coder aDecoder: NSCoder) { + self.hostName = aDecoder.decodeObject(forKey: "hostName") as! String + self.date = aDecoder.decodeObject(forKey: "date") as! NSDate + self.attendees = aDecoder.decodeInteger(forKey: "attendees") + self.equipments = aDecoder.decodeObject(forKey: "equipments") as! [String] + self.catering = aDecoder.decodeBool(forKey: "catering") + } + + func encode(with aCoder: NSCoder) { + aCoder.encode(self.hostName, forKey: "hostName") + aCoder.encode(self.date, forKey: "date") + aCoder.encode(self.attendees, forKey: "attendees") + aCoder.encode(self.equipments, forKey: "equipments") + aCoder.encode(self.catering, forKey: "catering") + } + +} diff --git "a/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/meetingRooms_archive/meetingRooms/EquipmentDefault.plist" "b/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/meetingRooms_archive/meetingRooms/EquipmentDefault.plist" new file mode 100644 index 0000000..50f805e --- /dev/null +++ "b/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/meetingRooms_archive/meetingRooms/EquipmentDefault.plist" @@ -0,0 +1,30 @@ + + + + + + amount + 12 + name + HDYE 22 + + + amount + 33 + name + DFO 33 + + + amount + 2 + name + WNJ 12 + + + amount + 15 + name + HP 2019 + + + diff --git "a/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/meetingRooms_archive/meetingRooms/EquipmentsListViewController.swift" "b/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/meetingRooms_archive/meetingRooms/EquipmentsListViewController.swift" new file mode 100644 index 0000000..9831526 --- /dev/null +++ "b/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/meetingRooms_archive/meetingRooms/EquipmentsListViewController.swift" @@ -0,0 +1,120 @@ +// +// EquipmentsListViewController.swift +// meetingRooms +// +// Created by 황도증 on 2017. 11. 10.. +// Copyright © 2017년 황도증. All rights reserved. +// + +import UIKit + +let EquipmentFileName = "EquipmentDefault" + +class EquipmentsListViewController: UITableViewController { + + var equipments:Array = [] + + override func viewDidLoad() { + super.viewDidLoad() + + // Uncomment the following line to preserve selection between presentations + // self.clearsSelectionOnViewWillAppear = false + + // Uncomment the following line to display an Edit button in the navigation bar for this view controller. + // self.navigationItem.rightBarButtonItem = self.editButtonItem + + guard let equipmentURL = Bundle.main.url(forResource: EquipmentFileName, withExtension: "plist") else { + print("no file") + return + } + if let equipmentArray = NSArray(contentsOf: equipmentURL) { + print(equipmentArray) + equipments.append(equipmentArray) + } + } + + override func didReceiveMemoryWarning() { + super.didReceiveMemoryWarning() + // Dispose of any resources that can be recreated. + } + + // MARK: - Table view data source + + override func numberOfSections(in tableView: UITableView) -> Int { + // #warning Incomplete implementation, return the number of sections + return 1 + } + + override func tableView(_ tableView: UITableView, numberOfRowsInSection section: Int) -> Int { + // #warning Incomplete implementation, return the number of rows + return equipments.count + } + + + override func tableView(_ tableView: UITableView, cellForRowAt indexPath: IndexPath) -> UITableViewCell { + let cell = tableView.dequeueReusableCell(withIdentifier: "EquipmentCell", for: indexPath) + + // Configure the cell... + guard let equipment = equipments[indexPath.row] as? [String:AnyObject] else { + print("error") + return cell + } + + if let name = equipment["name"] as? String { + cell.textLabel?.text = name + } + + if let amount = equipment["amount"] as? Int { + cell.detailTextLabel?.text = String(amount) + } + + return cell + } + + + /* + // Override to support conditional editing of the table view. + override func tableView(_ tableView: UITableView, canEditRowAt indexPath: IndexPath) -> Bool { + // Return false if you do not want the specified item to be editable. + return true + } + */ + + /* + // Override to support editing the table view. + override func tableView(_ tableView: UITableView, commit editingStyle: UITableViewCellEditingStyle, forRowAt indexPath: IndexPath) { + if editingStyle == .delete { + // Delete the row from the data source + tableView.deleteRows(at: [indexPath], with: .fade) + } else if editingStyle == .insert { + // Create a new instance of the appropriate class, insert it into the array, and add a new row to the table view + } + } + */ + + /* + // Override to support rearranging the table view. + override func tableView(_ tableView: UITableView, moveRowAt fromIndexPath: IndexPath, to: IndexPath) { + + } + */ + + /* + // Override to support conditional rearranging of the table view. + override func tableView(_ tableView: UITableView, canMoveRowAt indexPath: IndexPath) -> Bool { + // Return false if you do not want the item to be re-orderable. + return true + } + */ + + /* + // MARK: - Navigation + + // In a storyboard-based application, you will often want to do a little preparation before navigation + override func prepare(for segue: UIStoryboardSegue, sender: Any?) { + // Get the new view controller using segue.destinationViewController. + // Pass the selected object to the new view controller. + } + */ + +} diff --git "a/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/meetingRooms_archive/meetingRooms/Info.plist" "b/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/meetingRooms_archive/meetingRooms/Info.plist" new file mode 100644 index 0000000..16be3b6 --- /dev/null +++ "b/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/meetingRooms_archive/meetingRooms/Info.plist" @@ -0,0 +1,45 @@ + + + + + CFBundleDevelopmentRegion + $(DEVELOPMENT_LANGUAGE) + CFBundleExecutable + $(EXECUTABLE_NAME) + CFBundleIdentifier + $(PRODUCT_BUNDLE_IDENTIFIER) + CFBundleInfoDictionaryVersion + 6.0 + CFBundleName + $(PRODUCT_NAME) + CFBundlePackageType + APPL + CFBundleShortVersionString + 1.0 + CFBundleVersion + 1 + LSRequiresIPhoneOS + + UILaunchStoryboardName + LaunchScreen + UIMainStoryboardFile + Main + UIRequiredDeviceCapabilities + + armv7 + + UISupportedInterfaceOrientations + + UIInterfaceOrientationPortrait + UIInterfaceOrientationLandscapeLeft + UIInterfaceOrientationLandscapeRight + + UISupportedInterfaceOrientations~ipad + + UIInterfaceOrientationPortrait + UIInterfaceOrientationPortraitUpsideDown + UIInterfaceOrientationLandscapeLeft + UIInterfaceOrientationLandscapeRight + + + diff --git "a/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/meetingRooms_archive/meetingRooms/MeetingRoomListViewController.swift" "b/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/meetingRooms_archive/meetingRooms/MeetingRoomListViewController.swift" new file mode 100644 index 0000000..b56d5ae --- /dev/null +++ "b/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/meetingRooms_archive/meetingRooms/MeetingRoomListViewController.swift" @@ -0,0 +1,117 @@ +// +// MeetingRoomListViewController.swift +// meetingRooms +// +// Created by 황도증 on 2017. 10. 30.. +// Copyright © 2017년 황도증. All rights reserved. +// + +import UIKit + +class MeetingRoomListViewController: UITableViewController { + + var service:Service? + + override func viewDidLoad() { + super.viewDidLoad() + + // Uncomment the following line to preserve selection between presentations + // self.clearsSelectionOnViewWillAppear = false + + // Uncomment the following line to display an Edit button in the navigation bar for this view controller. + // self.navigationItem.rightBarButtonItem = self.editButtonItem + + self.title = service?.name + } + + override func didReceiveMemoryWarning() { + super.didReceiveMemoryWarning() + // Dispose of any resources that can be recreated. + } + + // MARK: - Table view data source + + override func numberOfSections(in tableView: UITableView) -> Int { + // #warning Incomplete implementation, return the number of sections + return 1 + } + + override func tableView(_ tableView: UITableView, numberOfRowsInSection section: Int) -> Int { + // #warning Incomplete implementation, return the number of rows + //let categoryValues = Array(meetingRooms.values)[section] + //let orderMeetingRoooms = meetingRooms.sorted(by: {$0.1.first!.1 < $1.1.first!.1}) + guard let rowCount = service?.items?.count else { + return 0 + } + return rowCount + } + + + override func tableView(_ tableView: UITableView, cellForRowAt indexPath: IndexPath) -> UITableViewCell { + let cell = tableView.dequeueReusableCell(withIdentifier: "ItemCell", for: indexPath) + + //let orderMeetingRoooms = meetingRooms.sorted(by: {$0.1.first!.1 < $1.1.first!.1}) + // Configure the cell... + //let categoryValue = Array(meetingRooms.values)[indexPath.section] + + guard let meetingRoom = service?.items?[indexPath.row] else { + return cell + } + + cell.textLabel!.text = meetingRoom.name + cell.detailTextLabel!.text = String(meetingRoom.capacity) + return cell + } + + /* + // Override to support conditional editing of the table view. + override func tableView(_ tableView: UITableView, canEditRowAt indexPath: IndexPath) -> Bool { + // Return false if you do not want the specified item to be editable. + return true + } + */ + + /* + // Override to support editing the table view. + override func tableView(_ tableView: UITableView, commit editingStyle: UITableViewCellEditingStyle, forRowAt indexPath: IndexPath) { + if editingStyle == .delete { + // Delete the row from the data source + tableView.deleteRows(at: [indexPath], with: .fade) + } else if editingStyle == .insert { + // Create a new instance of the appropriate class, insert it into the array, and add a new row to the table view + } + } + */ + + /* + // Override to support rearranging the table view. + override func tableView(_ tableView: UITableView, moveRowAt fromIndexPath: IndexPath, to: IndexPath) { + + } + */ + + /* + // Override to support conditional rearranging of the table view. + override func tableView(_ tableView: UITableView, canMoveRowAt indexPath: IndexPath) -> Bool { + // Return false if you do not want the item to be re-orderable. + return true + } + */ + + + // MARK: - Navigation + + // In a storyboard-based application, you will often want to do a little preparation before navigation + override func prepare(for segue: UIStoryboardSegue, sender: Any?) { + // Get the new view controller using segue.destinationViewController. + // Pass the selected object to the new view controller. + if segue.identifier == "ReservationSegue" { + guard let destination = segue.destination as? ReservationListViewController, let selectedIndex = self.tableView.indexPathForSelectedRow?.row, let meetingRoom = service?.items?[selectedIndex] else { + return + } + destination.meetingRoom = meetingRoom + } + + } + +} diff --git "a/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/meetingRooms_archive/meetingRooms/ReservationListViewController.swift" "b/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/meetingRooms_archive/meetingRooms/ReservationListViewController.swift" new file mode 100644 index 0000000..869a9b7 --- /dev/null +++ "b/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/meetingRooms_archive/meetingRooms/ReservationListViewController.swift" @@ -0,0 +1,120 @@ +// +// ReservationListViewController.swift +// meetingRooms +// +// Created by 황도증 on 2017. 11. 9.. +// Copyright © 2017년 황도증. All rights reserved. +// + +import UIKit + +class ReservationListViewController: UITableViewController { + + var meetingRoom:MeetingRoom? + var newReservation:Reservation? + + override func viewDidLoad() { + super.viewDidLoad() + + // Uncomment the following line to preserve selection between presentations + // self.clearsSelectionOnViewWillAppear = false + + // Uncomment the following line to display an Edit button in the navigation bar for this view controller. + // self.navigationItem.rightBarButtonItem = self.editButtonItem + } + + override func didReceiveMemoryWarning() { + super.didReceiveMemoryWarning() + // Dispose of any resources that can be recreated. + } + + func addNewItem(reservation:Reservation) { + if (self.meetingRoom?.reservations?.append(reservation)) == nil { + self.meetingRoom?.reservations = [reservation] + } + dataCenter.save() + self.tableView.reloadData() + } + + @IBAction func unwindToReservationList(segue:UIStoryboardSegue) { + + } + + + // MARK: - Table view data source + + override func numberOfSections(in tableView: UITableView) -> Int { + // #warning Incomplete implementation, return the number of sections + return 1 + } + + override func tableView(_ tableView: UITableView, numberOfRowsInSection section: Int) -> Int { + // #warning Incomplete implementation, return the number of rows + guard let rowCount = meetingRoom?.reservations?.count else { + return 0 + } + return rowCount + } + + + override func tableView(_ tableView: UITableView, cellForRowAt indexPath: IndexPath) -> UITableViewCell { + let cell = tableView.dequeueReusableCell(withIdentifier: "ReservationCell", for: indexPath) + + // Configure the cell... + guard let reservation = meetingRoom?.reservations?[indexPath.row] else { + return cell + } + + cell.textLabel?.text = reservation.date.description + cell.detailTextLabel?.text = reservation.hostName + + return cell + } + + + /* + // Override to support conditional editing of the table view. + override func tableView(_ tableView: UITableView, canEditRowAt indexPath: IndexPath) -> Bool { + // Return false if you do not want the specified item to be editable. + return true + } + */ + + /* + // Override to support editing the table view. + override func tableView(_ tableView: UITableView, commit editingStyle: UITableViewCellEditingStyle, forRowAt indexPath: IndexPath) { + if editingStyle == .delete { + // Delete the row from the data source + tableView.deleteRows(at: [indexPath], with: .fade) + } else if editingStyle == .insert { + // Create a new instance of the appropriate class, insert it into the array, and add a new row to the table view + } + } + */ + + /* + // Override to support rearranging the table view. + override func tableView(_ tableView: UITableView, moveRowAt fromIndexPath: IndexPath, to: IndexPath) { + + } + */ + + /* + // Override to support conditional rearranging of the table view. + override func tableView(_ tableView: UITableView, canMoveRowAt indexPath: IndexPath) -> Bool { + // Return false if you do not want the item to be re-orderable. + return true + } + */ + + /* + // MARK: - Navigation + + // In a storyboard-based application, you will often want to do a little preparation before navigation + override func prepare(for segue: UIStoryboardSegue, sender: Any?) { + // Get the new view controller using segue.destinationViewController. + // Pass the selected object to the new view controller. + } + */ + +} diff --git "a/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/meetingRooms_archive/meetingRooms/ReserveRoomViewController.swift" "b/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/meetingRooms_archive/meetingRooms/ReserveRoomViewController.swift" new file mode 100644 index 0000000..b976043 --- /dev/null +++ "b/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/meetingRooms_archive/meetingRooms/ReserveRoomViewController.swift" @@ -0,0 +1,154 @@ +// +// ReserveRoomViewController.swift +// meetingRooms +// +// Created by 황도증 on 2017. 11. 9.. +// Copyright © 2017년 황도증. All rights reserved. +// + +import UIKit + +class ReserveRoomViewController: UITableViewController { + + @IBOutlet weak var hostNameField: UITextField! + @IBOutlet weak var datePicker: UIDatePicker! + @IBOutlet weak var attendeesField: UITextField! + @IBOutlet weak var equipmentField: UITextField! + @IBOutlet weak var cateringSwitch: UISwitch! + + + override func viewDidLoad() { + super.viewDidLoad() + + // Uncomment the following line to preserve selection between presentations + // self.clearsSelectionOnViewWillAppear = false + + // Uncomment the following line to display an Edit button in the navigation bar for this view controller. + // self.navigationItem.rightBarButtonItem = self.editButtonItem + } + + override func didReceiveMemoryWarning() { + super.didReceiveMemoryWarning() + // Dispose of any resources that can be recreated. + } + + func newReservation() -> Reservation? { + let reservation = Reservation() + let host = hostNameField.text + + if (host?.isEmpty)! { + return nil + } + reservation.hostName = host! + reservation.date = datePicker.date as NSDate + + if let equipmentArray = equipmentField.text?.split(separator: ",").map(String.init) { + reservation.equipments = equipmentArray + } + reservation.catering = cateringSwitch.isOn + return reservation + } + + @IBAction func cancelReservation(_ sender: Any) { + self.dismiss(animated: true, completion: nil) + } + + @IBAction func makeReservation(_ sender: Any) { + guard let reservation = newReservation() else { + self.dismiss(animated: true, completion: nil) + return + } + + switch self.presentingViewController { + case let tapbarC as UITabBarController: + if let navigationC = tapbarC.selectedViewController as? UINavigationController, let reservationListVC = navigationC.topViewController as? ReservationListViewController { + reservationListVC.addNewItem(reservation: reservation) + } + case let navigationC as UINavigationController: + if let reservationListVC = navigationC.topViewController as? ReservationListViewController { + reservationListVC.addNewItem(reservation: reservation) + } + case let reservationListVC as ReservationListViewController: + reservationListVC.addNewItem(reservation: reservation) + default: + break + } + + self.dismiss(animated: true, completion: nil) + } + + + // MARK: - Table view data source +/* + override func numberOfSections(in tableView: UITableView) -> Int { + // #warning Incomplete implementation, return the number of sections + return 0 + } + + override func tableView(_ tableView: UITableView, numberOfRowsInSection section: Int) -> Int { + // #warning Incomplete implementation, return the number of rows + return 0 + } +*/ + /* + override func tableView(_ tableView: UITableView, cellForRowAt indexPath: IndexPath) -> UITableViewCell { + let cell = tableView.dequeueReusableCell(withIdentifier: "reuseIdentifier", for: indexPath) + + // Configure the cell... + + return cell + } + */ + + /* + // Override to support conditional editing of the table view. + override func tableView(_ tableView: UITableView, canEditRowAt indexPath: IndexPath) -> Bool { + // Return false if you do not want the specified item to be editable. + return true + } + */ + + /* + // Override to support editing the table view. + override func tableView(_ tableView: UITableView, commit editingStyle: UITableViewCellEditingStyle, forRowAt indexPath: IndexPath) { + if editingStyle == .delete { + // Delete the row from the data source + tableView.deleteRows(at: [indexPath], with: .fade) + } else if editingStyle == .insert { + // Create a new instance of the appropriate class, insert it into the array, and add a new row to the table view + } + } + */ + + /* + // Override to support rearranging the table view. + override func tableView(_ tableView: UITableView, moveRowAt fromIndexPath: IndexPath, to: IndexPath) { + + } + */ + + /* + // Override to support conditional rearranging of the table view. + override func tableView(_ tableView: UITableView, canMoveRowAt indexPath: IndexPath) -> Bool { + // Return false if you do not want the item to be re-orderable. + return true + } + */ + + + // MARK: - Navigation + + // In a storyboard-based application, you will often want to do a little preparation before navigation + override func prepare(for segue: UIStoryboardSegue, sender: Any?) { + // Get the new view controller using segue.destinationViewController. + // Pass the selected object to the new view controller. + if segue.identifier == "ReserveDone" { + guard let reservation = newReservation(), let reservationListVC = segue.destination as? ReservationListViewController else { + return + } + reservationListVC.addNewItem(reservation: reservation) + } + } + + +} diff --git "a/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/meetingRooms_archive/meetingRooms/RoomInfoViewController.swift" "b/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/meetingRooms_archive/meetingRooms/RoomInfoViewController.swift" new file mode 100644 index 0000000..61bf80d --- /dev/null +++ "b/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/meetingRooms_archive/meetingRooms/RoomInfoViewController.swift" @@ -0,0 +1,98 @@ +// +// RoomInfoViewController.swift +// meetingRooms +// +// Created by 황도증 on 2017. 11. 9.. +// Copyright © 2017년 황도증. All rights reserved. +// + +import UIKit + +class RoomInfoViewController: UITableViewController { + + override func viewDidLoad() { + super.viewDidLoad() + + // Uncomment the following line to preserve selection between presentations + // self.clearsSelectionOnViewWillAppear = false + + // Uncomment the following line to display an Edit button in the navigation bar for this view controller. + // self.navigationItem.rightBarButtonItem = self.editButtonItem + } + + override func didReceiveMemoryWarning() { + super.didReceiveMemoryWarning() + // Dispose of any resources that can be recreated. + } + @IBAction func modalDismiss(_ sender: Any) { + self.dismiss(animated: true, completion: nil) + } + /* + // MARK: - Table view data source + + override func numberOfSections(in tableView: UITableView) -> Int { + // #warning Incomplete implementation, return the number of sections + return 0 + } + + override func tableView(_ tableView: UITableView, numberOfRowsInSection section: Int) -> Int { + // #warning Incomplete implementation, return the number of rows + return 0 + } +*/ + /* + override func tableView(_ tableView: UITableView, cellForRowAt indexPath: IndexPath) -> UITableViewCell { + let cell = tableView.dequeueReusableCell(withIdentifier: "reuseIdentifier", for: indexPath) + + // Configure the cell... + + return cell + } + */ + + /* + // Override to support conditional editing of the table view. + override func tableView(_ tableView: UITableView, canEditRowAt indexPath: IndexPath) -> Bool { + // Return false if you do not want the specified item to be editable. + return true + } + */ + + /* + // Override to support editing the table view. + override func tableView(_ tableView: UITableView, commit editingStyle: UITableViewCellEditingStyle, forRowAt indexPath: IndexPath) { + if editingStyle == .delete { + // Delete the row from the data source + tableView.deleteRows(at: [indexPath], with: .fade) + } else if editingStyle == .insert { + // Create a new instance of the appropriate class, insert it into the array, and add a new row to the table view + } + } + */ + + /* + // Override to support rearranging the table view. + override func tableView(_ tableView: UITableView, moveRowAt fromIndexPath: IndexPath, to: IndexPath) { + + } + */ + + /* + // Override to support conditional rearranging of the table view. + override func tableView(_ tableView: UITableView, canMoveRowAt indexPath: IndexPath) -> Bool { + // Return false if you do not want the item to be re-orderable. + return true + } + */ + + /* + // MARK: - Navigation + + // In a storyboard-based application, you will often want to do a little preparation before navigation + override func prepare(for segue: UIStoryboardSegue, sender: Any?) { + // Get the new view controller using segue.destinationViewController. + // Pass the selected object to the new view controller. + } + */ + +} diff --git "a/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/meetingRooms_archive/meetingRooms/ServiceListViewController.swift" "b/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/meetingRooms_archive/meetingRooms/ServiceListViewController.swift" new file mode 100644 index 0000000..091d906 --- /dev/null +++ "b/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/meetingRooms_archive/meetingRooms/ServiceListViewController.swift" @@ -0,0 +1,113 @@ +// +// ServiceListViewController.swift +// meetingRooms +// +// Created by 황도증 on 2017. 11. 9.. +// Copyright © 2017년 황도증. All rights reserved. +// + +import UIKit + +class ServiceListViewController: UITableViewController { + + var branch:Branch? + + override func viewDidLoad() { + super.viewDidLoad() + + // Uncomment the following line to preserve selection between presentations + // self.clearsSelectionOnViewWillAppear = false + + // Uncomment the following line to display an Edit button in the navigation bar for this view controller. + // self.navigationItem.rightBarButtonItem = self.editButtonItem + self.title = branch?.name + self.navigationController?.isToolbarHidden = false + } + + override func didReceiveMemoryWarning() { + super.didReceiveMemoryWarning() + // Dispose of any resources that can be recreated. + } + + // MARK: - Table view data source + + override func numberOfSections(in tableView: UITableView) -> Int { + // #warning Incomplete implementation, return the number of sections + return 1 + } + + override func tableView(_ tableView: UITableView, numberOfRowsInSection section: Int) -> Int { + // #warning Incomplete implementation, return the number of rows + guard let rowCount = branch?.services?.count else { + return 0 + } + return rowCount + } + + + override func tableView(_ tableView: UITableView, cellForRowAt indexPath: IndexPath) -> UITableViewCell { + let cell = tableView.dequeueReusableCell(withIdentifier: "ServiceCell", for: indexPath) + + // Configure the cell... + guard let service = branch?.services?[indexPath.row] else { + return cell + } + + cell.textLabel?.text = service.name + + return cell + } + + + /* + // Override to support conditional editing of the table view. + override func tableView(_ tableView: UITableView, canEditRowAt indexPath: IndexPath) -> Bool { + // Return false if you do not want the specified item to be editable. + return true + } + */ + + /* + // Override to support editing the table view. + override func tableView(_ tableView: UITableView, commit editingStyle: UITableViewCellEditingStyle, forRowAt indexPath: IndexPath) { + if editingStyle == .delete { + // Delete the row from the data source + tableView.deleteRows(at: [indexPath], with: .fade) + } else if editingStyle == .insert { + // Create a new instance of the appropriate class, insert it into the array, and add a new row to the table view + } + } + */ + + /* + // Override to support rearranging the table view. + override func tableView(_ tableView: UITableView, moveRowAt fromIndexPath: IndexPath, to: IndexPath) { + + } + */ + + /* + // Override to support conditional rearranging of the table view. + override func tableView(_ tableView: UITableView, canMoveRowAt indexPath: IndexPath) -> Bool { + // Return false if you do not want the item to be re-orderable. + return true + } + */ + + + // MARK: - Navigation + + // In a storyboard-based application, you will often want to do a little preparation before navigation + override func prepare(for segue: UIStoryboardSegue, sender: Any?) { + // Get the new view controller using segue.destinationViewController. + // Pass the selected object to the new view controller. + if segue.identifier == "MeetingRoomSegue" { + guard let destination = segue.destination as? MeetingRoomListViewController, let selectedIndex = self.tableView.indexPathForSelectedRow?.row, let service = branch?.services?[selectedIndex] else { + return + } + destination.service = service + } + } + + +} diff --git "a/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/meetingRooms_archive/meetingRooms/TintColorViewController.swift" "b/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/meetingRooms_archive/meetingRooms/TintColorViewController.swift" new file mode 100644 index 0000000..9ba2c19 --- /dev/null +++ "b/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/meetingRooms_archive/meetingRooms/TintColorViewController.swift" @@ -0,0 +1,76 @@ +// +// TintColorViewController.swift +// meetingRooms +// +// Created by 황도증 on 2017. 11. 9.. +// Copyright © 2017년 황도증. All rights reserved. +// + +import UIKit + +enum TintColor:Int { + case Blue = 0, Red, Green, Purple + + var color:UIColor { get { + switch self { + case .Blue: + return UIColor.blue + case .Red: + return UIColor.red + case .Green: + return UIColor.green + case .Purple: + return UIColor.purple + } + } + + } +} + +let TintColorKey = "TintColor" + +func applyTintColor(color:UIColor) { + guard let window = UIApplication.shared.keyWindow else { + return + } + window.tintColor = color +} + +class TintColorViewController: UIViewController { + + @IBOutlet weak var tintColorSeg: UISegmentedControl! + + override func viewDidLoad() { + super.viewDidLoad() + + // Do any additional setup after loading the view. + let userDefaultColor = UserDefaults.standard.integer(forKey: TintColorKey) + self.tintColorSeg.selectedSegmentIndex = userDefaultColor + } + + override func didReceiveMemoryWarning() { + super.didReceiveMemoryWarning() + // Dispose of any resources that can be recreated. + } + + @IBAction func tintColorChanged(_ sender: Any) { + let selectedIndex = self.tintColorSeg.selectedSegmentIndex + UserDefaults.standard.set(selectedIndex, forKey: TintColorKey) + + guard let changedColor = TintColor(rawValue: selectedIndex)?.color else { + return + } + applyTintColor(color: changedColor) + } + + /* + // MARK: - Navigation + + // In a storyboard-based application, you will often want to do a little preparation before navigation + override func prepare(for segue: UIStoryboardSegue, sender: Any?) { + // Get the new view controller using segue.destinationViewController. + // Pass the selected object to the new view controller. + } + */ + +} diff --git "a/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/meetingRooms_archive/meetingRooms/ViewController.swift" "b/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/meetingRooms_archive/meetingRooms/ViewController.swift" new file mode 100644 index 0000000..24bd9b0 --- /dev/null +++ "b/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/meetingRooms_archive/meetingRooms/ViewController.swift" @@ -0,0 +1,25 @@ +// +// ViewController.swift +// meetingRooms +// +// Created by 황도증 on 2017. 10. 30.. +// Copyright © 2017년 황도증. All rights reserved. +// + +import UIKit + +class ViewController: UIViewController { + + override func viewDidLoad() { + super.viewDidLoad() + // Do any additional setup after loading the view, typically from a nib. + } + + override func didReceiveMemoryWarning() { + super.didReceiveMemoryWarning() + // Dispose of any resources that can be recreated. + } + + +} + diff --git "a/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/meetingRooms_archive/meetingRoomsTests/Info.plist" "b/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/meetingRooms_archive/meetingRoomsTests/Info.plist" new file mode 100644 index 0000000..6c40a6c --- /dev/null +++ "b/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/meetingRooms_archive/meetingRoomsTests/Info.plist" @@ -0,0 +1,22 @@ + + + + + CFBundleDevelopmentRegion + $(DEVELOPMENT_LANGUAGE) + CFBundleExecutable + $(EXECUTABLE_NAME) + CFBundleIdentifier + $(PRODUCT_BUNDLE_IDENTIFIER) + CFBundleInfoDictionaryVersion + 6.0 + CFBundleName + $(PRODUCT_NAME) + CFBundlePackageType + BNDL + CFBundleShortVersionString + 1.0 + CFBundleVersion + 1 + + diff --git "a/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/meetingRooms_archive/meetingRoomsTests/meetingRoomsTests.swift" "b/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/meetingRooms_archive/meetingRoomsTests/meetingRoomsTests.swift" new file mode 100644 index 0000000..bfbd8d6 --- /dev/null +++ "b/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/meetingRooms_archive/meetingRoomsTests/meetingRoomsTests.swift" @@ -0,0 +1,36 @@ +// +// meetingRoomsTests.swift +// meetingRoomsTests +// +// Created by 황도증 on 2017. 10. 30.. +// Copyright © 2017년 황도증. All rights reserved. +// + +import XCTest +@testable import meetingRooms + +class meetingRoomsTests: XCTestCase { + + override func setUp() { + super.setUp() + // Put setup code here. This method is called before the invocation of each test method in the class. + } + + override func tearDown() { + // Put teardown code here. This method is called after the invocation of each test method in the class. + super.tearDown() + } + + func testExample() { + // This is an example of a functional test case. + // Use XCTAssert and related functions to verify your tests produce the correct results. + } + + func testPerformanceExample() { + // This is an example of a performance test case. + self.measure { + // Put the code you want to measure the time of here. + } + } + +} diff --git "a/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/meetingRooms_archive/meetingRoomsUITests/Info.plist" "b/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/meetingRooms_archive/meetingRoomsUITests/Info.plist" new file mode 100644 index 0000000..6c40a6c --- /dev/null +++ "b/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/meetingRooms_archive/meetingRoomsUITests/Info.plist" @@ -0,0 +1,22 @@ + + + + + CFBundleDevelopmentRegion + $(DEVELOPMENT_LANGUAGE) + CFBundleExecutable + $(EXECUTABLE_NAME) + CFBundleIdentifier + $(PRODUCT_BUNDLE_IDENTIFIER) + CFBundleInfoDictionaryVersion + 6.0 + CFBundleName + $(PRODUCT_NAME) + CFBundlePackageType + BNDL + CFBundleShortVersionString + 1.0 + CFBundleVersion + 1 + + diff --git "a/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/meetingRooms_archive/meetingRoomsUITests/meetingRoomsUITests.swift" "b/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/meetingRooms_archive/meetingRoomsUITests/meetingRoomsUITests.swift" new file mode 100644 index 0000000..4873bfa --- /dev/null +++ "b/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/meetingRooms_archive/meetingRoomsUITests/meetingRoomsUITests.swift" @@ -0,0 +1,36 @@ +// +// meetingRoomsUITests.swift +// meetingRoomsUITests +// +// Created by 황도증 on 2017. 10. 30.. +// Copyright © 2017년 황도증. All rights reserved. +// + +import XCTest + +class meetingRoomsUITests: XCTestCase { + + override func setUp() { + super.setUp() + + // Put setup code here. This method is called before the invocation of each test method in the class. + + // In UI tests it is usually best to stop immediately when a failure occurs. + continueAfterFailure = false + // UI tests must launch the application that they test. Doing this in setup will make sure it happens for each test method. + XCUIApplication().launch() + + // In UI tests it’s important to set the initial state - such as interface orientation - required for your tests before they run. The setUp method is a good place to do this. + } + + override func tearDown() { + // Put teardown code here. This method is called after the invocation of each test method in the class. + super.tearDown() + } + + func testExample() { + // Use recording to get started writing UI tests. + // Use XCTAssert and related functions to verify your tests produce the correct results. + } + +} diff --git "a/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/meetingRooms_cell accessory&modal/meetingRooms.xcodeproj/project.pbxproj" "b/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/meetingRooms_cell accessory&modal/meetingRooms.xcodeproj/project.pbxproj" new file mode 100644 index 0000000..941ad94 --- /dev/null +++ "b/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/meetingRooms_cell accessory&modal/meetingRooms.xcodeproj/project.pbxproj" @@ -0,0 +1,577 @@ +// !$*UTF8*$! +{ + archiveVersion = 1; + classes = { + }; + objectVersion = 48; + objects = { + +/* Begin PBXBuildFile section */ + AE99575B1FA704AF00397D38 /* AppDelegate.swift in Sources */ = {isa = PBXBuildFile; fileRef = AE99575A1FA704AF00397D38 /* AppDelegate.swift */; }; + AE99575D1FA704AF00397D38 /* ViewController.swift in Sources */ = {isa = PBXBuildFile; fileRef = AE99575C1FA704AF00397D38 /* ViewController.swift */; }; + AE9957601FA704AF00397D38 /* Main.storyboard in Resources */ = {isa = PBXBuildFile; fileRef = AE99575E1FA704AF00397D38 /* Main.storyboard */; }; + AE9957621FA704AF00397D38 /* Assets.xcassets in Resources */ = {isa = PBXBuildFile; fileRef = AE9957611FA704AF00397D38 /* Assets.xcassets */; }; + AE9957651FA704AF00397D38 /* LaunchScreen.storyboard in Resources */ = {isa = PBXBuildFile; fileRef = AE9957631FA704AF00397D38 /* LaunchScreen.storyboard */; }; + AE9957701FA704AF00397D38 /* meetingRoomsTests.swift in Sources */ = {isa = PBXBuildFile; fileRef = AE99576F1FA704AF00397D38 /* meetingRoomsTests.swift */; }; + AE99577B1FA704B000397D38 /* meetingRoomsUITests.swift in Sources */ = {isa = PBXBuildFile; fileRef = AE99577A1FA704B000397D38 /* meetingRoomsUITests.swift */; }; + AE9957891FA7054800397D38 /* MeetingRoomListViewController.swift in Sources */ = {isa = PBXBuildFile; fileRef = AE9957881FA7054800397D38 /* MeetingRoomListViewController.swift */; }; + AEB3189D1FB4641000AEB094 /* DataCenter.swift in Sources */ = {isa = PBXBuildFile; fileRef = AEB3189C1FB4641000AEB094 /* DataCenter.swift */; }; + AEB3189F1FB4684600AEB094 /* BranchListViewController.swift in Sources */ = {isa = PBXBuildFile; fileRef = AEB3189E1FB4684600AEB094 /* BranchListViewController.swift */; }; + AEB318A11FB4685800AEB094 /* ServiceListViewController.swift in Sources */ = {isa = PBXBuildFile; fileRef = AEB318A01FB4685800AEB094 /* ServiceListViewController.swift */; }; + AEB318A31FB4807F00AEB094 /* RoomInfoViewController.swift in Sources */ = {isa = PBXBuildFile; fileRef = AEB318A21FB4807F00AEB094 /* RoomInfoViewController.swift */; }; +/* End PBXBuildFile section */ + +/* Begin PBXContainerItemProxy section */ + AE99576C1FA704AF00397D38 /* PBXContainerItemProxy */ = { + isa = PBXContainerItemProxy; + containerPortal = AE99574F1FA704AF00397D38 /* Project object */; + proxyType = 1; + remoteGlobalIDString = AE9957561FA704AF00397D38; + remoteInfo = meetingRooms; + }; + AE9957771FA704B000397D38 /* PBXContainerItemProxy */ = { + isa = PBXContainerItemProxy; + containerPortal = AE99574F1FA704AF00397D38 /* Project object */; + proxyType = 1; + remoteGlobalIDString = AE9957561FA704AF00397D38; + remoteInfo = meetingRooms; + }; +/* End PBXContainerItemProxy section */ + +/* Begin PBXFileReference section */ + AE9957571FA704AF00397D38 /* meetingRooms.app */ = {isa = PBXFileReference; explicitFileType = wrapper.application; includeInIndex = 0; path = meetingRooms.app; sourceTree = BUILT_PRODUCTS_DIR; }; + AE99575A1FA704AF00397D38 /* AppDelegate.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = AppDelegate.swift; sourceTree = ""; }; + AE99575C1FA704AF00397D38 /* ViewController.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = ViewController.swift; sourceTree = ""; }; + AE99575F1FA704AF00397D38 /* Base */ = {isa = PBXFileReference; lastKnownFileType = file.storyboard; name = Base; path = Base.lproj/Main.storyboard; sourceTree = ""; }; + AE9957611FA704AF00397D38 /* Assets.xcassets */ = {isa = PBXFileReference; lastKnownFileType = folder.assetcatalog; path = Assets.xcassets; sourceTree = ""; }; + AE9957641FA704AF00397D38 /* Base */ = {isa = PBXFileReference; lastKnownFileType = file.storyboard; name = Base; path = Base.lproj/LaunchScreen.storyboard; sourceTree = ""; }; + AE9957661FA704AF00397D38 /* Info.plist */ = {isa = PBXFileReference; lastKnownFileType = text.plist.xml; path = Info.plist; sourceTree = ""; }; + AE99576B1FA704AF00397D38 /* meetingRoomsTests.xctest */ = {isa = PBXFileReference; explicitFileType = wrapper.cfbundle; includeInIndex = 0; path = meetingRoomsTests.xctest; sourceTree = BUILT_PRODUCTS_DIR; }; + AE99576F1FA704AF00397D38 /* meetingRoomsTests.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = meetingRoomsTests.swift; sourceTree = ""; }; + AE9957711FA704AF00397D38 /* Info.plist */ = {isa = PBXFileReference; lastKnownFileType = text.plist.xml; path = Info.plist; sourceTree = ""; }; + AE9957761FA704B000397D38 /* meetingRoomsUITests.xctest */ = {isa = PBXFileReference; explicitFileType = wrapper.cfbundle; includeInIndex = 0; path = meetingRoomsUITests.xctest; sourceTree = BUILT_PRODUCTS_DIR; }; + AE99577A1FA704B000397D38 /* meetingRoomsUITests.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = meetingRoomsUITests.swift; sourceTree = ""; }; + AE99577C1FA704B000397D38 /* Info.plist */ = {isa = PBXFileReference; lastKnownFileType = text.plist.xml; path = Info.plist; sourceTree = ""; }; + AE9957881FA7054800397D38 /* MeetingRoomListViewController.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = MeetingRoomListViewController.swift; sourceTree = ""; }; + AEB3189C1FB4641000AEB094 /* DataCenter.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = DataCenter.swift; sourceTree = ""; }; + AEB3189E1FB4684600AEB094 /* BranchListViewController.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = BranchListViewController.swift; sourceTree = ""; }; + AEB318A01FB4685800AEB094 /* ServiceListViewController.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = ServiceListViewController.swift; sourceTree = ""; }; + AEB318A21FB4807F00AEB094 /* RoomInfoViewController.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = RoomInfoViewController.swift; sourceTree = ""; }; +/* End PBXFileReference section */ + +/* Begin PBXFrameworksBuildPhase section */ + AE9957541FA704AF00397D38 /* Frameworks */ = { + isa = PBXFrameworksBuildPhase; + buildActionMask = 2147483647; + files = ( + ); + runOnlyForDeploymentPostprocessing = 0; + }; + AE9957681FA704AF00397D38 /* Frameworks */ = { + isa = PBXFrameworksBuildPhase; + buildActionMask = 2147483647; + files = ( + ); + runOnlyForDeploymentPostprocessing = 0; + }; + AE9957731FA704B000397D38 /* Frameworks */ = { + isa = PBXFrameworksBuildPhase; + buildActionMask = 2147483647; + files = ( + ); + runOnlyForDeploymentPostprocessing = 0; + }; +/* End PBXFrameworksBuildPhase section */ + +/* Begin PBXGroup section */ + AE99574E1FA704AF00397D38 = { + isa = PBXGroup; + children = ( + AE9957591FA704AF00397D38 /* meetingRooms */, + AE99576E1FA704AF00397D38 /* meetingRoomsTests */, + AE9957791FA704B000397D38 /* meetingRoomsUITests */, + AE9957581FA704AF00397D38 /* Products */, + ); + sourceTree = ""; + }; + AE9957581FA704AF00397D38 /* Products */ = { + isa = PBXGroup; + children = ( + AE9957571FA704AF00397D38 /* meetingRooms.app */, + AE99576B1FA704AF00397D38 /* meetingRoomsTests.xctest */, + AE9957761FA704B000397D38 /* meetingRoomsUITests.xctest */, + ); + name = Products; + sourceTree = ""; + }; + AE9957591FA704AF00397D38 /* meetingRooms */ = { + isa = PBXGroup; + children = ( + AE99575A1FA704AF00397D38 /* AppDelegate.swift */, + AE99575C1FA704AF00397D38 /* ViewController.swift */, + AE99575E1FA704AF00397D38 /* Main.storyboard */, + AEB318A21FB4807F00AEB094 /* RoomInfoViewController.swift */, + AEB3189C1FB4641000AEB094 /* DataCenter.swift */, + AEB3189E1FB4684600AEB094 /* BranchListViewController.swift */, + AEB318A01FB4685800AEB094 /* ServiceListViewController.swift */, + AE9957881FA7054800397D38 /* MeetingRoomListViewController.swift */, + AE9957611FA704AF00397D38 /* Assets.xcassets */, + AE9957631FA704AF00397D38 /* LaunchScreen.storyboard */, + AE9957661FA704AF00397D38 /* Info.plist */, + ); + path = meetingRooms; + sourceTree = ""; + }; + AE99576E1FA704AF00397D38 /* meetingRoomsTests */ = { + isa = PBXGroup; + children = ( + AE99576F1FA704AF00397D38 /* meetingRoomsTests.swift */, + AE9957711FA704AF00397D38 /* Info.plist */, + ); + path = meetingRoomsTests; + sourceTree = ""; + }; + AE9957791FA704B000397D38 /* meetingRoomsUITests */ = { + isa = PBXGroup; + children = ( + AE99577A1FA704B000397D38 /* meetingRoomsUITests.swift */, + AE99577C1FA704B000397D38 /* Info.plist */, + ); + path = meetingRoomsUITests; + sourceTree = ""; + }; +/* End PBXGroup section */ + +/* Begin PBXNativeTarget section */ + AE9957561FA704AF00397D38 /* meetingRooms */ = { + isa = PBXNativeTarget; + buildConfigurationList = AE99577F1FA704B000397D38 /* Build configuration list for PBXNativeTarget "meetingRooms" */; + buildPhases = ( + AE9957531FA704AF00397D38 /* Sources */, + AE9957541FA704AF00397D38 /* Frameworks */, + AE9957551FA704AF00397D38 /* Resources */, + ); + buildRules = ( + ); + dependencies = ( + ); + name = meetingRooms; + productName = meetingRooms; + productReference = AE9957571FA704AF00397D38 /* meetingRooms.app */; + productType = "com.apple.product-type.application"; + }; + AE99576A1FA704AF00397D38 /* meetingRoomsTests */ = { + isa = PBXNativeTarget; + buildConfigurationList = AE9957821FA704B000397D38 /* Build configuration list for PBXNativeTarget "meetingRoomsTests" */; + buildPhases = ( + AE9957671FA704AF00397D38 /* Sources */, + AE9957681FA704AF00397D38 /* Frameworks */, + AE9957691FA704AF00397D38 /* Resources */, + ); + buildRules = ( + ); + dependencies = ( + AE99576D1FA704AF00397D38 /* PBXTargetDependency */, + ); + name = meetingRoomsTests; + productName = meetingRoomsTests; + productReference = AE99576B1FA704AF00397D38 /* meetingRoomsTests.xctest */; + productType = "com.apple.product-type.bundle.unit-test"; + }; + AE9957751FA704B000397D38 /* meetingRoomsUITests */ = { + isa = PBXNativeTarget; + buildConfigurationList = AE9957851FA704B000397D38 /* Build configuration list for PBXNativeTarget "meetingRoomsUITests" */; + buildPhases = ( + AE9957721FA704B000397D38 /* Sources */, + AE9957731FA704B000397D38 /* Frameworks */, + AE9957741FA704B000397D38 /* Resources */, + ); + buildRules = ( + ); + dependencies = ( + AE9957781FA704B000397D38 /* PBXTargetDependency */, + ); + name = meetingRoomsUITests; + productName = meetingRoomsUITests; + productReference = AE9957761FA704B000397D38 /* meetingRoomsUITests.xctest */; + productType = "com.apple.product-type.bundle.ui-testing"; + }; +/* End PBXNativeTarget section */ + +/* Begin PBXProject section */ + AE99574F1FA704AF00397D38 /* Project object */ = { + isa = PBXProject; + attributes = { + LastSwiftUpdateCheck = 0900; + LastUpgradeCheck = 0900; + ORGANIZATIONNAME = "황도증"; + TargetAttributes = { + AE9957561FA704AF00397D38 = { + CreatedOnToolsVersion = 9.0.1; + ProvisioningStyle = Automatic; + }; + AE99576A1FA704AF00397D38 = { + CreatedOnToolsVersion = 9.0.1; + ProvisioningStyle = Automatic; + TestTargetID = AE9957561FA704AF00397D38; + }; + AE9957751FA704B000397D38 = { + CreatedOnToolsVersion = 9.0.1; + ProvisioningStyle = Automatic; + TestTargetID = AE9957561FA704AF00397D38; + }; + }; + }; + buildConfigurationList = AE9957521FA704AF00397D38 /* Build configuration list for PBXProject "meetingRooms" */; + compatibilityVersion = "Xcode 8.0"; + developmentRegion = en; + hasScannedForEncodings = 0; + knownRegions = ( + en, + Base, + ); + mainGroup = AE99574E1FA704AF00397D38; + productRefGroup = AE9957581FA704AF00397D38 /* Products */; + projectDirPath = ""; + projectRoot = ""; + targets = ( + AE9957561FA704AF00397D38 /* meetingRooms */, + AE99576A1FA704AF00397D38 /* meetingRoomsTests */, + AE9957751FA704B000397D38 /* meetingRoomsUITests */, + ); + }; +/* End PBXProject section */ + +/* Begin PBXResourcesBuildPhase section */ + AE9957551FA704AF00397D38 /* Resources */ = { + isa = PBXResourcesBuildPhase; + buildActionMask = 2147483647; + files = ( + AE9957651FA704AF00397D38 /* LaunchScreen.storyboard in Resources */, + AE9957621FA704AF00397D38 /* Assets.xcassets in Resources */, + AE9957601FA704AF00397D38 /* Main.storyboard in Resources */, + ); + runOnlyForDeploymentPostprocessing = 0; + }; + AE9957691FA704AF00397D38 /* Resources */ = { + isa = PBXResourcesBuildPhase; + buildActionMask = 2147483647; + files = ( + ); + runOnlyForDeploymentPostprocessing = 0; + }; + AE9957741FA704B000397D38 /* Resources */ = { + isa = PBXResourcesBuildPhase; + buildActionMask = 2147483647; + files = ( + ); + runOnlyForDeploymentPostprocessing = 0; + }; +/* End PBXResourcesBuildPhase section */ + +/* Begin PBXSourcesBuildPhase section */ + AE9957531FA704AF00397D38 /* Sources */ = { + isa = PBXSourcesBuildPhase; + buildActionMask = 2147483647; + files = ( + AEB318A31FB4807F00AEB094 /* RoomInfoViewController.swift in Sources */, + AE99575D1FA704AF00397D38 /* ViewController.swift in Sources */, + AE99575B1FA704AF00397D38 /* AppDelegate.swift in Sources */, + AEB3189D1FB4641000AEB094 /* DataCenter.swift in Sources */, + AEB3189F1FB4684600AEB094 /* BranchListViewController.swift in Sources */, + AEB318A11FB4685800AEB094 /* ServiceListViewController.swift in Sources */, + AE9957891FA7054800397D38 /* MeetingRoomListViewController.swift in Sources */, + ); + runOnlyForDeploymentPostprocessing = 0; + }; + AE9957671FA704AF00397D38 /* Sources */ = { + isa = PBXSourcesBuildPhase; + buildActionMask = 2147483647; + files = ( + AE9957701FA704AF00397D38 /* meetingRoomsTests.swift in Sources */, + ); + runOnlyForDeploymentPostprocessing = 0; + }; + AE9957721FA704B000397D38 /* Sources */ = { + isa = PBXSourcesBuildPhase; + buildActionMask = 2147483647; + files = ( + AE99577B1FA704B000397D38 /* meetingRoomsUITests.swift in Sources */, + ); + runOnlyForDeploymentPostprocessing = 0; + }; +/* End PBXSourcesBuildPhase section */ + +/* Begin PBXTargetDependency section */ + AE99576D1FA704AF00397D38 /* PBXTargetDependency */ = { + isa = PBXTargetDependency; + target = AE9957561FA704AF00397D38 /* meetingRooms */; + targetProxy = AE99576C1FA704AF00397D38 /* PBXContainerItemProxy */; + }; + AE9957781FA704B000397D38 /* PBXTargetDependency */ = { + isa = PBXTargetDependency; + target = AE9957561FA704AF00397D38 /* meetingRooms */; + targetProxy = AE9957771FA704B000397D38 /* PBXContainerItemProxy */; + }; +/* End PBXTargetDependency section */ + +/* Begin PBXVariantGroup section */ + AE99575E1FA704AF00397D38 /* Main.storyboard */ = { + isa = PBXVariantGroup; + children = ( + AE99575F1FA704AF00397D38 /* Base */, + ); + name = Main.storyboard; + sourceTree = ""; + }; + AE9957631FA704AF00397D38 /* LaunchScreen.storyboard */ = { + isa = PBXVariantGroup; + children = ( + AE9957641FA704AF00397D38 /* Base */, + ); + name = LaunchScreen.storyboard; + sourceTree = ""; + }; +/* End PBXVariantGroup section */ + +/* Begin XCBuildConfiguration section */ + AE99577D1FA704B000397D38 /* Debug */ = { + isa = XCBuildConfiguration; + buildSettings = { + ALWAYS_SEARCH_USER_PATHS = NO; + CLANG_ANALYZER_NONNULL = YES; + CLANG_ANALYZER_NUMBER_OBJECT_CONVERSION = YES_AGGRESSIVE; + CLANG_CXX_LANGUAGE_STANDARD = "gnu++14"; + CLANG_CXX_LIBRARY = "libc++"; + CLANG_ENABLE_MODULES = YES; + CLANG_ENABLE_OBJC_ARC = YES; + CLANG_WARN_BLOCK_CAPTURE_AUTORELEASING = YES; + CLANG_WARN_BOOL_CONVERSION = YES; + CLANG_WARN_COMMA = YES; + CLANG_WARN_CONSTANT_CONVERSION = YES; + CLANG_WARN_DIRECT_OBJC_ISA_USAGE = YES_ERROR; + CLANG_WARN_DOCUMENTATION_COMMENTS = YES; + CLANG_WARN_EMPTY_BODY = YES; + CLANG_WARN_ENUM_CONVERSION = YES; + CLANG_WARN_INFINITE_RECURSION = YES; + CLANG_WARN_INT_CONVERSION = YES; + CLANG_WARN_NON_LITERAL_NULL_CONVERSION = YES; + CLANG_WARN_OBJC_LITERAL_CONVERSION = YES; + CLANG_WARN_OBJC_ROOT_CLASS = YES_ERROR; + CLANG_WARN_RANGE_LOOP_ANALYSIS = YES; + CLANG_WARN_STRICT_PROTOTYPES = YES; + CLANG_WARN_SUSPICIOUS_MOVE = YES; + CLANG_WARN_UNGUARDED_AVAILABILITY = YES_AGGRESSIVE; + CLANG_WARN_UNREACHABLE_CODE = YES; + CLANG_WARN__DUPLICATE_METHOD_MATCH = YES; + CODE_SIGN_IDENTITY = "iPhone Developer"; + COPY_PHASE_STRIP = NO; + DEBUG_INFORMATION_FORMAT = dwarf; + ENABLE_STRICT_OBJC_MSGSEND = YES; + ENABLE_TESTABILITY = YES; + GCC_C_LANGUAGE_STANDARD = gnu11; + GCC_DYNAMIC_NO_PIC = NO; + GCC_NO_COMMON_BLOCKS = YES; + GCC_OPTIMIZATION_LEVEL = 0; + GCC_PREPROCESSOR_DEFINITIONS = ( + "DEBUG=1", + "$(inherited)", + ); + GCC_WARN_64_TO_32_BIT_CONVERSION = YES; + GCC_WARN_ABOUT_RETURN_TYPE = YES_ERROR; + GCC_WARN_UNDECLARED_SELECTOR = YES; + GCC_WARN_UNINITIALIZED_AUTOS = YES_AGGRESSIVE; + GCC_WARN_UNUSED_FUNCTION = YES; + GCC_WARN_UNUSED_VARIABLE = YES; + IPHONEOS_DEPLOYMENT_TARGET = 11.0; + MTL_ENABLE_DEBUG_INFO = YES; + ONLY_ACTIVE_ARCH = YES; + SDKROOT = iphoneos; + SWIFT_ACTIVE_COMPILATION_CONDITIONS = DEBUG; + SWIFT_OPTIMIZATION_LEVEL = "-Onone"; + }; + name = Debug; + }; + AE99577E1FA704B000397D38 /* Release */ = { + isa = XCBuildConfiguration; + buildSettings = { + ALWAYS_SEARCH_USER_PATHS = NO; + CLANG_ANALYZER_NONNULL = YES; + CLANG_ANALYZER_NUMBER_OBJECT_CONVERSION = YES_AGGRESSIVE; + CLANG_CXX_LANGUAGE_STANDARD = "gnu++14"; + CLANG_CXX_LIBRARY = "libc++"; + CLANG_ENABLE_MODULES = YES; + CLANG_ENABLE_OBJC_ARC = YES; + CLANG_WARN_BLOCK_CAPTURE_AUTORELEASING = YES; + CLANG_WARN_BOOL_CONVERSION = YES; + CLANG_WARN_COMMA = YES; + CLANG_WARN_CONSTANT_CONVERSION = YES; + CLANG_WARN_DIRECT_OBJC_ISA_USAGE = YES_ERROR; + CLANG_WARN_DOCUMENTATION_COMMENTS = YES; + CLANG_WARN_EMPTY_BODY = YES; + CLANG_WARN_ENUM_CONVERSION = YES; + CLANG_WARN_INFINITE_RECURSION = YES; + CLANG_WARN_INT_CONVERSION = YES; + CLANG_WARN_NON_LITERAL_NULL_CONVERSION = YES; + CLANG_WARN_OBJC_LITERAL_CONVERSION = YES; + CLANG_WARN_OBJC_ROOT_CLASS = YES_ERROR; + CLANG_WARN_RANGE_LOOP_ANALYSIS = YES; + CLANG_WARN_STRICT_PROTOTYPES = YES; + CLANG_WARN_SUSPICIOUS_MOVE = YES; + CLANG_WARN_UNGUARDED_AVAILABILITY = YES_AGGRESSIVE; + CLANG_WARN_UNREACHABLE_CODE = YES; + CLANG_WARN__DUPLICATE_METHOD_MATCH = YES; + CODE_SIGN_IDENTITY = "iPhone Developer"; + COPY_PHASE_STRIP = NO; + DEBUG_INFORMATION_FORMAT = "dwarf-with-dsym"; + ENABLE_NS_ASSERTIONS = NO; + ENABLE_STRICT_OBJC_MSGSEND = YES; + GCC_C_LANGUAGE_STANDARD = gnu11; + GCC_NO_COMMON_BLOCKS = YES; + GCC_WARN_64_TO_32_BIT_CONVERSION = YES; + GCC_WARN_ABOUT_RETURN_TYPE = YES_ERROR; + GCC_WARN_UNDECLARED_SELECTOR = YES; + GCC_WARN_UNINITIALIZED_AUTOS = YES_AGGRESSIVE; + GCC_WARN_UNUSED_FUNCTION = YES; + GCC_WARN_UNUSED_VARIABLE = YES; + IPHONEOS_DEPLOYMENT_TARGET = 11.0; + MTL_ENABLE_DEBUG_INFO = NO; + SDKROOT = iphoneos; + SWIFT_OPTIMIZATION_LEVEL = "-Owholemodule"; + VALIDATE_PRODUCT = YES; + }; + name = Release; + }; + AE9957801FA704B000397D38 /* Debug */ = { + isa = XCBuildConfiguration; + buildSettings = { + ASSETCATALOG_COMPILER_APPICON_NAME = AppIcon; + CODE_SIGN_STYLE = Automatic; + INFOPLIST_FILE = meetingRooms/Info.plist; + LD_RUNPATH_SEARCH_PATHS = "$(inherited) @executable_path/Frameworks"; + PRODUCT_BUNDLE_IDENTIFIER = "--------.meetingRooms"; + PRODUCT_NAME = "$(TARGET_NAME)"; + SWIFT_VERSION = 4.0; + TARGETED_DEVICE_FAMILY = "1,2"; + }; + name = Debug; + }; + AE9957811FA704B000397D38 /* Release */ = { + isa = XCBuildConfiguration; + buildSettings = { + ASSETCATALOG_COMPILER_APPICON_NAME = AppIcon; + CODE_SIGN_STYLE = Automatic; + INFOPLIST_FILE = meetingRooms/Info.plist; + LD_RUNPATH_SEARCH_PATHS = "$(inherited) @executable_path/Frameworks"; + PRODUCT_BUNDLE_IDENTIFIER = "--------.meetingRooms"; + PRODUCT_NAME = "$(TARGET_NAME)"; + SWIFT_VERSION = 4.0; + TARGETED_DEVICE_FAMILY = "1,2"; + }; + name = Release; + }; + AE9957831FA704B000397D38 /* Debug */ = { + isa = XCBuildConfiguration; + buildSettings = { + ALWAYS_EMBED_SWIFT_STANDARD_LIBRARIES = YES; + BUNDLE_LOADER = "$(TEST_HOST)"; + CODE_SIGN_STYLE = Automatic; + INFOPLIST_FILE = meetingRoomsTests/Info.plist; + LD_RUNPATH_SEARCH_PATHS = "$(inherited) @executable_path/Frameworks @loader_path/Frameworks"; + PRODUCT_BUNDLE_IDENTIFIER = "--------.meetingRoomsTests"; + PRODUCT_NAME = "$(TARGET_NAME)"; + SWIFT_VERSION = 4.0; + TARGETED_DEVICE_FAMILY = "1,2"; + TEST_HOST = "$(BUILT_PRODUCTS_DIR)/meetingRooms.app/meetingRooms"; + }; + name = Debug; + }; + AE9957841FA704B000397D38 /* Release */ = { + isa = XCBuildConfiguration; + buildSettings = { + ALWAYS_EMBED_SWIFT_STANDARD_LIBRARIES = YES; + BUNDLE_LOADER = "$(TEST_HOST)"; + CODE_SIGN_STYLE = Automatic; + INFOPLIST_FILE = meetingRoomsTests/Info.plist; + LD_RUNPATH_SEARCH_PATHS = "$(inherited) @executable_path/Frameworks @loader_path/Frameworks"; + PRODUCT_BUNDLE_IDENTIFIER = "--------.meetingRoomsTests"; + PRODUCT_NAME = "$(TARGET_NAME)"; + SWIFT_VERSION = 4.0; + TARGETED_DEVICE_FAMILY = "1,2"; + TEST_HOST = "$(BUILT_PRODUCTS_DIR)/meetingRooms.app/meetingRooms"; + }; + name = Release; + }; + AE9957861FA704B000397D38 /* Debug */ = { + isa = XCBuildConfiguration; + buildSettings = { + ALWAYS_EMBED_SWIFT_STANDARD_LIBRARIES = YES; + CODE_SIGN_STYLE = Automatic; + INFOPLIST_FILE = meetingRoomsUITests/Info.plist; + LD_RUNPATH_SEARCH_PATHS = "$(inherited) @executable_path/Frameworks @loader_path/Frameworks"; + PRODUCT_BUNDLE_IDENTIFIER = "--------.meetingRoomsUITests"; + PRODUCT_NAME = "$(TARGET_NAME)"; + SWIFT_VERSION = 4.0; + TARGETED_DEVICE_FAMILY = "1,2"; + TEST_TARGET_NAME = meetingRooms; + }; + name = Debug; + }; + AE9957871FA704B000397D38 /* Release */ = { + isa = XCBuildConfiguration; + buildSettings = { + ALWAYS_EMBED_SWIFT_STANDARD_LIBRARIES = YES; + CODE_SIGN_STYLE = Automatic; + INFOPLIST_FILE = meetingRoomsUITests/Info.plist; + LD_RUNPATH_SEARCH_PATHS = "$(inherited) @executable_path/Frameworks @loader_path/Frameworks"; + PRODUCT_BUNDLE_IDENTIFIER = "--------.meetingRoomsUITests"; + PRODUCT_NAME = "$(TARGET_NAME)"; + SWIFT_VERSION = 4.0; + TARGETED_DEVICE_FAMILY = "1,2"; + TEST_TARGET_NAME = meetingRooms; + }; + name = Release; + }; +/* End XCBuildConfiguration section */ + +/* Begin XCConfigurationList section */ + AE9957521FA704AF00397D38 /* Build configuration list for PBXProject "meetingRooms" */ = { + isa = XCConfigurationList; + buildConfigurations = ( + AE99577D1FA704B000397D38 /* Debug */, + AE99577E1FA704B000397D38 /* Release */, + ); + defaultConfigurationIsVisible = 0; + defaultConfigurationName = Release; + }; + AE99577F1FA704B000397D38 /* Build configuration list for PBXNativeTarget "meetingRooms" */ = { + isa = XCConfigurationList; + buildConfigurations = ( + AE9957801FA704B000397D38 /* Debug */, + AE9957811FA704B000397D38 /* Release */, + ); + defaultConfigurationIsVisible = 0; + defaultConfigurationName = Release; + }; + AE9957821FA704B000397D38 /* Build configuration list for PBXNativeTarget "meetingRoomsTests" */ = { + isa = XCConfigurationList; + buildConfigurations = ( + AE9957831FA704B000397D38 /* Debug */, + AE9957841FA704B000397D38 /* Release */, + ); + defaultConfigurationIsVisible = 0; + defaultConfigurationName = Release; + }; + AE9957851FA704B000397D38 /* Build configuration list for PBXNativeTarget "meetingRoomsUITests" */ = { + isa = XCConfigurationList; + buildConfigurations = ( + AE9957861FA704B000397D38 /* Debug */, + AE9957871FA704B000397D38 /* Release */, + ); + defaultConfigurationIsVisible = 0; + defaultConfigurationName = Release; + }; +/* End XCConfigurationList section */ + }; + rootObject = AE99574F1FA704AF00397D38 /* Project object */; +} diff --git "a/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/meetingRooms_cell accessory&modal/meetingRooms.xcodeproj/project.xcworkspace/contents.xcworkspacedata" "b/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/meetingRooms_cell accessory&modal/meetingRooms.xcodeproj/project.xcworkspace/contents.xcworkspacedata" new file mode 100644 index 0000000..8491799 --- /dev/null +++ "b/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/meetingRooms_cell accessory&modal/meetingRooms.xcodeproj/project.xcworkspace/contents.xcworkspacedata" @@ -0,0 +1,7 @@ + + + + + diff --git "a/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/meetingRooms_cell accessory&modal/meetingRooms/AppDelegate.swift" "b/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/meetingRooms_cell accessory&modal/meetingRooms/AppDelegate.swift" new file mode 100644 index 0000000..fc60321 --- /dev/null +++ "b/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/meetingRooms_cell accessory&modal/meetingRooms/AppDelegate.swift" @@ -0,0 +1,46 @@ +// +// AppDelegate.swift +// meetingRooms +// +// Created by 황도증 on 2017. 10. 30.. +// Copyright © 2017년 황도증. All rights reserved. +// + +import UIKit + +@UIApplicationMain +class AppDelegate: UIResponder, UIApplicationDelegate { + + var window: UIWindow? + + + func application(_ application: UIApplication, didFinishLaunchingWithOptions launchOptions: [UIApplicationLaunchOptionsKey: Any]?) -> Bool { + // Override point for customization after application launch. + return true + } + + func applicationWillResignActive(_ application: UIApplication) { + // Sent when the application is about to move from active to inactive state. This can occur for certain types of temporary interruptions (such as an incoming phone call or SMS message) or when the user quits the application and it begins the transition to the background state. + // Use this method to pause ongoing tasks, disable timers, and invalidate graphics rendering callbacks. Games should use this method to pause the game. + } + + func applicationDidEnterBackground(_ application: UIApplication) { + // Use this method to release shared resources, save user data, invalidate timers, and store enough application state information to restore your application to its current state in case it is terminated later. + // If your application supports background execution, this method is called instead of applicationWillTerminate: when the user quits. + } + + func applicationWillEnterForeground(_ application: UIApplication) { + // Called as part of the transition from the background to the active state; here you can undo many of the changes made on entering the background. + } + + func applicationDidBecomeActive(_ application: UIApplication) { + // Restart any tasks that were paused (or not yet started) while the application was inactive. If the application was previously in the background, optionally refresh the user interface. + } + + func applicationWillTerminate(_ application: UIApplication) { + // Called when the application is about to terminate. Save data if appropriate. See also applicationDidEnterBackground:. + } + + +} + diff --git "a/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/meetingRooms_cell accessory&modal/meetingRooms/Assets.xcassets/AppIcon.appiconset/Contents.json" "b/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/meetingRooms_cell accessory&modal/meetingRooms/Assets.xcassets/AppIcon.appiconset/Contents.json" new file mode 100644 index 0000000..d8db8d6 --- /dev/null +++ "b/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/meetingRooms_cell accessory&modal/meetingRooms/Assets.xcassets/AppIcon.appiconset/Contents.json" @@ -0,0 +1,98 @@ +{ + "images" : [ + { + "idiom" : "iphone", + "size" : "20x20", + "scale" : "2x" + }, + { + "idiom" : "iphone", + "size" : "20x20", + "scale" : "3x" + }, + { + "idiom" : "iphone", + "size" : "29x29", + "scale" : "2x" + }, + { + "idiom" : "iphone", + "size" : "29x29", + "scale" : "3x" + }, + { + "idiom" : "iphone", + "size" : "40x40", + "scale" : "2x" + }, + { + "idiom" : "iphone", + "size" : "40x40", + "scale" : "3x" + }, + { + "idiom" : "iphone", + "size" : "60x60", + "scale" : "2x" + }, + { + "idiom" : "iphone", + "size" : "60x60", + "scale" : "3x" + }, + { + "idiom" : "ipad", + "size" : "20x20", + "scale" : "1x" + }, + { + "idiom" : "ipad", + "size" : "20x20", + "scale" : "2x" + }, + { + "idiom" : "ipad", + "size" : "29x29", + "scale" : "1x" + }, + { + "idiom" : "ipad", + "size" : "29x29", + "scale" : "2x" + }, + { + "idiom" : "ipad", + "size" : "40x40", + "scale" : "1x" + }, + { + "idiom" : "ipad", + "size" : "40x40", + "scale" : "2x" + }, + { + "idiom" : "ipad", + "size" : "76x76", + "scale" : "1x" + }, + { + "idiom" : "ipad", + "size" : "76x76", + "scale" : "2x" + }, + { + "idiom" : "ipad", + "size" : "83.5x83.5", + "scale" : "2x" + }, + { + "idiom" : "ios-marketing", + "size" : "1024x1024", + "scale" : "1x" + } + ], + "info" : { + "version" : 1, + "author" : "xcode" + } +} \ No newline at end of file diff --git "a/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/meetingRooms_cell accessory&modal/meetingRooms/Base.lproj/LaunchScreen.storyboard" "b/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/meetingRooms_cell accessory&modal/meetingRooms/Base.lproj/LaunchScreen.storyboard" new file mode 100644 index 0000000..f83f6fd --- /dev/null +++ "b/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/meetingRooms_cell accessory&modal/meetingRooms/Base.lproj/LaunchScreen.storyboard" @@ -0,0 +1,25 @@ + + + + + + + + + + + + + + + + + + + + + + + + + diff --git "a/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/meetingRooms_cell accessory&modal/meetingRooms/Base.lproj/Main.storyboard" "b/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/meetingRooms_cell accessory&modal/meetingRooms/Base.lproj/Main.storyboard" new file mode 100644 index 0000000..c995b69 --- /dev/null +++ "b/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/meetingRooms_cell accessory&modal/meetingRooms/Base.lproj/Main.storyboard" @@ -0,0 +1,389 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + diff --git "a/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/meetingRooms_cell accessory&modal/meetingRooms/BranchListViewController.swift" "b/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/meetingRooms_cell accessory&modal/meetingRooms/BranchListViewController.swift" new file mode 100644 index 0000000..fa28525 --- /dev/null +++ "b/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/meetingRooms_cell accessory&modal/meetingRooms/BranchListViewController.swift" @@ -0,0 +1,119 @@ +// +// BranchListViewController.swift +// meetingRooms +// +// Created by 황도증 on 2017. 11. 9.. +// Copyright © 2017년 황도증. All rights reserved. +// + +import UIKit + +class BranchListViewController: UITableViewController { + + override func viewDidLoad() { + super.viewDidLoad() + + // Uncomment the following line to preserve selection between presentations + // self.clearsSelectionOnViewWillAppear = false + + // Uncomment the following line to display an Edit button in the navigation bar for this view controller. + // self.navigationItem.rightBarButtonItem = self.editButtonItem + + self.navigationController?.isToolbarHidden = true + } + + override func didReceiveMemoryWarning() { + super.didReceiveMemoryWarning() + // Dispose of any resources that can be recreated. + } + + // MARK: - Table view data source + + override func numberOfSections(in tableView: UITableView) -> Int { + // #warning Incomplete implementation, return the number of sections + return 1 + } + + @IBAction func locationTurnOn(_ sender: Any) { + let locationAlert = UIAlertController(title:"위치정보요청", message: "위치정보를 기반으로 가까운 지점을 자동으로 선택할 수 있습니다.", preferredStyle: .actionSheet) + + let locationAction = UIAlertAction(title: "위치정보켜기", style: .default, handler: {(action:UIAlertAction) -> Void in print("위치정보켜기 선택")}) + + let openMapAction = UIAlertAction(title: "지도에서 열기", style: .default, handler: {(action:UIAlertAction) -> Void in print("지도앱에서 열기 선택")}) + + locationAlert.addAction(locationAction) + locationAlert.addAction(openMapAction) + + self.present(locationAlert, animated: true, completion: nil) + } + override func tableView(_ tableView: UITableView, numberOfRowsInSection section: Int) -> Int { + // #warning Incomplete implementation, return the number of rows + let rowCount = dataCenter.branches.count + return rowCount + } + + + override func tableView(_ tableView: UITableView, cellForRowAt indexPath: IndexPath) -> UITableViewCell { + let cell = tableView.dequeueReusableCell(withIdentifier: "BranchCell", for: indexPath) + + // Configure the cell... + let branch = dataCenter.branches[indexPath.row] + cell.textLabel?.text = branch.name + + return cell + } + + + /* + // Override to support conditional editing of the table view. + override func tableView(_ tableView: UITableView, canEditRowAt indexPath: IndexPath) -> Bool { + // Return false if you do not want the specified item to be editable. + return true + } + */ + + /* + // Override to support editing the table view. + override func tableView(_ tableView: UITableView, commit editingStyle: UITableViewCellEditingStyle, forRowAt indexPath: IndexPath) { + if editingStyle == .delete { + // Delete the row from the data source + tableView.deleteRows(at: [indexPath], with: .fade) + } else if editingStyle == .insert { + // Create a new instance of the appropriate class, insert it into the array, and add a new row to the table view + } + } + */ + + /* + // Override to support rearranging the table view. + override func tableView(_ tableView: UITableView, moveRowAt fromIndexPath: IndexPath, to: IndexPath) { + + } + */ + + /* + // Override to support conditional rearranging of the table view. + override func tableView(_ tableView: UITableView, canMoveRowAt indexPath: IndexPath) -> Bool { + // Return false if you do not want the item to be re-orderable. + return true + } + */ + + + // MARK: - Navigation + + // In a storyboard-based application, you will often want to do a little preparation before navigation + override func prepare(for segue: UIStoryboardSegue, sender: Any?) { + // Get the new view controller using segue.destinationViewController. + // Pass the selected object to the new view controller. + + if segue.identifier == "ServiceSegue" { + if let destination = segue.destination as? ServiceListViewController { + if let selectedIndex = self.tableView.indexPathForSelectedRow?.row { + destination.branch = dataCenter.branches[selectedIndex] as Branch + } + } + } + + } +} diff --git "a/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/meetingRooms_cell accessory&modal/meetingRooms/DataCenter.swift" "b/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/meetingRooms_cell accessory&modal/meetingRooms/DataCenter.swift" new file mode 100644 index 0000000..4231269 --- /dev/null +++ "b/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/meetingRooms_cell accessory&modal/meetingRooms/DataCenter.swift" @@ -0,0 +1,66 @@ +// +// DataCenter.swift +// meetingRooms +// +// Created by 황도증 on 2017. 11. 9.. +// Copyright © 2017년 황도증. All rights reserved. +// + +import Foundation + +let dataCenter:DataCenter = DataCenter() + +class DataCenter { + var branches:[Branch] = [] + + init (){ + let banksyRoom = MeetingRoom(name:"Banksy", capacity: 4) + let kahloRoom = MeetingRoom(name:"Kahlo", capacity: 8) + let riveraRoom = MeetingRoom(name:"Rivera", capacity: 8) + let picasoRoom = MeetingRoom(name:"Picaso", capacity: 10) + + let vehicleService = Service(name: "차량예약") + let meetingRoomService = Service(name: "회의실예약") + let visitorService = Service(name: "방문자예약") + let deskService = Service(name: "데스크예약") + meetingRoomService.items = [banksyRoom, kahloRoom, riveraRoom, picasoRoom] + + let pangyoBranch = Branch(name: "판교점") + let samsungBranch = Branch(name: "삼성점") + let yeoksamBranch = Branch(name: "역삼점") + let sinrimBranch = Branch(name: "신림점") + let songdooBranch = Branch(name: "송도점") + let anamBranch = Branch(name: "안암점") + pangyoBranch.services = [vehicleService, meetingRoomService, visitorService, deskService] + + branches += [pangyoBranch, samsungBranch, yeoksamBranch, sinrimBranch, songdooBranch, anamBranch] + } +} + +class Branch { + let name:String + var services:[Service]? + + init(name:String) { + self.name = name + } +} + +class Service { + let name:String + var items:[MeetingRoom]? + + init(name:String) { + self.name = name + } +} + +class MeetingRoom { + let name:String + let capacity:Int + + init(name:String, capacity:Int) { + self.name = name + self.capacity = capacity + } +} diff --git "a/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/meetingRooms_cell accessory&modal/meetingRooms/Info.plist" "b/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/meetingRooms_cell accessory&modal/meetingRooms/Info.plist" new file mode 100644 index 0000000..16be3b6 --- /dev/null +++ "b/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/meetingRooms_cell accessory&modal/meetingRooms/Info.plist" @@ -0,0 +1,45 @@ + + + + + CFBundleDevelopmentRegion + $(DEVELOPMENT_LANGUAGE) + CFBundleExecutable + $(EXECUTABLE_NAME) + CFBundleIdentifier + $(PRODUCT_BUNDLE_IDENTIFIER) + CFBundleInfoDictionaryVersion + 6.0 + CFBundleName + $(PRODUCT_NAME) + CFBundlePackageType + APPL + CFBundleShortVersionString + 1.0 + CFBundleVersion + 1 + LSRequiresIPhoneOS + + UILaunchStoryboardName + LaunchScreen + UIMainStoryboardFile + Main + UIRequiredDeviceCapabilities + + armv7 + + UISupportedInterfaceOrientations + + UIInterfaceOrientationPortrait + UIInterfaceOrientationLandscapeLeft + UIInterfaceOrientationLandscapeRight + + UISupportedInterfaceOrientations~ipad + + UIInterfaceOrientationPortrait + UIInterfaceOrientationPortraitUpsideDown + UIInterfaceOrientationLandscapeLeft + UIInterfaceOrientationLandscapeRight + + + diff --git "a/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/meetingRooms_cell accessory&modal/meetingRooms/MeetingRoomListViewController.swift" "b/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/meetingRooms_cell accessory&modal/meetingRooms/MeetingRoomListViewController.swift" new file mode 100644 index 0000000..0d523b3 --- /dev/null +++ "b/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/meetingRooms_cell accessory&modal/meetingRooms/MeetingRoomListViewController.swift" @@ -0,0 +1,111 @@ +// +// MeetingRoomListViewController.swift +// meetingRooms +// +// Created by 황도증 on 2017. 10. 30.. +// Copyright © 2017년 황도증. All rights reserved. +// + +import UIKit + +class MeetingRoomListViewController: UITableViewController { + + var service:Service? + + override func viewDidLoad() { + super.viewDidLoad() + + // Uncomment the following line to preserve selection between presentations + // self.clearsSelectionOnViewWillAppear = false + + // Uncomment the following line to display an Edit button in the navigation bar for this view controller. + // self.navigationItem.rightBarButtonItem = self.editButtonItem + + self.title = service?.name + } + + override func didReceiveMemoryWarning() { + super.didReceiveMemoryWarning() + // Dispose of any resources that can be recreated. + } + + // MARK: - Table view data source + + override func numberOfSections(in tableView: UITableView) -> Int { + // #warning Incomplete implementation, return the number of sections + return 1 + } + + override func tableView(_ tableView: UITableView, numberOfRowsInSection section: Int) -> Int { + // #warning Incomplete implementation, return the number of rows + //let categoryValues = Array(meetingRooms.values)[section] + //let orderMeetingRoooms = meetingRooms.sorted(by: {$0.1.first!.1 < $1.1.first!.1}) + guard let rowCount = service?.items?.count else { + return 0 + } + return rowCount + } + + + override func tableView(_ tableView: UITableView, cellForRowAt indexPath: IndexPath) -> UITableViewCell { + let cell = tableView.dequeueReusableCell(withIdentifier: "ItemCell", for: indexPath) + + //let orderMeetingRoooms = meetingRooms.sorted(by: {$0.1.first!.1 < $1.1.first!.1}) + // Configure the cell... + //let categoryValue = Array(meetingRooms.values)[indexPath.section] + + guard let meetingRoom = service?.items?[indexPath.row] else { + return cell + } + + cell.textLabel!.text = meetingRoom.name + cell.detailTextLabel!.text = String(meetingRoom.capacity) + return cell + } + + /* + // Override to support conditional editing of the table view. + override func tableView(_ tableView: UITableView, canEditRowAt indexPath: IndexPath) -> Bool { + // Return false if you do not want the specified item to be editable. + return true + } + */ + + /* + // Override to support editing the table view. + override func tableView(_ tableView: UITableView, commit editingStyle: UITableViewCellEditingStyle, forRowAt indexPath: IndexPath) { + if editingStyle == .delete { + // Delete the row from the data source + tableView.deleteRows(at: [indexPath], with: .fade) + } else if editingStyle == .insert { + // Create a new instance of the appropriate class, insert it into the array, and add a new row to the table view + } + } + */ + + /* + // Override to support rearranging the table view. + override func tableView(_ tableView: UITableView, moveRowAt fromIndexPath: IndexPath, to: IndexPath) { + + } + */ + + /* + // Override to support conditional rearranging of the table view. + override func tableView(_ tableView: UITableView, canMoveRowAt indexPath: IndexPath) -> Bool { + // Return false if you do not want the item to be re-orderable. + return true + } + */ + + + // MARK: - Navigation +/* + // In a storyboard-based application, you will often want to do a little preparation before navigation + override func prepare(for segue: UIStoryboardSegue, sender: Any?) { + // Get the new view controller using segue.destinationViewController. + // Pass the selected object to the new view controller. + + } + */ +} diff --git "a/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/meetingRooms_cell accessory&modal/meetingRooms/RoomInfoViewController.swift" "b/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/meetingRooms_cell accessory&modal/meetingRooms/RoomInfoViewController.swift" new file mode 100644 index 0000000..61bf80d --- /dev/null +++ "b/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/meetingRooms_cell accessory&modal/meetingRooms/RoomInfoViewController.swift" @@ -0,0 +1,98 @@ +// +// RoomInfoViewController.swift +// meetingRooms +// +// Created by 황도증 on 2017. 11. 9.. +// Copyright © 2017년 황도증. All rights reserved. +// + +import UIKit + +class RoomInfoViewController: UITableViewController { + + override func viewDidLoad() { + super.viewDidLoad() + + // Uncomment the following line to preserve selection between presentations + // self.clearsSelectionOnViewWillAppear = false + + // Uncomment the following line to display an Edit button in the navigation bar for this view controller. + // self.navigationItem.rightBarButtonItem = self.editButtonItem + } + + override func didReceiveMemoryWarning() { + super.didReceiveMemoryWarning() + // Dispose of any resources that can be recreated. + } + @IBAction func modalDismiss(_ sender: Any) { + self.dismiss(animated: true, completion: nil) + } + /* + // MARK: - Table view data source + + override func numberOfSections(in tableView: UITableView) -> Int { + // #warning Incomplete implementation, return the number of sections + return 0 + } + + override func tableView(_ tableView: UITableView, numberOfRowsInSection section: Int) -> Int { + // #warning Incomplete implementation, return the number of rows + return 0 + } +*/ + /* + override func tableView(_ tableView: UITableView, cellForRowAt indexPath: IndexPath) -> UITableViewCell { + let cell = tableView.dequeueReusableCell(withIdentifier: "reuseIdentifier", for: indexPath) + + // Configure the cell... + + return cell + } + */ + + /* + // Override to support conditional editing of the table view. + override func tableView(_ tableView: UITableView, canEditRowAt indexPath: IndexPath) -> Bool { + // Return false if you do not want the specified item to be editable. + return true + } + */ + + /* + // Override to support editing the table view. + override func tableView(_ tableView: UITableView, commit editingStyle: UITableViewCellEditingStyle, forRowAt indexPath: IndexPath) { + if editingStyle == .delete { + // Delete the row from the data source + tableView.deleteRows(at: [indexPath], with: .fade) + } else if editingStyle == .insert { + // Create a new instance of the appropriate class, insert it into the array, and add a new row to the table view + } + } + */ + + /* + // Override to support rearranging the table view. + override func tableView(_ tableView: UITableView, moveRowAt fromIndexPath: IndexPath, to: IndexPath) { + + } + */ + + /* + // Override to support conditional rearranging of the table view. + override func tableView(_ tableView: UITableView, canMoveRowAt indexPath: IndexPath) -> Bool { + // Return false if you do not want the item to be re-orderable. + return true + } + */ + + /* + // MARK: - Navigation + + // In a storyboard-based application, you will often want to do a little preparation before navigation + override func prepare(for segue: UIStoryboardSegue, sender: Any?) { + // Get the new view controller using segue.destinationViewController. + // Pass the selected object to the new view controller. + } + */ + +} diff --git "a/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/meetingRooms_cell accessory&modal/meetingRooms/ServiceListViewController.swift" "b/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/meetingRooms_cell accessory&modal/meetingRooms/ServiceListViewController.swift" new file mode 100644 index 0000000..091d906 --- /dev/null +++ "b/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/meetingRooms_cell accessory&modal/meetingRooms/ServiceListViewController.swift" @@ -0,0 +1,113 @@ +// +// ServiceListViewController.swift +// meetingRooms +// +// Created by 황도증 on 2017. 11. 9.. +// Copyright © 2017년 황도증. All rights reserved. +// + +import UIKit + +class ServiceListViewController: UITableViewController { + + var branch:Branch? + + override func viewDidLoad() { + super.viewDidLoad() + + // Uncomment the following line to preserve selection between presentations + // self.clearsSelectionOnViewWillAppear = false + + // Uncomment the following line to display an Edit button in the navigation bar for this view controller. + // self.navigationItem.rightBarButtonItem = self.editButtonItem + self.title = branch?.name + self.navigationController?.isToolbarHidden = false + } + + override func didReceiveMemoryWarning() { + super.didReceiveMemoryWarning() + // Dispose of any resources that can be recreated. + } + + // MARK: - Table view data source + + override func numberOfSections(in tableView: UITableView) -> Int { + // #warning Incomplete implementation, return the number of sections + return 1 + } + + override func tableView(_ tableView: UITableView, numberOfRowsInSection section: Int) -> Int { + // #warning Incomplete implementation, return the number of rows + guard let rowCount = branch?.services?.count else { + return 0 + } + return rowCount + } + + + override func tableView(_ tableView: UITableView, cellForRowAt indexPath: IndexPath) -> UITableViewCell { + let cell = tableView.dequeueReusableCell(withIdentifier: "ServiceCell", for: indexPath) + + // Configure the cell... + guard let service = branch?.services?[indexPath.row] else { + return cell + } + + cell.textLabel?.text = service.name + + return cell + } + + + /* + // Override to support conditional editing of the table view. + override func tableView(_ tableView: UITableView, canEditRowAt indexPath: IndexPath) -> Bool { + // Return false if you do not want the specified item to be editable. + return true + } + */ + + /* + // Override to support editing the table view. + override func tableView(_ tableView: UITableView, commit editingStyle: UITableViewCellEditingStyle, forRowAt indexPath: IndexPath) { + if editingStyle == .delete { + // Delete the row from the data source + tableView.deleteRows(at: [indexPath], with: .fade) + } else if editingStyle == .insert { + // Create a new instance of the appropriate class, insert it into the array, and add a new row to the table view + } + } + */ + + /* + // Override to support rearranging the table view. + override func tableView(_ tableView: UITableView, moveRowAt fromIndexPath: IndexPath, to: IndexPath) { + + } + */ + + /* + // Override to support conditional rearranging of the table view. + override func tableView(_ tableView: UITableView, canMoveRowAt indexPath: IndexPath) -> Bool { + // Return false if you do not want the item to be re-orderable. + return true + } + */ + + + // MARK: - Navigation + + // In a storyboard-based application, you will often want to do a little preparation before navigation + override func prepare(for segue: UIStoryboardSegue, sender: Any?) { + // Get the new view controller using segue.destinationViewController. + // Pass the selected object to the new view controller. + if segue.identifier == "MeetingRoomSegue" { + guard let destination = segue.destination as? MeetingRoomListViewController, let selectedIndex = self.tableView.indexPathForSelectedRow?.row, let service = branch?.services?[selectedIndex] else { + return + } + destination.service = service + } + } + + +} diff --git "a/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/meetingRooms_cell accessory&modal/meetingRooms/ViewController.swift" "b/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/meetingRooms_cell accessory&modal/meetingRooms/ViewController.swift" new file mode 100644 index 0000000..24bd9b0 --- /dev/null +++ "b/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/meetingRooms_cell accessory&modal/meetingRooms/ViewController.swift" @@ -0,0 +1,25 @@ +// +// ViewController.swift +// meetingRooms +// +// Created by 황도증 on 2017. 10. 30.. +// Copyright © 2017년 황도증. All rights reserved. +// + +import UIKit + +class ViewController: UIViewController { + + override func viewDidLoad() { + super.viewDidLoad() + // Do any additional setup after loading the view, typically from a nib. + } + + override func didReceiveMemoryWarning() { + super.didReceiveMemoryWarning() + // Dispose of any resources that can be recreated. + } + + +} + diff --git "a/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/meetingRooms_cell accessory&modal/meetingRoomsTests/Info.plist" "b/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/meetingRooms_cell accessory&modal/meetingRoomsTests/Info.plist" new file mode 100644 index 0000000..6c40a6c --- /dev/null +++ "b/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/meetingRooms_cell accessory&modal/meetingRoomsTests/Info.plist" @@ -0,0 +1,22 @@ + + + + + CFBundleDevelopmentRegion + $(DEVELOPMENT_LANGUAGE) + CFBundleExecutable + $(EXECUTABLE_NAME) + CFBundleIdentifier + $(PRODUCT_BUNDLE_IDENTIFIER) + CFBundleInfoDictionaryVersion + 6.0 + CFBundleName + $(PRODUCT_NAME) + CFBundlePackageType + BNDL + CFBundleShortVersionString + 1.0 + CFBundleVersion + 1 + + diff --git "a/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/meetingRooms_cell accessory&modal/meetingRoomsTests/meetingRoomsTests.swift" "b/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/meetingRooms_cell accessory&modal/meetingRoomsTests/meetingRoomsTests.swift" new file mode 100644 index 0000000..bfbd8d6 --- /dev/null +++ "b/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/meetingRooms_cell accessory&modal/meetingRoomsTests/meetingRoomsTests.swift" @@ -0,0 +1,36 @@ +// +// meetingRoomsTests.swift +// meetingRoomsTests +// +// Created by 황도증 on 2017. 10. 30.. +// Copyright © 2017년 황도증. All rights reserved. +// + +import XCTest +@testable import meetingRooms + +class meetingRoomsTests: XCTestCase { + + override func setUp() { + super.setUp() + // Put setup code here. This method is called before the invocation of each test method in the class. + } + + override func tearDown() { + // Put teardown code here. This method is called after the invocation of each test method in the class. + super.tearDown() + } + + func testExample() { + // This is an example of a functional test case. + // Use XCTAssert and related functions to verify your tests produce the correct results. + } + + func testPerformanceExample() { + // This is an example of a performance test case. + self.measure { + // Put the code you want to measure the time of here. + } + } + +} diff --git "a/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/meetingRooms_cell accessory&modal/meetingRoomsUITests/Info.plist" "b/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/meetingRooms_cell accessory&modal/meetingRoomsUITests/Info.plist" new file mode 100644 index 0000000..6c40a6c --- /dev/null +++ "b/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/meetingRooms_cell accessory&modal/meetingRoomsUITests/Info.plist" @@ -0,0 +1,22 @@ + + + + + CFBundleDevelopmentRegion + $(DEVELOPMENT_LANGUAGE) + CFBundleExecutable + $(EXECUTABLE_NAME) + CFBundleIdentifier + $(PRODUCT_BUNDLE_IDENTIFIER) + CFBundleInfoDictionaryVersion + 6.0 + CFBundleName + $(PRODUCT_NAME) + CFBundlePackageType + BNDL + CFBundleShortVersionString + 1.0 + CFBundleVersion + 1 + + diff --git "a/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/meetingRooms_cell accessory&modal/meetingRoomsUITests/meetingRoomsUITests.swift" "b/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/meetingRooms_cell accessory&modal/meetingRoomsUITests/meetingRoomsUITests.swift" new file mode 100644 index 0000000..4873bfa --- /dev/null +++ "b/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/meetingRooms_cell accessory&modal/meetingRoomsUITests/meetingRoomsUITests.swift" @@ -0,0 +1,36 @@ +// +// meetingRoomsUITests.swift +// meetingRoomsUITests +// +// Created by 황도증 on 2017. 10. 30.. +// Copyright © 2017년 황도증. All rights reserved. +// + +import XCTest + +class meetingRoomsUITests: XCTestCase { + + override func setUp() { + super.setUp() + + // Put setup code here. This method is called before the invocation of each test method in the class. + + // In UI tests it is usually best to stop immediately when a failure occurs. + continueAfterFailure = false + // UI tests must launch the application that they test. Doing this in setup will make sure it happens for each test method. + XCUIApplication().launch() + + // In UI tests it’s important to set the initial state - such as interface orientation - required for your tests before they run. The setUp method is a good place to do this. + } + + override func tearDown() { + // Put teardown code here. This method is called after the invocation of each test method in the class. + super.tearDown() + } + + func testExample() { + // Use recording to get started writing UI tests. + // Use XCTAssert and related functions to verify your tests produce the correct results. + } + +} diff --git "a/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/meetingRooms_modal present/meetingRooms.xcodeproj/project.pbxproj" "b/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/meetingRooms_modal present/meetingRooms.xcodeproj/project.pbxproj" new file mode 100644 index 0000000..fd9c07f --- /dev/null +++ "b/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/meetingRooms_modal present/meetingRooms.xcodeproj/project.pbxproj" @@ -0,0 +1,585 @@ +// !$*UTF8*$! +{ + archiveVersion = 1; + classes = { + }; + objectVersion = 48; + objects = { + +/* Begin PBXBuildFile section */ + AE99575B1FA704AF00397D38 /* AppDelegate.swift in Sources */ = {isa = PBXBuildFile; fileRef = AE99575A1FA704AF00397D38 /* AppDelegate.swift */; }; + AE99575D1FA704AF00397D38 /* ViewController.swift in Sources */ = {isa = PBXBuildFile; fileRef = AE99575C1FA704AF00397D38 /* ViewController.swift */; }; + AE9957601FA704AF00397D38 /* Main.storyboard in Resources */ = {isa = PBXBuildFile; fileRef = AE99575E1FA704AF00397D38 /* Main.storyboard */; }; + AE9957621FA704AF00397D38 /* Assets.xcassets in Resources */ = {isa = PBXBuildFile; fileRef = AE9957611FA704AF00397D38 /* Assets.xcassets */; }; + AE9957651FA704AF00397D38 /* LaunchScreen.storyboard in Resources */ = {isa = PBXBuildFile; fileRef = AE9957631FA704AF00397D38 /* LaunchScreen.storyboard */; }; + AE9957701FA704AF00397D38 /* meetingRoomsTests.swift in Sources */ = {isa = PBXBuildFile; fileRef = AE99576F1FA704AF00397D38 /* meetingRoomsTests.swift */; }; + AE99577B1FA704B000397D38 /* meetingRoomsUITests.swift in Sources */ = {isa = PBXBuildFile; fileRef = AE99577A1FA704B000397D38 /* meetingRoomsUITests.swift */; }; + AE9957891FA7054800397D38 /* MeetingRoomListViewController.swift in Sources */ = {isa = PBXBuildFile; fileRef = AE9957881FA7054800397D38 /* MeetingRoomListViewController.swift */; }; + AEB3189D1FB4641000AEB094 /* DataCenter.swift in Sources */ = {isa = PBXBuildFile; fileRef = AEB3189C1FB4641000AEB094 /* DataCenter.swift */; }; + AEB3189F1FB4684600AEB094 /* BranchListViewController.swift in Sources */ = {isa = PBXBuildFile; fileRef = AEB3189E1FB4684600AEB094 /* BranchListViewController.swift */; }; + AEB318A11FB4685800AEB094 /* ServiceListViewController.swift in Sources */ = {isa = PBXBuildFile; fileRef = AEB318A01FB4685800AEB094 /* ServiceListViewController.swift */; }; + AEB318A31FB4807F00AEB094 /* RoomInfoViewController.swift in Sources */ = {isa = PBXBuildFile; fileRef = AEB318A21FB4807F00AEB094 /* RoomInfoViewController.swift */; }; + AEB318A51FB485D300AEB094 /* ReservationListViewController.swift in Sources */ = {isa = PBXBuildFile; fileRef = AEB318A41FB485D300AEB094 /* ReservationListViewController.swift */; }; + AEB318A71FB4861600AEB094 /* ReserveRoomViewController.swift in Sources */ = {isa = PBXBuildFile; fileRef = AEB318A61FB4861600AEB094 /* ReserveRoomViewController.swift */; }; +/* End PBXBuildFile section */ + +/* Begin PBXContainerItemProxy section */ + AE99576C1FA704AF00397D38 /* PBXContainerItemProxy */ = { + isa = PBXContainerItemProxy; + containerPortal = AE99574F1FA704AF00397D38 /* Project object */; + proxyType = 1; + remoteGlobalIDString = AE9957561FA704AF00397D38; + remoteInfo = meetingRooms; + }; + AE9957771FA704B000397D38 /* PBXContainerItemProxy */ = { + isa = PBXContainerItemProxy; + containerPortal = AE99574F1FA704AF00397D38 /* Project object */; + proxyType = 1; + remoteGlobalIDString = AE9957561FA704AF00397D38; + remoteInfo = meetingRooms; + }; +/* End PBXContainerItemProxy section */ + +/* Begin PBXFileReference section */ + AE9957571FA704AF00397D38 /* meetingRooms.app */ = {isa = PBXFileReference; explicitFileType = wrapper.application; includeInIndex = 0; path = meetingRooms.app; sourceTree = BUILT_PRODUCTS_DIR; }; + AE99575A1FA704AF00397D38 /* AppDelegate.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = AppDelegate.swift; sourceTree = ""; }; + AE99575C1FA704AF00397D38 /* ViewController.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = ViewController.swift; sourceTree = ""; }; + AE99575F1FA704AF00397D38 /* Base */ = {isa = PBXFileReference; lastKnownFileType = file.storyboard; name = Base; path = Base.lproj/Main.storyboard; sourceTree = ""; }; + AE9957611FA704AF00397D38 /* Assets.xcassets */ = {isa = PBXFileReference; lastKnownFileType = folder.assetcatalog; path = Assets.xcassets; sourceTree = ""; }; + AE9957641FA704AF00397D38 /* Base */ = {isa = PBXFileReference; lastKnownFileType = file.storyboard; name = Base; path = Base.lproj/LaunchScreen.storyboard; sourceTree = ""; }; + AE9957661FA704AF00397D38 /* Info.plist */ = {isa = PBXFileReference; lastKnownFileType = text.plist.xml; path = Info.plist; sourceTree = ""; }; + AE99576B1FA704AF00397D38 /* meetingRoomsTests.xctest */ = {isa = PBXFileReference; explicitFileType = wrapper.cfbundle; includeInIndex = 0; path = meetingRoomsTests.xctest; sourceTree = BUILT_PRODUCTS_DIR; }; + AE99576F1FA704AF00397D38 /* meetingRoomsTests.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = meetingRoomsTests.swift; sourceTree = ""; }; + AE9957711FA704AF00397D38 /* Info.plist */ = {isa = PBXFileReference; lastKnownFileType = text.plist.xml; path = Info.plist; sourceTree = ""; }; + AE9957761FA704B000397D38 /* meetingRoomsUITests.xctest */ = {isa = PBXFileReference; explicitFileType = wrapper.cfbundle; includeInIndex = 0; path = meetingRoomsUITests.xctest; sourceTree = BUILT_PRODUCTS_DIR; }; + AE99577A1FA704B000397D38 /* meetingRoomsUITests.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = meetingRoomsUITests.swift; sourceTree = ""; }; + AE99577C1FA704B000397D38 /* Info.plist */ = {isa = PBXFileReference; lastKnownFileType = text.plist.xml; path = Info.plist; sourceTree = ""; }; + AE9957881FA7054800397D38 /* MeetingRoomListViewController.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = MeetingRoomListViewController.swift; sourceTree = ""; }; + AEB3189C1FB4641000AEB094 /* DataCenter.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = DataCenter.swift; sourceTree = ""; }; + AEB3189E1FB4684600AEB094 /* BranchListViewController.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = BranchListViewController.swift; sourceTree = ""; }; + AEB318A01FB4685800AEB094 /* ServiceListViewController.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = ServiceListViewController.swift; sourceTree = ""; }; + AEB318A21FB4807F00AEB094 /* RoomInfoViewController.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = RoomInfoViewController.swift; sourceTree = ""; }; + AEB318A41FB485D300AEB094 /* ReservationListViewController.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = ReservationListViewController.swift; sourceTree = ""; }; + AEB318A61FB4861600AEB094 /* ReserveRoomViewController.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = ReserveRoomViewController.swift; sourceTree = ""; }; +/* End PBXFileReference section */ + +/* Begin PBXFrameworksBuildPhase section */ + AE9957541FA704AF00397D38 /* Frameworks */ = { + isa = PBXFrameworksBuildPhase; + buildActionMask = 2147483647; + files = ( + ); + runOnlyForDeploymentPostprocessing = 0; + }; + AE9957681FA704AF00397D38 /* Frameworks */ = { + isa = PBXFrameworksBuildPhase; + buildActionMask = 2147483647; + files = ( + ); + runOnlyForDeploymentPostprocessing = 0; + }; + AE9957731FA704B000397D38 /* Frameworks */ = { + isa = PBXFrameworksBuildPhase; + buildActionMask = 2147483647; + files = ( + ); + runOnlyForDeploymentPostprocessing = 0; + }; +/* End PBXFrameworksBuildPhase section */ + +/* Begin PBXGroup section */ + AE99574E1FA704AF00397D38 = { + isa = PBXGroup; + children = ( + AE9957591FA704AF00397D38 /* meetingRooms */, + AE99576E1FA704AF00397D38 /* meetingRoomsTests */, + AE9957791FA704B000397D38 /* meetingRoomsUITests */, + AE9957581FA704AF00397D38 /* Products */, + ); + sourceTree = ""; + }; + AE9957581FA704AF00397D38 /* Products */ = { + isa = PBXGroup; + children = ( + AE9957571FA704AF00397D38 /* meetingRooms.app */, + AE99576B1FA704AF00397D38 /* meetingRoomsTests.xctest */, + AE9957761FA704B000397D38 /* meetingRoomsUITests.xctest */, + ); + name = Products; + sourceTree = ""; + }; + AE9957591FA704AF00397D38 /* meetingRooms */ = { + isa = PBXGroup; + children = ( + AE99575A1FA704AF00397D38 /* AppDelegate.swift */, + AE99575C1FA704AF00397D38 /* ViewController.swift */, + AE99575E1FA704AF00397D38 /* Main.storyboard */, + AEB318A61FB4861600AEB094 /* ReserveRoomViewController.swift */, + AEB318A41FB485D300AEB094 /* ReservationListViewController.swift */, + AEB318A21FB4807F00AEB094 /* RoomInfoViewController.swift */, + AEB3189C1FB4641000AEB094 /* DataCenter.swift */, + AEB3189E1FB4684600AEB094 /* BranchListViewController.swift */, + AEB318A01FB4685800AEB094 /* ServiceListViewController.swift */, + AE9957881FA7054800397D38 /* MeetingRoomListViewController.swift */, + AE9957611FA704AF00397D38 /* Assets.xcassets */, + AE9957631FA704AF00397D38 /* LaunchScreen.storyboard */, + AE9957661FA704AF00397D38 /* Info.plist */, + ); + path = meetingRooms; + sourceTree = ""; + }; + AE99576E1FA704AF00397D38 /* meetingRoomsTests */ = { + isa = PBXGroup; + children = ( + AE99576F1FA704AF00397D38 /* meetingRoomsTests.swift */, + AE9957711FA704AF00397D38 /* Info.plist */, + ); + path = meetingRoomsTests; + sourceTree = ""; + }; + AE9957791FA704B000397D38 /* meetingRoomsUITests */ = { + isa = PBXGroup; + children = ( + AE99577A1FA704B000397D38 /* meetingRoomsUITests.swift */, + AE99577C1FA704B000397D38 /* Info.plist */, + ); + path = meetingRoomsUITests; + sourceTree = ""; + }; +/* End PBXGroup section */ + +/* Begin PBXNativeTarget section */ + AE9957561FA704AF00397D38 /* meetingRooms */ = { + isa = PBXNativeTarget; + buildConfigurationList = AE99577F1FA704B000397D38 /* Build configuration list for PBXNativeTarget "meetingRooms" */; + buildPhases = ( + AE9957531FA704AF00397D38 /* Sources */, + AE9957541FA704AF00397D38 /* Frameworks */, + AE9957551FA704AF00397D38 /* Resources */, + ); + buildRules = ( + ); + dependencies = ( + ); + name = meetingRooms; + productName = meetingRooms; + productReference = AE9957571FA704AF00397D38 /* meetingRooms.app */; + productType = "com.apple.product-type.application"; + }; + AE99576A1FA704AF00397D38 /* meetingRoomsTests */ = { + isa = PBXNativeTarget; + buildConfigurationList = AE9957821FA704B000397D38 /* Build configuration list for PBXNativeTarget "meetingRoomsTests" */; + buildPhases = ( + AE9957671FA704AF00397D38 /* Sources */, + AE9957681FA704AF00397D38 /* Frameworks */, + AE9957691FA704AF00397D38 /* Resources */, + ); + buildRules = ( + ); + dependencies = ( + AE99576D1FA704AF00397D38 /* PBXTargetDependency */, + ); + name = meetingRoomsTests; + productName = meetingRoomsTests; + productReference = AE99576B1FA704AF00397D38 /* meetingRoomsTests.xctest */; + productType = "com.apple.product-type.bundle.unit-test"; + }; + AE9957751FA704B000397D38 /* meetingRoomsUITests */ = { + isa = PBXNativeTarget; + buildConfigurationList = AE9957851FA704B000397D38 /* Build configuration list for PBXNativeTarget "meetingRoomsUITests" */; + buildPhases = ( + AE9957721FA704B000397D38 /* Sources */, + AE9957731FA704B000397D38 /* Frameworks */, + AE9957741FA704B000397D38 /* Resources */, + ); + buildRules = ( + ); + dependencies = ( + AE9957781FA704B000397D38 /* PBXTargetDependency */, + ); + name = meetingRoomsUITests; + productName = meetingRoomsUITests; + productReference = AE9957761FA704B000397D38 /* meetingRoomsUITests.xctest */; + productType = "com.apple.product-type.bundle.ui-testing"; + }; +/* End PBXNativeTarget section */ + +/* Begin PBXProject section */ + AE99574F1FA704AF00397D38 /* Project object */ = { + isa = PBXProject; + attributes = { + LastSwiftUpdateCheck = 0900; + LastUpgradeCheck = 0900; + ORGANIZATIONNAME = "황도증"; + TargetAttributes = { + AE9957561FA704AF00397D38 = { + CreatedOnToolsVersion = 9.0.1; + ProvisioningStyle = Automatic; + }; + AE99576A1FA704AF00397D38 = { + CreatedOnToolsVersion = 9.0.1; + ProvisioningStyle = Automatic; + TestTargetID = AE9957561FA704AF00397D38; + }; + AE9957751FA704B000397D38 = { + CreatedOnToolsVersion = 9.0.1; + ProvisioningStyle = Automatic; + TestTargetID = AE9957561FA704AF00397D38; + }; + }; + }; + buildConfigurationList = AE9957521FA704AF00397D38 /* Build configuration list for PBXProject "meetingRooms" */; + compatibilityVersion = "Xcode 8.0"; + developmentRegion = en; + hasScannedForEncodings = 0; + knownRegions = ( + en, + Base, + ); + mainGroup = AE99574E1FA704AF00397D38; + productRefGroup = AE9957581FA704AF00397D38 /* Products */; + projectDirPath = ""; + projectRoot = ""; + targets = ( + AE9957561FA704AF00397D38 /* meetingRooms */, + AE99576A1FA704AF00397D38 /* meetingRoomsTests */, + AE9957751FA704B000397D38 /* meetingRoomsUITests */, + ); + }; +/* End PBXProject section */ + +/* Begin PBXResourcesBuildPhase section */ + AE9957551FA704AF00397D38 /* Resources */ = { + isa = PBXResourcesBuildPhase; + buildActionMask = 2147483647; + files = ( + AE9957651FA704AF00397D38 /* LaunchScreen.storyboard in Resources */, + AE9957621FA704AF00397D38 /* Assets.xcassets in Resources */, + AE9957601FA704AF00397D38 /* Main.storyboard in Resources */, + ); + runOnlyForDeploymentPostprocessing = 0; + }; + AE9957691FA704AF00397D38 /* Resources */ = { + isa = PBXResourcesBuildPhase; + buildActionMask = 2147483647; + files = ( + ); + runOnlyForDeploymentPostprocessing = 0; + }; + AE9957741FA704B000397D38 /* Resources */ = { + isa = PBXResourcesBuildPhase; + buildActionMask = 2147483647; + files = ( + ); + runOnlyForDeploymentPostprocessing = 0; + }; +/* End PBXResourcesBuildPhase section */ + +/* Begin PBXSourcesBuildPhase section */ + AE9957531FA704AF00397D38 /* Sources */ = { + isa = PBXSourcesBuildPhase; + buildActionMask = 2147483647; + files = ( + AEB318A31FB4807F00AEB094 /* RoomInfoViewController.swift in Sources */, + AE99575D1FA704AF00397D38 /* ViewController.swift in Sources */, + AE99575B1FA704AF00397D38 /* AppDelegate.swift in Sources */, + AEB318A51FB485D300AEB094 /* ReservationListViewController.swift in Sources */, + AEB3189D1FB4641000AEB094 /* DataCenter.swift in Sources */, + AEB3189F1FB4684600AEB094 /* BranchListViewController.swift in Sources */, + AEB318A11FB4685800AEB094 /* ServiceListViewController.swift in Sources */, + AE9957891FA7054800397D38 /* MeetingRoomListViewController.swift in Sources */, + AEB318A71FB4861600AEB094 /* ReserveRoomViewController.swift in Sources */, + ); + runOnlyForDeploymentPostprocessing = 0; + }; + AE9957671FA704AF00397D38 /* Sources */ = { + isa = PBXSourcesBuildPhase; + buildActionMask = 2147483647; + files = ( + AE9957701FA704AF00397D38 /* meetingRoomsTests.swift in Sources */, + ); + runOnlyForDeploymentPostprocessing = 0; + }; + AE9957721FA704B000397D38 /* Sources */ = { + isa = PBXSourcesBuildPhase; + buildActionMask = 2147483647; + files = ( + AE99577B1FA704B000397D38 /* meetingRoomsUITests.swift in Sources */, + ); + runOnlyForDeploymentPostprocessing = 0; + }; +/* End PBXSourcesBuildPhase section */ + +/* Begin PBXTargetDependency section */ + AE99576D1FA704AF00397D38 /* PBXTargetDependency */ = { + isa = PBXTargetDependency; + target = AE9957561FA704AF00397D38 /* meetingRooms */; + targetProxy = AE99576C1FA704AF00397D38 /* PBXContainerItemProxy */; + }; + AE9957781FA704B000397D38 /* PBXTargetDependency */ = { + isa = PBXTargetDependency; + target = AE9957561FA704AF00397D38 /* meetingRooms */; + targetProxy = AE9957771FA704B000397D38 /* PBXContainerItemProxy */; + }; +/* End PBXTargetDependency section */ + +/* Begin PBXVariantGroup section */ + AE99575E1FA704AF00397D38 /* Main.storyboard */ = { + isa = PBXVariantGroup; + children = ( + AE99575F1FA704AF00397D38 /* Base */, + ); + name = Main.storyboard; + sourceTree = ""; + }; + AE9957631FA704AF00397D38 /* LaunchScreen.storyboard */ = { + isa = PBXVariantGroup; + children = ( + AE9957641FA704AF00397D38 /* Base */, + ); + name = LaunchScreen.storyboard; + sourceTree = ""; + }; +/* End PBXVariantGroup section */ + +/* Begin XCBuildConfiguration section */ + AE99577D1FA704B000397D38 /* Debug */ = { + isa = XCBuildConfiguration; + buildSettings = { + ALWAYS_SEARCH_USER_PATHS = NO; + CLANG_ANALYZER_NONNULL = YES; + CLANG_ANALYZER_NUMBER_OBJECT_CONVERSION = YES_AGGRESSIVE; + CLANG_CXX_LANGUAGE_STANDARD = "gnu++14"; + CLANG_CXX_LIBRARY = "libc++"; + CLANG_ENABLE_MODULES = YES; + CLANG_ENABLE_OBJC_ARC = YES; + CLANG_WARN_BLOCK_CAPTURE_AUTORELEASING = YES; + CLANG_WARN_BOOL_CONVERSION = YES; + CLANG_WARN_COMMA = YES; + CLANG_WARN_CONSTANT_CONVERSION = YES; + CLANG_WARN_DIRECT_OBJC_ISA_USAGE = YES_ERROR; + CLANG_WARN_DOCUMENTATION_COMMENTS = YES; + CLANG_WARN_EMPTY_BODY = YES; + CLANG_WARN_ENUM_CONVERSION = YES; + CLANG_WARN_INFINITE_RECURSION = YES; + CLANG_WARN_INT_CONVERSION = YES; + CLANG_WARN_NON_LITERAL_NULL_CONVERSION = YES; + CLANG_WARN_OBJC_LITERAL_CONVERSION = YES; + CLANG_WARN_OBJC_ROOT_CLASS = YES_ERROR; + CLANG_WARN_RANGE_LOOP_ANALYSIS = YES; + CLANG_WARN_STRICT_PROTOTYPES = YES; + CLANG_WARN_SUSPICIOUS_MOVE = YES; + CLANG_WARN_UNGUARDED_AVAILABILITY = YES_AGGRESSIVE; + CLANG_WARN_UNREACHABLE_CODE = YES; + CLANG_WARN__DUPLICATE_METHOD_MATCH = YES; + CODE_SIGN_IDENTITY = "iPhone Developer"; + COPY_PHASE_STRIP = NO; + DEBUG_INFORMATION_FORMAT = dwarf; + ENABLE_STRICT_OBJC_MSGSEND = YES; + ENABLE_TESTABILITY = YES; + GCC_C_LANGUAGE_STANDARD = gnu11; + GCC_DYNAMIC_NO_PIC = NO; + GCC_NO_COMMON_BLOCKS = YES; + GCC_OPTIMIZATION_LEVEL = 0; + GCC_PREPROCESSOR_DEFINITIONS = ( + "DEBUG=1", + "$(inherited)", + ); + GCC_WARN_64_TO_32_BIT_CONVERSION = YES; + GCC_WARN_ABOUT_RETURN_TYPE = YES_ERROR; + GCC_WARN_UNDECLARED_SELECTOR = YES; + GCC_WARN_UNINITIALIZED_AUTOS = YES_AGGRESSIVE; + GCC_WARN_UNUSED_FUNCTION = YES; + GCC_WARN_UNUSED_VARIABLE = YES; + IPHONEOS_DEPLOYMENT_TARGET = 11.0; + MTL_ENABLE_DEBUG_INFO = YES; + ONLY_ACTIVE_ARCH = YES; + SDKROOT = iphoneos; + SWIFT_ACTIVE_COMPILATION_CONDITIONS = DEBUG; + SWIFT_OPTIMIZATION_LEVEL = "-Onone"; + }; + name = Debug; + }; + AE99577E1FA704B000397D38 /* Release */ = { + isa = XCBuildConfiguration; + buildSettings = { + ALWAYS_SEARCH_USER_PATHS = NO; + CLANG_ANALYZER_NONNULL = YES; + CLANG_ANALYZER_NUMBER_OBJECT_CONVERSION = YES_AGGRESSIVE; + CLANG_CXX_LANGUAGE_STANDARD = "gnu++14"; + CLANG_CXX_LIBRARY = "libc++"; + CLANG_ENABLE_MODULES = YES; + CLANG_ENABLE_OBJC_ARC = YES; + CLANG_WARN_BLOCK_CAPTURE_AUTORELEASING = YES; + CLANG_WARN_BOOL_CONVERSION = YES; + CLANG_WARN_COMMA = YES; + CLANG_WARN_CONSTANT_CONVERSION = YES; + CLANG_WARN_DIRECT_OBJC_ISA_USAGE = YES_ERROR; + CLANG_WARN_DOCUMENTATION_COMMENTS = YES; + CLANG_WARN_EMPTY_BODY = YES; + CLANG_WARN_ENUM_CONVERSION = YES; + CLANG_WARN_INFINITE_RECURSION = YES; + CLANG_WARN_INT_CONVERSION = YES; + CLANG_WARN_NON_LITERAL_NULL_CONVERSION = YES; + CLANG_WARN_OBJC_LITERAL_CONVERSION = YES; + CLANG_WARN_OBJC_ROOT_CLASS = YES_ERROR; + CLANG_WARN_RANGE_LOOP_ANALYSIS = YES; + CLANG_WARN_STRICT_PROTOTYPES = YES; + CLANG_WARN_SUSPICIOUS_MOVE = YES; + CLANG_WARN_UNGUARDED_AVAILABILITY = YES_AGGRESSIVE; + CLANG_WARN_UNREACHABLE_CODE = YES; + CLANG_WARN__DUPLICATE_METHOD_MATCH = YES; + CODE_SIGN_IDENTITY = "iPhone Developer"; + COPY_PHASE_STRIP = NO; + DEBUG_INFORMATION_FORMAT = "dwarf-with-dsym"; + ENABLE_NS_ASSERTIONS = NO; + ENABLE_STRICT_OBJC_MSGSEND = YES; + GCC_C_LANGUAGE_STANDARD = gnu11; + GCC_NO_COMMON_BLOCKS = YES; + GCC_WARN_64_TO_32_BIT_CONVERSION = YES; + GCC_WARN_ABOUT_RETURN_TYPE = YES_ERROR; + GCC_WARN_UNDECLARED_SELECTOR = YES; + GCC_WARN_UNINITIALIZED_AUTOS = YES_AGGRESSIVE; + GCC_WARN_UNUSED_FUNCTION = YES; + GCC_WARN_UNUSED_VARIABLE = YES; + IPHONEOS_DEPLOYMENT_TARGET = 11.0; + MTL_ENABLE_DEBUG_INFO = NO; + SDKROOT = iphoneos; + SWIFT_OPTIMIZATION_LEVEL = "-Owholemodule"; + VALIDATE_PRODUCT = YES; + }; + name = Release; + }; + AE9957801FA704B000397D38 /* Debug */ = { + isa = XCBuildConfiguration; + buildSettings = { + ASSETCATALOG_COMPILER_APPICON_NAME = AppIcon; + CODE_SIGN_STYLE = Automatic; + INFOPLIST_FILE = meetingRooms/Info.plist; + LD_RUNPATH_SEARCH_PATHS = "$(inherited) @executable_path/Frameworks"; + PRODUCT_BUNDLE_IDENTIFIER = "--------.meetingRooms"; + PRODUCT_NAME = "$(TARGET_NAME)"; + SWIFT_VERSION = 4.0; + TARGETED_DEVICE_FAMILY = "1,2"; + }; + name = Debug; + }; + AE9957811FA704B000397D38 /* Release */ = { + isa = XCBuildConfiguration; + buildSettings = { + ASSETCATALOG_COMPILER_APPICON_NAME = AppIcon; + CODE_SIGN_STYLE = Automatic; + INFOPLIST_FILE = meetingRooms/Info.plist; + LD_RUNPATH_SEARCH_PATHS = "$(inherited) @executable_path/Frameworks"; + PRODUCT_BUNDLE_IDENTIFIER = "--------.meetingRooms"; + PRODUCT_NAME = "$(TARGET_NAME)"; + SWIFT_VERSION = 4.0; + TARGETED_DEVICE_FAMILY = "1,2"; + }; + name = Release; + }; + AE9957831FA704B000397D38 /* Debug */ = { + isa = XCBuildConfiguration; + buildSettings = { + ALWAYS_EMBED_SWIFT_STANDARD_LIBRARIES = YES; + BUNDLE_LOADER = "$(TEST_HOST)"; + CODE_SIGN_STYLE = Automatic; + INFOPLIST_FILE = meetingRoomsTests/Info.plist; + LD_RUNPATH_SEARCH_PATHS = "$(inherited) @executable_path/Frameworks @loader_path/Frameworks"; + PRODUCT_BUNDLE_IDENTIFIER = "--------.meetingRoomsTests"; + PRODUCT_NAME = "$(TARGET_NAME)"; + SWIFT_VERSION = 4.0; + TARGETED_DEVICE_FAMILY = "1,2"; + TEST_HOST = "$(BUILT_PRODUCTS_DIR)/meetingRooms.app/meetingRooms"; + }; + name = Debug; + }; + AE9957841FA704B000397D38 /* Release */ = { + isa = XCBuildConfiguration; + buildSettings = { + ALWAYS_EMBED_SWIFT_STANDARD_LIBRARIES = YES; + BUNDLE_LOADER = "$(TEST_HOST)"; + CODE_SIGN_STYLE = Automatic; + INFOPLIST_FILE = meetingRoomsTests/Info.plist; + LD_RUNPATH_SEARCH_PATHS = "$(inherited) @executable_path/Frameworks @loader_path/Frameworks"; + PRODUCT_BUNDLE_IDENTIFIER = "--------.meetingRoomsTests"; + PRODUCT_NAME = "$(TARGET_NAME)"; + SWIFT_VERSION = 4.0; + TARGETED_DEVICE_FAMILY = "1,2"; + TEST_HOST = "$(BUILT_PRODUCTS_DIR)/meetingRooms.app/meetingRooms"; + }; + name = Release; + }; + AE9957861FA704B000397D38 /* Debug */ = { + isa = XCBuildConfiguration; + buildSettings = { + ALWAYS_EMBED_SWIFT_STANDARD_LIBRARIES = YES; + CODE_SIGN_STYLE = Automatic; + INFOPLIST_FILE = meetingRoomsUITests/Info.plist; + LD_RUNPATH_SEARCH_PATHS = "$(inherited) @executable_path/Frameworks @loader_path/Frameworks"; + PRODUCT_BUNDLE_IDENTIFIER = "--------.meetingRoomsUITests"; + PRODUCT_NAME = "$(TARGET_NAME)"; + SWIFT_VERSION = 4.0; + TARGETED_DEVICE_FAMILY = "1,2"; + TEST_TARGET_NAME = meetingRooms; + }; + name = Debug; + }; + AE9957871FA704B000397D38 /* Release */ = { + isa = XCBuildConfiguration; + buildSettings = { + ALWAYS_EMBED_SWIFT_STANDARD_LIBRARIES = YES; + CODE_SIGN_STYLE = Automatic; + INFOPLIST_FILE = meetingRoomsUITests/Info.plist; + LD_RUNPATH_SEARCH_PATHS = "$(inherited) @executable_path/Frameworks @loader_path/Frameworks"; + PRODUCT_BUNDLE_IDENTIFIER = "--------.meetingRoomsUITests"; + PRODUCT_NAME = "$(TARGET_NAME)"; + SWIFT_VERSION = 4.0; + TARGETED_DEVICE_FAMILY = "1,2"; + TEST_TARGET_NAME = meetingRooms; + }; + name = Release; + }; +/* End XCBuildConfiguration section */ + +/* Begin XCConfigurationList section */ + AE9957521FA704AF00397D38 /* Build configuration list for PBXProject "meetingRooms" */ = { + isa = XCConfigurationList; + buildConfigurations = ( + AE99577D1FA704B000397D38 /* Debug */, + AE99577E1FA704B000397D38 /* Release */, + ); + defaultConfigurationIsVisible = 0; + defaultConfigurationName = Release; + }; + AE99577F1FA704B000397D38 /* Build configuration list for PBXNativeTarget "meetingRooms" */ = { + isa = XCConfigurationList; + buildConfigurations = ( + AE9957801FA704B000397D38 /* Debug */, + AE9957811FA704B000397D38 /* Release */, + ); + defaultConfigurationIsVisible = 0; + defaultConfigurationName = Release; + }; + AE9957821FA704B000397D38 /* Build configuration list for PBXNativeTarget "meetingRoomsTests" */ = { + isa = XCConfigurationList; + buildConfigurations = ( + AE9957831FA704B000397D38 /* Debug */, + AE9957841FA704B000397D38 /* Release */, + ); + defaultConfigurationIsVisible = 0; + defaultConfigurationName = Release; + }; + AE9957851FA704B000397D38 /* Build configuration list for PBXNativeTarget "meetingRoomsUITests" */ = { + isa = XCConfigurationList; + buildConfigurations = ( + AE9957861FA704B000397D38 /* Debug */, + AE9957871FA704B000397D38 /* Release */, + ); + defaultConfigurationIsVisible = 0; + defaultConfigurationName = Release; + }; +/* End XCConfigurationList section */ + }; + rootObject = AE99574F1FA704AF00397D38 /* Project object */; +} diff --git "a/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/meetingRooms_modal present/meetingRooms.xcodeproj/project.xcworkspace/contents.xcworkspacedata" "b/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/meetingRooms_modal present/meetingRooms.xcodeproj/project.xcworkspace/contents.xcworkspacedata" new file mode 100644 index 0000000..8491799 --- /dev/null +++ "b/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/meetingRooms_modal present/meetingRooms.xcodeproj/project.xcworkspace/contents.xcworkspacedata" @@ -0,0 +1,7 @@ + + + + + diff --git "a/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/meetingRooms_modal present/meetingRooms/AppDelegate.swift" "b/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/meetingRooms_modal present/meetingRooms/AppDelegate.swift" new file mode 100644 index 0000000..fc60321 --- /dev/null +++ "b/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/meetingRooms_modal present/meetingRooms/AppDelegate.swift" @@ -0,0 +1,46 @@ +// +// AppDelegate.swift +// meetingRooms +// +// Created by 황도증 on 2017. 10. 30.. +// Copyright © 2017년 황도증. All rights reserved. +// + +import UIKit + +@UIApplicationMain +class AppDelegate: UIResponder, UIApplicationDelegate { + + var window: UIWindow? + + + func application(_ application: UIApplication, didFinishLaunchingWithOptions launchOptions: [UIApplicationLaunchOptionsKey: Any]?) -> Bool { + // Override point for customization after application launch. + return true + } + + func applicationWillResignActive(_ application: UIApplication) { + // Sent when the application is about to move from active to inactive state. This can occur for certain types of temporary interruptions (such as an incoming phone call or SMS message) or when the user quits the application and it begins the transition to the background state. + // Use this method to pause ongoing tasks, disable timers, and invalidate graphics rendering callbacks. Games should use this method to pause the game. + } + + func applicationDidEnterBackground(_ application: UIApplication) { + // Use this method to release shared resources, save user data, invalidate timers, and store enough application state information to restore your application to its current state in case it is terminated later. + // If your application supports background execution, this method is called instead of applicationWillTerminate: when the user quits. + } + + func applicationWillEnterForeground(_ application: UIApplication) { + // Called as part of the transition from the background to the active state; here you can undo many of the changes made on entering the background. + } + + func applicationDidBecomeActive(_ application: UIApplication) { + // Restart any tasks that were paused (or not yet started) while the application was inactive. If the application was previously in the background, optionally refresh the user interface. + } + + func applicationWillTerminate(_ application: UIApplication) { + // Called when the application is about to terminate. Save data if appropriate. See also applicationDidEnterBackground:. + } + + +} + diff --git "a/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/meetingRooms_modal present/meetingRooms/Assets.xcassets/AppIcon.appiconset/Contents.json" "b/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/meetingRooms_modal present/meetingRooms/Assets.xcassets/AppIcon.appiconset/Contents.json" new file mode 100644 index 0000000..d8db8d6 --- /dev/null +++ "b/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/meetingRooms_modal present/meetingRooms/Assets.xcassets/AppIcon.appiconset/Contents.json" @@ -0,0 +1,98 @@ +{ + "images" : [ + { + "idiom" : "iphone", + "size" : "20x20", + "scale" : "2x" + }, + { + "idiom" : "iphone", + "size" : "20x20", + "scale" : "3x" + }, + { + "idiom" : "iphone", + "size" : "29x29", + "scale" : "2x" + }, + { + "idiom" : "iphone", + "size" : "29x29", + "scale" : "3x" + }, + { + "idiom" : "iphone", + "size" : "40x40", + "scale" : "2x" + }, + { + "idiom" : "iphone", + "size" : "40x40", + "scale" : "3x" + }, + { + "idiom" : "iphone", + "size" : "60x60", + "scale" : "2x" + }, + { + "idiom" : "iphone", + "size" : "60x60", + "scale" : "3x" + }, + { + "idiom" : "ipad", + "size" : "20x20", + "scale" : "1x" + }, + { + "idiom" : "ipad", + "size" : "20x20", + "scale" : "2x" + }, + { + "idiom" : "ipad", + "size" : "29x29", + "scale" : "1x" + }, + { + "idiom" : "ipad", + "size" : "29x29", + "scale" : "2x" + }, + { + "idiom" : "ipad", + "size" : "40x40", + "scale" : "1x" + }, + { + "idiom" : "ipad", + "size" : "40x40", + "scale" : "2x" + }, + { + "idiom" : "ipad", + "size" : "76x76", + "scale" : "1x" + }, + { + "idiom" : "ipad", + "size" : "76x76", + "scale" : "2x" + }, + { + "idiom" : "ipad", + "size" : "83.5x83.5", + "scale" : "2x" + }, + { + "idiom" : "ios-marketing", + "size" : "1024x1024", + "scale" : "1x" + } + ], + "info" : { + "version" : 1, + "author" : "xcode" + } +} \ No newline at end of file diff --git "a/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/meetingRooms_modal present/meetingRooms/Base.lproj/LaunchScreen.storyboard" "b/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/meetingRooms_modal present/meetingRooms/Base.lproj/LaunchScreen.storyboard" new file mode 100644 index 0000000..f83f6fd --- /dev/null +++ "b/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/meetingRooms_modal present/meetingRooms/Base.lproj/LaunchScreen.storyboard" @@ -0,0 +1,25 @@ + + + + + + + + + + + + + + + + + + + + + + + + + diff --git "a/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/meetingRooms_modal present/meetingRooms/Base.lproj/Main.storyboard" "b/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/meetingRooms_modal present/meetingRooms/Base.lproj/Main.storyboard" new file mode 100644 index 0000000..2f0fd47 --- /dev/null +++ "b/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/meetingRooms_modal present/meetingRooms/Base.lproj/Main.storyboard" @@ -0,0 +1,617 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + diff --git "a/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/meetingRooms_modal present/meetingRooms/BranchListViewController.swift" "b/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/meetingRooms_modal present/meetingRooms/BranchListViewController.swift" new file mode 100644 index 0000000..fa28525 --- /dev/null +++ "b/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/meetingRooms_modal present/meetingRooms/BranchListViewController.swift" @@ -0,0 +1,119 @@ +// +// BranchListViewController.swift +// meetingRooms +// +// Created by 황도증 on 2017. 11. 9.. +// Copyright © 2017년 황도증. All rights reserved. +// + +import UIKit + +class BranchListViewController: UITableViewController { + + override func viewDidLoad() { + super.viewDidLoad() + + // Uncomment the following line to preserve selection between presentations + // self.clearsSelectionOnViewWillAppear = false + + // Uncomment the following line to display an Edit button in the navigation bar for this view controller. + // self.navigationItem.rightBarButtonItem = self.editButtonItem + + self.navigationController?.isToolbarHidden = true + } + + override func didReceiveMemoryWarning() { + super.didReceiveMemoryWarning() + // Dispose of any resources that can be recreated. + } + + // MARK: - Table view data source + + override func numberOfSections(in tableView: UITableView) -> Int { + // #warning Incomplete implementation, return the number of sections + return 1 + } + + @IBAction func locationTurnOn(_ sender: Any) { + let locationAlert = UIAlertController(title:"위치정보요청", message: "위치정보를 기반으로 가까운 지점을 자동으로 선택할 수 있습니다.", preferredStyle: .actionSheet) + + let locationAction = UIAlertAction(title: "위치정보켜기", style: .default, handler: {(action:UIAlertAction) -> Void in print("위치정보켜기 선택")}) + + let openMapAction = UIAlertAction(title: "지도에서 열기", style: .default, handler: {(action:UIAlertAction) -> Void in print("지도앱에서 열기 선택")}) + + locationAlert.addAction(locationAction) + locationAlert.addAction(openMapAction) + + self.present(locationAlert, animated: true, completion: nil) + } + override func tableView(_ tableView: UITableView, numberOfRowsInSection section: Int) -> Int { + // #warning Incomplete implementation, return the number of rows + let rowCount = dataCenter.branches.count + return rowCount + } + + + override func tableView(_ tableView: UITableView, cellForRowAt indexPath: IndexPath) -> UITableViewCell { + let cell = tableView.dequeueReusableCell(withIdentifier: "BranchCell", for: indexPath) + + // Configure the cell... + let branch = dataCenter.branches[indexPath.row] + cell.textLabel?.text = branch.name + + return cell + } + + + /* + // Override to support conditional editing of the table view. + override func tableView(_ tableView: UITableView, canEditRowAt indexPath: IndexPath) -> Bool { + // Return false if you do not want the specified item to be editable. + return true + } + */ + + /* + // Override to support editing the table view. + override func tableView(_ tableView: UITableView, commit editingStyle: UITableViewCellEditingStyle, forRowAt indexPath: IndexPath) { + if editingStyle == .delete { + // Delete the row from the data source + tableView.deleteRows(at: [indexPath], with: .fade) + } else if editingStyle == .insert { + // Create a new instance of the appropriate class, insert it into the array, and add a new row to the table view + } + } + */ + + /* + // Override to support rearranging the table view. + override func tableView(_ tableView: UITableView, moveRowAt fromIndexPath: IndexPath, to: IndexPath) { + + } + */ + + /* + // Override to support conditional rearranging of the table view. + override func tableView(_ tableView: UITableView, canMoveRowAt indexPath: IndexPath) -> Bool { + // Return false if you do not want the item to be re-orderable. + return true + } + */ + + + // MARK: - Navigation + + // In a storyboard-based application, you will often want to do a little preparation before navigation + override func prepare(for segue: UIStoryboardSegue, sender: Any?) { + // Get the new view controller using segue.destinationViewController. + // Pass the selected object to the new view controller. + + if segue.identifier == "ServiceSegue" { + if let destination = segue.destination as? ServiceListViewController { + if let selectedIndex = self.tableView.indexPathForSelectedRow?.row { + destination.branch = dataCenter.branches[selectedIndex] as Branch + } + } + } + + } +} diff --git "a/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/meetingRooms_modal present/meetingRooms/DataCenter.swift" "b/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/meetingRooms_modal present/meetingRooms/DataCenter.swift" new file mode 100644 index 0000000..7476872 --- /dev/null +++ "b/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/meetingRooms_modal present/meetingRooms/DataCenter.swift" @@ -0,0 +1,84 @@ +// +// DataCenter.swift +// meetingRooms +// +// Created by 황도증 on 2017. 11. 9.. +// Copyright © 2017년 황도증. All rights reserved. +// + +import Foundation + +let dataCenter:DataCenter = DataCenter() + +class DataCenter { + var branches:[Branch] = [] + + init (){ + let banksyRoom = MeetingRoom(name:"Banksy", capacity: 4) + let kahloRoom = MeetingRoom(name:"Kahlo", capacity: 8) + let riveraRoom = MeetingRoom(name:"Rivera", capacity: 8) + let picasoRoom = MeetingRoom(name:"Picaso", capacity: 10) + + let vehicleService = Service(name: "차량예약") + let meetingRoomService = Service(name: "회의실예약") + let visitorService = Service(name: "방문자예약") + let deskService = Service(name: "데스크예약") + meetingRoomService.items = [banksyRoom, kahloRoom, riveraRoom, picasoRoom] + + let pangyoBranch = Branch(name: "판교점") + let samsungBranch = Branch(name: "삼성점") + let yeoksamBranch = Branch(name: "역삼점") + let sinrimBranch = Branch(name: "신림점") + let songdooBranch = Branch(name: "송도점") + let anamBranch = Branch(name: "안암점") + pangyoBranch.services = [vehicleService, meetingRoomService, visitorService, deskService] + + branches += [pangyoBranch, samsungBranch, yeoksamBranch, sinrimBranch, songdooBranch, anamBranch] + } +} + +class Branch { + let name:String + var services:[Service]? + + init(name:String) { + self.name = name + } +} + +class Service { + let name:String + var items:[MeetingRoom]? + + init(name:String) { + self.name = name + } +} + +class MeetingRoom { + let name:String + let capacity:Int + var reservations:[Reservation]? + + init(name:String, capacity:Int) { + self.name = name + self.capacity = capacity + } +} + +class Reservation { + var hostName:String + var date:NSDate + var attendees:Int + var equipments:[String] + var catering:Bool + + init() { + self.hostName = "host of meeting" + self.date = NSDate() + self.attendees = 1 + self.equipments = [] + self.catering = false + } + +} diff --git "a/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/meetingRooms_modal present/meetingRooms/Info.plist" "b/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/meetingRooms_modal present/meetingRooms/Info.plist" new file mode 100644 index 0000000..16be3b6 --- /dev/null +++ "b/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/meetingRooms_modal present/meetingRooms/Info.plist" @@ -0,0 +1,45 @@ + + + + + CFBundleDevelopmentRegion + $(DEVELOPMENT_LANGUAGE) + CFBundleExecutable + $(EXECUTABLE_NAME) + CFBundleIdentifier + $(PRODUCT_BUNDLE_IDENTIFIER) + CFBundleInfoDictionaryVersion + 6.0 + CFBundleName + $(PRODUCT_NAME) + CFBundlePackageType + APPL + CFBundleShortVersionString + 1.0 + CFBundleVersion + 1 + LSRequiresIPhoneOS + + UILaunchStoryboardName + LaunchScreen + UIMainStoryboardFile + Main + UIRequiredDeviceCapabilities + + armv7 + + UISupportedInterfaceOrientations + + UIInterfaceOrientationPortrait + UIInterfaceOrientationLandscapeLeft + UIInterfaceOrientationLandscapeRight + + UISupportedInterfaceOrientations~ipad + + UIInterfaceOrientationPortrait + UIInterfaceOrientationPortraitUpsideDown + UIInterfaceOrientationLandscapeLeft + UIInterfaceOrientationLandscapeRight + + + diff --git "a/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/meetingRooms_modal present/meetingRooms/MeetingRoomListViewController.swift" "b/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/meetingRooms_modal present/meetingRooms/MeetingRoomListViewController.swift" new file mode 100644 index 0000000..b56d5ae --- /dev/null +++ "b/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/meetingRooms_modal present/meetingRooms/MeetingRoomListViewController.swift" @@ -0,0 +1,117 @@ +// +// MeetingRoomListViewController.swift +// meetingRooms +// +// Created by 황도증 on 2017. 10. 30.. +// Copyright © 2017년 황도증. All rights reserved. +// + +import UIKit + +class MeetingRoomListViewController: UITableViewController { + + var service:Service? + + override func viewDidLoad() { + super.viewDidLoad() + + // Uncomment the following line to preserve selection between presentations + // self.clearsSelectionOnViewWillAppear = false + + // Uncomment the following line to display an Edit button in the navigation bar for this view controller. + // self.navigationItem.rightBarButtonItem = self.editButtonItem + + self.title = service?.name + } + + override func didReceiveMemoryWarning() { + super.didReceiveMemoryWarning() + // Dispose of any resources that can be recreated. + } + + // MARK: - Table view data source + + override func numberOfSections(in tableView: UITableView) -> Int { + // #warning Incomplete implementation, return the number of sections + return 1 + } + + override func tableView(_ tableView: UITableView, numberOfRowsInSection section: Int) -> Int { + // #warning Incomplete implementation, return the number of rows + //let categoryValues = Array(meetingRooms.values)[section] + //let orderMeetingRoooms = meetingRooms.sorted(by: {$0.1.first!.1 < $1.1.first!.1}) + guard let rowCount = service?.items?.count else { + return 0 + } + return rowCount + } + + + override func tableView(_ tableView: UITableView, cellForRowAt indexPath: IndexPath) -> UITableViewCell { + let cell = tableView.dequeueReusableCell(withIdentifier: "ItemCell", for: indexPath) + + //let orderMeetingRoooms = meetingRooms.sorted(by: {$0.1.first!.1 < $1.1.first!.1}) + // Configure the cell... + //let categoryValue = Array(meetingRooms.values)[indexPath.section] + + guard let meetingRoom = service?.items?[indexPath.row] else { + return cell + } + + cell.textLabel!.text = meetingRoom.name + cell.detailTextLabel!.text = String(meetingRoom.capacity) + return cell + } + + /* + // Override to support conditional editing of the table view. + override func tableView(_ tableView: UITableView, canEditRowAt indexPath: IndexPath) -> Bool { + // Return false if you do not want the specified item to be editable. + return true + } + */ + + /* + // Override to support editing the table view. + override func tableView(_ tableView: UITableView, commit editingStyle: UITableViewCellEditingStyle, forRowAt indexPath: IndexPath) { + if editingStyle == .delete { + // Delete the row from the data source + tableView.deleteRows(at: [indexPath], with: .fade) + } else if editingStyle == .insert { + // Create a new instance of the appropriate class, insert it into the array, and add a new row to the table view + } + } + */ + + /* + // Override to support rearranging the table view. + override func tableView(_ tableView: UITableView, moveRowAt fromIndexPath: IndexPath, to: IndexPath) { + + } + */ + + /* + // Override to support conditional rearranging of the table view. + override func tableView(_ tableView: UITableView, canMoveRowAt indexPath: IndexPath) -> Bool { + // Return false if you do not want the item to be re-orderable. + return true + } + */ + + + // MARK: - Navigation + + // In a storyboard-based application, you will often want to do a little preparation before navigation + override func prepare(for segue: UIStoryboardSegue, sender: Any?) { + // Get the new view controller using segue.destinationViewController. + // Pass the selected object to the new view controller. + if segue.identifier == "ReservationSegue" { + guard let destination = segue.destination as? ReservationListViewController, let selectedIndex = self.tableView.indexPathForSelectedRow?.row, let meetingRoom = service?.items?[selectedIndex] else { + return + } + destination.meetingRoom = meetingRoom + } + + } + +} diff --git "a/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/meetingRooms_modal present/meetingRooms/ReservationListViewController.swift" "b/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/meetingRooms_modal present/meetingRooms/ReservationListViewController.swift" new file mode 100644 index 0000000..a700809 --- /dev/null +++ "b/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/meetingRooms_modal present/meetingRooms/ReservationListViewController.swift" @@ -0,0 +1,114 @@ +// +// ReservationListViewController.swift +// meetingRooms +// +// Created by 황도증 on 2017. 11. 9.. +// Copyright © 2017년 황도증. All rights reserved. +// + +import UIKit + +class ReservationListViewController: UITableViewController { + + var meetingRoom:MeetingRoom? + var newReservation:Reservation? + + override func viewDidLoad() { + super.viewDidLoad() + + // Uncomment the following line to preserve selection between presentations + // self.clearsSelectionOnViewWillAppear = false + + // Uncomment the following line to display an Edit button in the navigation bar for this view controller. + // self.navigationItem.rightBarButtonItem = self.editButtonItem + } + + override func didReceiveMemoryWarning() { + super.didReceiveMemoryWarning() + // Dispose of any resources that can be recreated. + } + + func addNewItem(reservation:Reservation) { + if (self.meetingRoom?.reservations?.append(reservation)) == nil { + self.meetingRoom?.reservations = [reservation] + } + self.tableView.reloadData() + } + + // MARK: - Table view data source + + override func numberOfSections(in tableView: UITableView) -> Int { + // #warning Incomplete implementation, return the number of sections + return 1 + } + + override func tableView(_ tableView: UITableView, numberOfRowsInSection section: Int) -> Int { + // #warning Incomplete implementation, return the number of rows + guard let rowCount = meetingRoom?.reservations?.count else { + return 0 + } + return rowCount + } + + + override func tableView(_ tableView: UITableView, cellForRowAt indexPath: IndexPath) -> UITableViewCell { + let cell = tableView.dequeueReusableCell(withIdentifier: "ReservationCell", for: indexPath) + + // Configure the cell... + guard let reservation = meetingRoom?.reservations?[indexPath.row] else { + return cell + } + + cell.textLabel?.text = reservation.date.description + cell.detailTextLabel?.text = reservation.hostName + + return cell + } + + + /* + // Override to support conditional editing of the table view. + override func tableView(_ tableView: UITableView, canEditRowAt indexPath: IndexPath) -> Bool { + // Return false if you do not want the specified item to be editable. + return true + } + */ + + /* + // Override to support editing the table view. + override func tableView(_ tableView: UITableView, commit editingStyle: UITableViewCellEditingStyle, forRowAt indexPath: IndexPath) { + if editingStyle == .delete { + // Delete the row from the data source + tableView.deleteRows(at: [indexPath], with: .fade) + } else if editingStyle == .insert { + // Create a new instance of the appropriate class, insert it into the array, and add a new row to the table view + } + } + */ + + /* + // Override to support rearranging the table view. + override func tableView(_ tableView: UITableView, moveRowAt fromIndexPath: IndexPath, to: IndexPath) { + + } + */ + + /* + // Override to support conditional rearranging of the table view. + override func tableView(_ tableView: UITableView, canMoveRowAt indexPath: IndexPath) -> Bool { + // Return false if you do not want the item to be re-orderable. + return true + } + */ + + /* + // MARK: - Navigation + + // In a storyboard-based application, you will often want to do a little preparation before navigation + override func prepare(for segue: UIStoryboardSegue, sender: Any?) { + // Get the new view controller using segue.destinationViewController. + // Pass the selected object to the new view controller. + } + */ + +} diff --git "a/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/meetingRooms_modal present/meetingRooms/ReserveRoomViewController.swift" "b/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/meetingRooms_modal present/meetingRooms/ReserveRoomViewController.swift" new file mode 100644 index 0000000..1b0a590 --- /dev/null +++ "b/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/meetingRooms_modal present/meetingRooms/ReserveRoomViewController.swift" @@ -0,0 +1,148 @@ +// +// ReserveRoomViewController.swift +// meetingRooms +// +// Created by 황도증 on 2017. 11. 9.. +// Copyright © 2017년 황도증. All rights reserved. +// + +import UIKit + +class ReserveRoomViewController: UITableViewController { + + @IBOutlet weak var hostNameField: UITextField! + @IBOutlet weak var datePicker: UIDatePicker! + @IBOutlet weak var attendeesField: UITextField! + @IBOutlet weak var equipmentField: UITextField! + @IBOutlet weak var cateringSwitch: UISwitch! + + + override func viewDidLoad() { + super.viewDidLoad() + + // Uncomment the following line to preserve selection between presentations + // self.clearsSelectionOnViewWillAppear = false + + // Uncomment the following line to display an Edit button in the navigation bar for this view controller. + // self.navigationItem.rightBarButtonItem = self.editButtonItem + } + + override func didReceiveMemoryWarning() { + super.didReceiveMemoryWarning() + // Dispose of any resources that can be recreated. + } + + func newReservation() -> Reservation? { + let reservation = Reservation() + let host = hostNameField.text + + if (host?.isEmpty)! { + return nil + } + reservation.hostName = host! + reservation.date = datePicker.date as NSDate + + if let equipmentArray = equipmentField.text?.split(separator: ",").map(String.init) { + reservation.equipments = equipmentArray + } + reservation.catering = cateringSwitch.isOn + return reservation + } + + @IBAction func cancelReservation(_ sender: Any) { + self.dismiss(animated: true, completion: nil) + } + + @IBAction func makeReservation(_ sender: Any) { + guard let reservation = newReservation() else { + self.dismiss(animated: true, completion: nil) + return + } + + switch self.presentingViewController { + case let tapbarC as UITabBarController: + if let navigationC = tapbarC.selectedViewController as? UINavigationController, let reservationListVC = navigationC.topViewController as? ReservationListViewController { + reservationListVC.addNewItem(reservation: reservation) + } + case let navigationC as UINavigationController: + if let reservationListVC = navigationC.topViewController as? ReservationListViewController { + reservationListVC.addNewItem(reservation: reservation) + } + case let reservationListVC as ReservationListViewController: + reservationListVC.addNewItem(reservation: reservation) + default: + break + } + + self.dismiss(animated: true, completion: nil) + } + + + // MARK: - Table view data source +/* + override func numberOfSections(in tableView: UITableView) -> Int { + // #warning Incomplete implementation, return the number of sections + return 0 + } + + override func tableView(_ tableView: UITableView, numberOfRowsInSection section: Int) -> Int { + // #warning Incomplete implementation, return the number of rows + return 0 + } +*/ + /* + override func tableView(_ tableView: UITableView, cellForRowAt indexPath: IndexPath) -> UITableViewCell { + let cell = tableView.dequeueReusableCell(withIdentifier: "reuseIdentifier", for: indexPath) + + // Configure the cell... + + return cell + } + */ + + /* + // Override to support conditional editing of the table view. + override func tableView(_ tableView: UITableView, canEditRowAt indexPath: IndexPath) -> Bool { + // Return false if you do not want the specified item to be editable. + return true + } + */ + + /* + // Override to support editing the table view. + override func tableView(_ tableView: UITableView, commit editingStyle: UITableViewCellEditingStyle, forRowAt indexPath: IndexPath) { + if editingStyle == .delete { + // Delete the row from the data source + tableView.deleteRows(at: [indexPath], with: .fade) + } else if editingStyle == .insert { + // Create a new instance of the appropriate class, insert it into the array, and add a new row to the table view + } + } + */ + + /* + // Override to support rearranging the table view. + override func tableView(_ tableView: UITableView, moveRowAt fromIndexPath: IndexPath, to: IndexPath) { + + } + */ + + /* + // Override to support conditional rearranging of the table view. + override func tableView(_ tableView: UITableView, canMoveRowAt indexPath: IndexPath) -> Bool { + // Return false if you do not want the item to be re-orderable. + return true + } + */ + + /* + // MARK: - Navigation + + // In a storyboard-based application, you will often want to do a little preparation before navigation + override func prepare(for segue: UIStoryboardSegue, sender: Any?) { + // Get the new view controller using segue.destinationViewController. + // Pass the selected object to the new view controller. + } + */ + +} diff --git "a/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/meetingRooms_modal present/meetingRooms/RoomInfoViewController.swift" "b/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/meetingRooms_modal present/meetingRooms/RoomInfoViewController.swift" new file mode 100644 index 0000000..61bf80d --- /dev/null +++ "b/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/meetingRooms_modal present/meetingRooms/RoomInfoViewController.swift" @@ -0,0 +1,98 @@ +// +// RoomInfoViewController.swift +// meetingRooms +// +// Created by 황도증 on 2017. 11. 9.. +// Copyright © 2017년 황도증. All rights reserved. +// + +import UIKit + +class RoomInfoViewController: UITableViewController { + + override func viewDidLoad() { + super.viewDidLoad() + + // Uncomment the following line to preserve selection between presentations + // self.clearsSelectionOnViewWillAppear = false + + // Uncomment the following line to display an Edit button in the navigation bar for this view controller. + // self.navigationItem.rightBarButtonItem = self.editButtonItem + } + + override func didReceiveMemoryWarning() { + super.didReceiveMemoryWarning() + // Dispose of any resources that can be recreated. + } + @IBAction func modalDismiss(_ sender: Any) { + self.dismiss(animated: true, completion: nil) + } + /* + // MARK: - Table view data source + + override func numberOfSections(in tableView: UITableView) -> Int { + // #warning Incomplete implementation, return the number of sections + return 0 + } + + override func tableView(_ tableView: UITableView, numberOfRowsInSection section: Int) -> Int { + // #warning Incomplete implementation, return the number of rows + return 0 + } +*/ + /* + override func tableView(_ tableView: UITableView, cellForRowAt indexPath: IndexPath) -> UITableViewCell { + let cell = tableView.dequeueReusableCell(withIdentifier: "reuseIdentifier", for: indexPath) + + // Configure the cell... + + return cell + } + */ + + /* + // Override to support conditional editing of the table view. + override func tableView(_ tableView: UITableView, canEditRowAt indexPath: IndexPath) -> Bool { + // Return false if you do not want the specified item to be editable. + return true + } + */ + + /* + // Override to support editing the table view. + override func tableView(_ tableView: UITableView, commit editingStyle: UITableViewCellEditingStyle, forRowAt indexPath: IndexPath) { + if editingStyle == .delete { + // Delete the row from the data source + tableView.deleteRows(at: [indexPath], with: .fade) + } else if editingStyle == .insert { + // Create a new instance of the appropriate class, insert it into the array, and add a new row to the table view + } + } + */ + + /* + // Override to support rearranging the table view. + override func tableView(_ tableView: UITableView, moveRowAt fromIndexPath: IndexPath, to: IndexPath) { + + } + */ + + /* + // Override to support conditional rearranging of the table view. + override func tableView(_ tableView: UITableView, canMoveRowAt indexPath: IndexPath) -> Bool { + // Return false if you do not want the item to be re-orderable. + return true + } + */ + + /* + // MARK: - Navigation + + // In a storyboard-based application, you will often want to do a little preparation before navigation + override func prepare(for segue: UIStoryboardSegue, sender: Any?) { + // Get the new view controller using segue.destinationViewController. + // Pass the selected object to the new view controller. + } + */ + +} diff --git "a/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/meetingRooms_modal present/meetingRooms/ServiceListViewController.swift" "b/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/meetingRooms_modal present/meetingRooms/ServiceListViewController.swift" new file mode 100644 index 0000000..091d906 --- /dev/null +++ "b/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/meetingRooms_modal present/meetingRooms/ServiceListViewController.swift" @@ -0,0 +1,113 @@ +// +// ServiceListViewController.swift +// meetingRooms +// +// Created by 황도증 on 2017. 11. 9.. +// Copyright © 2017년 황도증. All rights reserved. +// + +import UIKit + +class ServiceListViewController: UITableViewController { + + var branch:Branch? + + override func viewDidLoad() { + super.viewDidLoad() + + // Uncomment the following line to preserve selection between presentations + // self.clearsSelectionOnViewWillAppear = false + + // Uncomment the following line to display an Edit button in the navigation bar for this view controller. + // self.navigationItem.rightBarButtonItem = self.editButtonItem + self.title = branch?.name + self.navigationController?.isToolbarHidden = false + } + + override func didReceiveMemoryWarning() { + super.didReceiveMemoryWarning() + // Dispose of any resources that can be recreated. + } + + // MARK: - Table view data source + + override func numberOfSections(in tableView: UITableView) -> Int { + // #warning Incomplete implementation, return the number of sections + return 1 + } + + override func tableView(_ tableView: UITableView, numberOfRowsInSection section: Int) -> Int { + // #warning Incomplete implementation, return the number of rows + guard let rowCount = branch?.services?.count else { + return 0 + } + return rowCount + } + + + override func tableView(_ tableView: UITableView, cellForRowAt indexPath: IndexPath) -> UITableViewCell { + let cell = tableView.dequeueReusableCell(withIdentifier: "ServiceCell", for: indexPath) + + // Configure the cell... + guard let service = branch?.services?[indexPath.row] else { + return cell + } + + cell.textLabel?.text = service.name + + return cell + } + + + /* + // Override to support conditional editing of the table view. + override func tableView(_ tableView: UITableView, canEditRowAt indexPath: IndexPath) -> Bool { + // Return false if you do not want the specified item to be editable. + return true + } + */ + + /* + // Override to support editing the table view. + override func tableView(_ tableView: UITableView, commit editingStyle: UITableViewCellEditingStyle, forRowAt indexPath: IndexPath) { + if editingStyle == .delete { + // Delete the row from the data source + tableView.deleteRows(at: [indexPath], with: .fade) + } else if editingStyle == .insert { + // Create a new instance of the appropriate class, insert it into the array, and add a new row to the table view + } + } + */ + + /* + // Override to support rearranging the table view. + override func tableView(_ tableView: UITableView, moveRowAt fromIndexPath: IndexPath, to: IndexPath) { + + } + */ + + /* + // Override to support conditional rearranging of the table view. + override func tableView(_ tableView: UITableView, canMoveRowAt indexPath: IndexPath) -> Bool { + // Return false if you do not want the item to be re-orderable. + return true + } + */ + + + // MARK: - Navigation + + // In a storyboard-based application, you will often want to do a little preparation before navigation + override func prepare(for segue: UIStoryboardSegue, sender: Any?) { + // Get the new view controller using segue.destinationViewController. + // Pass the selected object to the new view controller. + if segue.identifier == "MeetingRoomSegue" { + guard let destination = segue.destination as? MeetingRoomListViewController, let selectedIndex = self.tableView.indexPathForSelectedRow?.row, let service = branch?.services?[selectedIndex] else { + return + } + destination.service = service + } + } + + +} diff --git "a/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/meetingRooms_modal present/meetingRooms/ViewController.swift" "b/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/meetingRooms_modal present/meetingRooms/ViewController.swift" new file mode 100644 index 0000000..24bd9b0 --- /dev/null +++ "b/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/meetingRooms_modal present/meetingRooms/ViewController.swift" @@ -0,0 +1,25 @@ +// +// ViewController.swift +// meetingRooms +// +// Created by 황도증 on 2017. 10. 30.. +// Copyright © 2017년 황도증. All rights reserved. +// + +import UIKit + +class ViewController: UIViewController { + + override func viewDidLoad() { + super.viewDidLoad() + // Do any additional setup after loading the view, typically from a nib. + } + + override func didReceiveMemoryWarning() { + super.didReceiveMemoryWarning() + // Dispose of any resources that can be recreated. + } + + +} + diff --git "a/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/meetingRooms_modal present/meetingRoomsTests/Info.plist" "b/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/meetingRooms_modal present/meetingRoomsTests/Info.plist" new file mode 100644 index 0000000..6c40a6c --- /dev/null +++ "b/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/meetingRooms_modal present/meetingRoomsTests/Info.plist" @@ -0,0 +1,22 @@ + + + + + CFBundleDevelopmentRegion + $(DEVELOPMENT_LANGUAGE) + CFBundleExecutable + $(EXECUTABLE_NAME) + CFBundleIdentifier + $(PRODUCT_BUNDLE_IDENTIFIER) + CFBundleInfoDictionaryVersion + 6.0 + CFBundleName + $(PRODUCT_NAME) + CFBundlePackageType + BNDL + CFBundleShortVersionString + 1.0 + CFBundleVersion + 1 + + diff --git "a/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/meetingRooms_modal present/meetingRoomsTests/meetingRoomsTests.swift" "b/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/meetingRooms_modal present/meetingRoomsTests/meetingRoomsTests.swift" new file mode 100644 index 0000000..bfbd8d6 --- /dev/null +++ "b/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/meetingRooms_modal present/meetingRoomsTests/meetingRoomsTests.swift" @@ -0,0 +1,36 @@ +// +// meetingRoomsTests.swift +// meetingRoomsTests +// +// Created by 황도증 on 2017. 10. 30.. +// Copyright © 2017년 황도증. All rights reserved. +// + +import XCTest +@testable import meetingRooms + +class meetingRoomsTests: XCTestCase { + + override func setUp() { + super.setUp() + // Put setup code here. This method is called before the invocation of each test method in the class. + } + + override func tearDown() { + // Put teardown code here. This method is called after the invocation of each test method in the class. + super.tearDown() + } + + func testExample() { + // This is an example of a functional test case. + // Use XCTAssert and related functions to verify your tests produce the correct results. + } + + func testPerformanceExample() { + // This is an example of a performance test case. + self.measure { + // Put the code you want to measure the time of here. + } + } + +} diff --git "a/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/meetingRooms_modal present/meetingRoomsUITests/Info.plist" "b/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/meetingRooms_modal present/meetingRoomsUITests/Info.plist" new file mode 100644 index 0000000..6c40a6c --- /dev/null +++ "b/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/meetingRooms_modal present/meetingRoomsUITests/Info.plist" @@ -0,0 +1,22 @@ + + + + + CFBundleDevelopmentRegion + $(DEVELOPMENT_LANGUAGE) + CFBundleExecutable + $(EXECUTABLE_NAME) + CFBundleIdentifier + $(PRODUCT_BUNDLE_IDENTIFIER) + CFBundleInfoDictionaryVersion + 6.0 + CFBundleName + $(PRODUCT_NAME) + CFBundlePackageType + BNDL + CFBundleShortVersionString + 1.0 + CFBundleVersion + 1 + + diff --git "a/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/meetingRooms_modal present/meetingRoomsUITests/meetingRoomsUITests.swift" "b/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/meetingRooms_modal present/meetingRoomsUITests/meetingRoomsUITests.swift" new file mode 100644 index 0000000..4873bfa --- /dev/null +++ "b/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/meetingRooms_modal present/meetingRoomsUITests/meetingRoomsUITests.swift" @@ -0,0 +1,36 @@ +// +// meetingRoomsUITests.swift +// meetingRoomsUITests +// +// Created by 황도증 on 2017. 10. 30.. +// Copyright © 2017년 황도증. All rights reserved. +// + +import XCTest + +class meetingRoomsUITests: XCTestCase { + + override func setUp() { + super.setUp() + + // Put setup code here. This method is called before the invocation of each test method in the class. + + // In UI tests it is usually best to stop immediately when a failure occurs. + continueAfterFailure = false + // UI tests must launch the application that they test. Doing this in setup will make sure it happens for each test method. + XCUIApplication().launch() + + // In UI tests it’s important to set the initial state - such as interface orientation - required for your tests before they run. The setUp method is a good place to do this. + } + + override func tearDown() { + // Put teardown code here. This method is called after the invocation of each test method in the class. + super.tearDown() + } + + func testExample() { + // Use recording to get started writing UI tests. + // Use XCTAssert and related functions to verify your tests produce the correct results. + } + +} diff --git "a/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/meetingRooms_nav/meetingRooms.xcodeproj/project.pbxproj" "b/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/meetingRooms_nav/meetingRooms.xcodeproj/project.pbxproj" new file mode 100644 index 0000000..d0ea954 --- /dev/null +++ "b/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/meetingRooms_nav/meetingRooms.xcodeproj/project.pbxproj" @@ -0,0 +1,573 @@ +// !$*UTF8*$! +{ + archiveVersion = 1; + classes = { + }; + objectVersion = 48; + objects = { + +/* Begin PBXBuildFile section */ + AE99575B1FA704AF00397D38 /* AppDelegate.swift in Sources */ = {isa = PBXBuildFile; fileRef = AE99575A1FA704AF00397D38 /* AppDelegate.swift */; }; + AE99575D1FA704AF00397D38 /* ViewController.swift in Sources */ = {isa = PBXBuildFile; fileRef = AE99575C1FA704AF00397D38 /* ViewController.swift */; }; + AE9957601FA704AF00397D38 /* Main.storyboard in Resources */ = {isa = PBXBuildFile; fileRef = AE99575E1FA704AF00397D38 /* Main.storyboard */; }; + AE9957621FA704AF00397D38 /* Assets.xcassets in Resources */ = {isa = PBXBuildFile; fileRef = AE9957611FA704AF00397D38 /* Assets.xcassets */; }; + AE9957651FA704AF00397D38 /* LaunchScreen.storyboard in Resources */ = {isa = PBXBuildFile; fileRef = AE9957631FA704AF00397D38 /* LaunchScreen.storyboard */; }; + AE9957701FA704AF00397D38 /* meetingRoomsTests.swift in Sources */ = {isa = PBXBuildFile; fileRef = AE99576F1FA704AF00397D38 /* meetingRoomsTests.swift */; }; + AE99577B1FA704B000397D38 /* meetingRoomsUITests.swift in Sources */ = {isa = PBXBuildFile; fileRef = AE99577A1FA704B000397D38 /* meetingRoomsUITests.swift */; }; + AE9957891FA7054800397D38 /* MeetingRoomListViewController.swift in Sources */ = {isa = PBXBuildFile; fileRef = AE9957881FA7054800397D38 /* MeetingRoomListViewController.swift */; }; + AEB3189D1FB4641000AEB094 /* DataCenter.swift in Sources */ = {isa = PBXBuildFile; fileRef = AEB3189C1FB4641000AEB094 /* DataCenter.swift */; }; + AEB3189F1FB4684600AEB094 /* BranchListViewController.swift in Sources */ = {isa = PBXBuildFile; fileRef = AEB3189E1FB4684600AEB094 /* BranchListViewController.swift */; }; + AEB318A11FB4685800AEB094 /* ServiceListViewController.swift in Sources */ = {isa = PBXBuildFile; fileRef = AEB318A01FB4685800AEB094 /* ServiceListViewController.swift */; }; +/* End PBXBuildFile section */ + +/* Begin PBXContainerItemProxy section */ + AE99576C1FA704AF00397D38 /* PBXContainerItemProxy */ = { + isa = PBXContainerItemProxy; + containerPortal = AE99574F1FA704AF00397D38 /* Project object */; + proxyType = 1; + remoteGlobalIDString = AE9957561FA704AF00397D38; + remoteInfo = meetingRooms; + }; + AE9957771FA704B000397D38 /* PBXContainerItemProxy */ = { + isa = PBXContainerItemProxy; + containerPortal = AE99574F1FA704AF00397D38 /* Project object */; + proxyType = 1; + remoteGlobalIDString = AE9957561FA704AF00397D38; + remoteInfo = meetingRooms; + }; +/* End PBXContainerItemProxy section */ + +/* Begin PBXFileReference section */ + AE9957571FA704AF00397D38 /* meetingRooms.app */ = {isa = PBXFileReference; explicitFileType = wrapper.application; includeInIndex = 0; path = meetingRooms.app; sourceTree = BUILT_PRODUCTS_DIR; }; + AE99575A1FA704AF00397D38 /* AppDelegate.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = AppDelegate.swift; sourceTree = ""; }; + AE99575C1FA704AF00397D38 /* ViewController.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = ViewController.swift; sourceTree = ""; }; + AE99575F1FA704AF00397D38 /* Base */ = {isa = PBXFileReference; lastKnownFileType = file.storyboard; name = Base; path = Base.lproj/Main.storyboard; sourceTree = ""; }; + AE9957611FA704AF00397D38 /* Assets.xcassets */ = {isa = PBXFileReference; lastKnownFileType = folder.assetcatalog; path = Assets.xcassets; sourceTree = ""; }; + AE9957641FA704AF00397D38 /* Base */ = {isa = PBXFileReference; lastKnownFileType = file.storyboard; name = Base; path = Base.lproj/LaunchScreen.storyboard; sourceTree = ""; }; + AE9957661FA704AF00397D38 /* Info.plist */ = {isa = PBXFileReference; lastKnownFileType = text.plist.xml; path = Info.plist; sourceTree = ""; }; + AE99576B1FA704AF00397D38 /* meetingRoomsTests.xctest */ = {isa = PBXFileReference; explicitFileType = wrapper.cfbundle; includeInIndex = 0; path = meetingRoomsTests.xctest; sourceTree = BUILT_PRODUCTS_DIR; }; + AE99576F1FA704AF00397D38 /* meetingRoomsTests.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = meetingRoomsTests.swift; sourceTree = ""; }; + AE9957711FA704AF00397D38 /* Info.plist */ = {isa = PBXFileReference; lastKnownFileType = text.plist.xml; path = Info.plist; sourceTree = ""; }; + AE9957761FA704B000397D38 /* meetingRoomsUITests.xctest */ = {isa = PBXFileReference; explicitFileType = wrapper.cfbundle; includeInIndex = 0; path = meetingRoomsUITests.xctest; sourceTree = BUILT_PRODUCTS_DIR; }; + AE99577A1FA704B000397D38 /* meetingRoomsUITests.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = meetingRoomsUITests.swift; sourceTree = ""; }; + AE99577C1FA704B000397D38 /* Info.plist */ = {isa = PBXFileReference; lastKnownFileType = text.plist.xml; path = Info.plist; sourceTree = ""; }; + AE9957881FA7054800397D38 /* MeetingRoomListViewController.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = MeetingRoomListViewController.swift; sourceTree = ""; }; + AEB3189C1FB4641000AEB094 /* DataCenter.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = DataCenter.swift; sourceTree = ""; }; + AEB3189E1FB4684600AEB094 /* BranchListViewController.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = BranchListViewController.swift; sourceTree = ""; }; + AEB318A01FB4685800AEB094 /* ServiceListViewController.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = ServiceListViewController.swift; sourceTree = ""; }; +/* End PBXFileReference section */ + +/* Begin PBXFrameworksBuildPhase section */ + AE9957541FA704AF00397D38 /* Frameworks */ = { + isa = PBXFrameworksBuildPhase; + buildActionMask = 2147483647; + files = ( + ); + runOnlyForDeploymentPostprocessing = 0; + }; + AE9957681FA704AF00397D38 /* Frameworks */ = { + isa = PBXFrameworksBuildPhase; + buildActionMask = 2147483647; + files = ( + ); + runOnlyForDeploymentPostprocessing = 0; + }; + AE9957731FA704B000397D38 /* Frameworks */ = { + isa = PBXFrameworksBuildPhase; + buildActionMask = 2147483647; + files = ( + ); + runOnlyForDeploymentPostprocessing = 0; + }; +/* End PBXFrameworksBuildPhase section */ + +/* Begin PBXGroup section */ + AE99574E1FA704AF00397D38 = { + isa = PBXGroup; + children = ( + AE9957591FA704AF00397D38 /* meetingRooms */, + AE99576E1FA704AF00397D38 /* meetingRoomsTests */, + AE9957791FA704B000397D38 /* meetingRoomsUITests */, + AE9957581FA704AF00397D38 /* Products */, + ); + sourceTree = ""; + }; + AE9957581FA704AF00397D38 /* Products */ = { + isa = PBXGroup; + children = ( + AE9957571FA704AF00397D38 /* meetingRooms.app */, + AE99576B1FA704AF00397D38 /* meetingRoomsTests.xctest */, + AE9957761FA704B000397D38 /* meetingRoomsUITests.xctest */, + ); + name = Products; + sourceTree = ""; + }; + AE9957591FA704AF00397D38 /* meetingRooms */ = { + isa = PBXGroup; + children = ( + AE99575A1FA704AF00397D38 /* AppDelegate.swift */, + AE99575C1FA704AF00397D38 /* ViewController.swift */, + AE99575E1FA704AF00397D38 /* Main.storyboard */, + AEB3189C1FB4641000AEB094 /* DataCenter.swift */, + AEB3189E1FB4684600AEB094 /* BranchListViewController.swift */, + AEB318A01FB4685800AEB094 /* ServiceListViewController.swift */, + AE9957881FA7054800397D38 /* MeetingRoomListViewController.swift */, + AE9957611FA704AF00397D38 /* Assets.xcassets */, + AE9957631FA704AF00397D38 /* LaunchScreen.storyboard */, + AE9957661FA704AF00397D38 /* Info.plist */, + ); + path = meetingRooms; + sourceTree = ""; + }; + AE99576E1FA704AF00397D38 /* meetingRoomsTests */ = { + isa = PBXGroup; + children = ( + AE99576F1FA704AF00397D38 /* meetingRoomsTests.swift */, + AE9957711FA704AF00397D38 /* Info.plist */, + ); + path = meetingRoomsTests; + sourceTree = ""; + }; + AE9957791FA704B000397D38 /* meetingRoomsUITests */ = { + isa = PBXGroup; + children = ( + AE99577A1FA704B000397D38 /* meetingRoomsUITests.swift */, + AE99577C1FA704B000397D38 /* Info.plist */, + ); + path = meetingRoomsUITests; + sourceTree = ""; + }; +/* End PBXGroup section */ + +/* Begin PBXNativeTarget section */ + AE9957561FA704AF00397D38 /* meetingRooms */ = { + isa = PBXNativeTarget; + buildConfigurationList = AE99577F1FA704B000397D38 /* Build configuration list for PBXNativeTarget "meetingRooms" */; + buildPhases = ( + AE9957531FA704AF00397D38 /* Sources */, + AE9957541FA704AF00397D38 /* Frameworks */, + AE9957551FA704AF00397D38 /* Resources */, + ); + buildRules = ( + ); + dependencies = ( + ); + name = meetingRooms; + productName = meetingRooms; + productReference = AE9957571FA704AF00397D38 /* meetingRooms.app */; + productType = "com.apple.product-type.application"; + }; + AE99576A1FA704AF00397D38 /* meetingRoomsTests */ = { + isa = PBXNativeTarget; + buildConfigurationList = AE9957821FA704B000397D38 /* Build configuration list for PBXNativeTarget "meetingRoomsTests" */; + buildPhases = ( + AE9957671FA704AF00397D38 /* Sources */, + AE9957681FA704AF00397D38 /* Frameworks */, + AE9957691FA704AF00397D38 /* Resources */, + ); + buildRules = ( + ); + dependencies = ( + AE99576D1FA704AF00397D38 /* PBXTargetDependency */, + ); + name = meetingRoomsTests; + productName = meetingRoomsTests; + productReference = AE99576B1FA704AF00397D38 /* meetingRoomsTests.xctest */; + productType = "com.apple.product-type.bundle.unit-test"; + }; + AE9957751FA704B000397D38 /* meetingRoomsUITests */ = { + isa = PBXNativeTarget; + buildConfigurationList = AE9957851FA704B000397D38 /* Build configuration list for PBXNativeTarget "meetingRoomsUITests" */; + buildPhases = ( + AE9957721FA704B000397D38 /* Sources */, + AE9957731FA704B000397D38 /* Frameworks */, + AE9957741FA704B000397D38 /* Resources */, + ); + buildRules = ( + ); + dependencies = ( + AE9957781FA704B000397D38 /* PBXTargetDependency */, + ); + name = meetingRoomsUITests; + productName = meetingRoomsUITests; + productReference = AE9957761FA704B000397D38 /* meetingRoomsUITests.xctest */; + productType = "com.apple.product-type.bundle.ui-testing"; + }; +/* End PBXNativeTarget section */ + +/* Begin PBXProject section */ + AE99574F1FA704AF00397D38 /* Project object */ = { + isa = PBXProject; + attributes = { + LastSwiftUpdateCheck = 0900; + LastUpgradeCheck = 0900; + ORGANIZATIONNAME = "황도증"; + TargetAttributes = { + AE9957561FA704AF00397D38 = { + CreatedOnToolsVersion = 9.0.1; + ProvisioningStyle = Automatic; + }; + AE99576A1FA704AF00397D38 = { + CreatedOnToolsVersion = 9.0.1; + ProvisioningStyle = Automatic; + TestTargetID = AE9957561FA704AF00397D38; + }; + AE9957751FA704B000397D38 = { + CreatedOnToolsVersion = 9.0.1; + ProvisioningStyle = Automatic; + TestTargetID = AE9957561FA704AF00397D38; + }; + }; + }; + buildConfigurationList = AE9957521FA704AF00397D38 /* Build configuration list for PBXProject "meetingRooms" */; + compatibilityVersion = "Xcode 8.0"; + developmentRegion = en; + hasScannedForEncodings = 0; + knownRegions = ( + en, + Base, + ); + mainGroup = AE99574E1FA704AF00397D38; + productRefGroup = AE9957581FA704AF00397D38 /* Products */; + projectDirPath = ""; + projectRoot = ""; + targets = ( + AE9957561FA704AF00397D38 /* meetingRooms */, + AE99576A1FA704AF00397D38 /* meetingRoomsTests */, + AE9957751FA704B000397D38 /* meetingRoomsUITests */, + ); + }; +/* End PBXProject section */ + +/* Begin PBXResourcesBuildPhase section */ + AE9957551FA704AF00397D38 /* Resources */ = { + isa = PBXResourcesBuildPhase; + buildActionMask = 2147483647; + files = ( + AE9957651FA704AF00397D38 /* LaunchScreen.storyboard in Resources */, + AE9957621FA704AF00397D38 /* Assets.xcassets in Resources */, + AE9957601FA704AF00397D38 /* Main.storyboard in Resources */, + ); + runOnlyForDeploymentPostprocessing = 0; + }; + AE9957691FA704AF00397D38 /* Resources */ = { + isa = PBXResourcesBuildPhase; + buildActionMask = 2147483647; + files = ( + ); + runOnlyForDeploymentPostprocessing = 0; + }; + AE9957741FA704B000397D38 /* Resources */ = { + isa = PBXResourcesBuildPhase; + buildActionMask = 2147483647; + files = ( + ); + runOnlyForDeploymentPostprocessing = 0; + }; +/* End PBXResourcesBuildPhase section */ + +/* Begin PBXSourcesBuildPhase section */ + AE9957531FA704AF00397D38 /* Sources */ = { + isa = PBXSourcesBuildPhase; + buildActionMask = 2147483647; + files = ( + AE99575D1FA704AF00397D38 /* ViewController.swift in Sources */, + AE99575B1FA704AF00397D38 /* AppDelegate.swift in Sources */, + AEB3189D1FB4641000AEB094 /* DataCenter.swift in Sources */, + AEB3189F1FB4684600AEB094 /* BranchListViewController.swift in Sources */, + AEB318A11FB4685800AEB094 /* ServiceListViewController.swift in Sources */, + AE9957891FA7054800397D38 /* MeetingRoomListViewController.swift in Sources */, + ); + runOnlyForDeploymentPostprocessing = 0; + }; + AE9957671FA704AF00397D38 /* Sources */ = { + isa = PBXSourcesBuildPhase; + buildActionMask = 2147483647; + files = ( + AE9957701FA704AF00397D38 /* meetingRoomsTests.swift in Sources */, + ); + runOnlyForDeploymentPostprocessing = 0; + }; + AE9957721FA704B000397D38 /* Sources */ = { + isa = PBXSourcesBuildPhase; + buildActionMask = 2147483647; + files = ( + AE99577B1FA704B000397D38 /* meetingRoomsUITests.swift in Sources */, + ); + runOnlyForDeploymentPostprocessing = 0; + }; +/* End PBXSourcesBuildPhase section */ + +/* Begin PBXTargetDependency section */ + AE99576D1FA704AF00397D38 /* PBXTargetDependency */ = { + isa = PBXTargetDependency; + target = AE9957561FA704AF00397D38 /* meetingRooms */; + targetProxy = AE99576C1FA704AF00397D38 /* PBXContainerItemProxy */; + }; + AE9957781FA704B000397D38 /* PBXTargetDependency */ = { + isa = PBXTargetDependency; + target = AE9957561FA704AF00397D38 /* meetingRooms */; + targetProxy = AE9957771FA704B000397D38 /* PBXContainerItemProxy */; + }; +/* End PBXTargetDependency section */ + +/* Begin PBXVariantGroup section */ + AE99575E1FA704AF00397D38 /* Main.storyboard */ = { + isa = PBXVariantGroup; + children = ( + AE99575F1FA704AF00397D38 /* Base */, + ); + name = Main.storyboard; + sourceTree = ""; + }; + AE9957631FA704AF00397D38 /* LaunchScreen.storyboard */ = { + isa = PBXVariantGroup; + children = ( + AE9957641FA704AF00397D38 /* Base */, + ); + name = LaunchScreen.storyboard; + sourceTree = ""; + }; +/* End PBXVariantGroup section */ + +/* Begin XCBuildConfiguration section */ + AE99577D1FA704B000397D38 /* Debug */ = { + isa = XCBuildConfiguration; + buildSettings = { + ALWAYS_SEARCH_USER_PATHS = NO; + CLANG_ANALYZER_NONNULL = YES; + CLANG_ANALYZER_NUMBER_OBJECT_CONVERSION = YES_AGGRESSIVE; + CLANG_CXX_LANGUAGE_STANDARD = "gnu++14"; + CLANG_CXX_LIBRARY = "libc++"; + CLANG_ENABLE_MODULES = YES; + CLANG_ENABLE_OBJC_ARC = YES; + CLANG_WARN_BLOCK_CAPTURE_AUTORELEASING = YES; + CLANG_WARN_BOOL_CONVERSION = YES; + CLANG_WARN_COMMA = YES; + CLANG_WARN_CONSTANT_CONVERSION = YES; + CLANG_WARN_DIRECT_OBJC_ISA_USAGE = YES_ERROR; + CLANG_WARN_DOCUMENTATION_COMMENTS = YES; + CLANG_WARN_EMPTY_BODY = YES; + CLANG_WARN_ENUM_CONVERSION = YES; + CLANG_WARN_INFINITE_RECURSION = YES; + CLANG_WARN_INT_CONVERSION = YES; + CLANG_WARN_NON_LITERAL_NULL_CONVERSION = YES; + CLANG_WARN_OBJC_LITERAL_CONVERSION = YES; + CLANG_WARN_OBJC_ROOT_CLASS = YES_ERROR; + CLANG_WARN_RANGE_LOOP_ANALYSIS = YES; + CLANG_WARN_STRICT_PROTOTYPES = YES; + CLANG_WARN_SUSPICIOUS_MOVE = YES; + CLANG_WARN_UNGUARDED_AVAILABILITY = YES_AGGRESSIVE; + CLANG_WARN_UNREACHABLE_CODE = YES; + CLANG_WARN__DUPLICATE_METHOD_MATCH = YES; + CODE_SIGN_IDENTITY = "iPhone Developer"; + COPY_PHASE_STRIP = NO; + DEBUG_INFORMATION_FORMAT = dwarf; + ENABLE_STRICT_OBJC_MSGSEND = YES; + ENABLE_TESTABILITY = YES; + GCC_C_LANGUAGE_STANDARD = gnu11; + GCC_DYNAMIC_NO_PIC = NO; + GCC_NO_COMMON_BLOCKS = YES; + GCC_OPTIMIZATION_LEVEL = 0; + GCC_PREPROCESSOR_DEFINITIONS = ( + "DEBUG=1", + "$(inherited)", + ); + GCC_WARN_64_TO_32_BIT_CONVERSION = YES; + GCC_WARN_ABOUT_RETURN_TYPE = YES_ERROR; + GCC_WARN_UNDECLARED_SELECTOR = YES; + GCC_WARN_UNINITIALIZED_AUTOS = YES_AGGRESSIVE; + GCC_WARN_UNUSED_FUNCTION = YES; + GCC_WARN_UNUSED_VARIABLE = YES; + IPHONEOS_DEPLOYMENT_TARGET = 11.0; + MTL_ENABLE_DEBUG_INFO = YES; + ONLY_ACTIVE_ARCH = YES; + SDKROOT = iphoneos; + SWIFT_ACTIVE_COMPILATION_CONDITIONS = DEBUG; + SWIFT_OPTIMIZATION_LEVEL = "-Onone"; + }; + name = Debug; + }; + AE99577E1FA704B000397D38 /* Release */ = { + isa = XCBuildConfiguration; + buildSettings = { + ALWAYS_SEARCH_USER_PATHS = NO; + CLANG_ANALYZER_NONNULL = YES; + CLANG_ANALYZER_NUMBER_OBJECT_CONVERSION = YES_AGGRESSIVE; + CLANG_CXX_LANGUAGE_STANDARD = "gnu++14"; + CLANG_CXX_LIBRARY = "libc++"; + CLANG_ENABLE_MODULES = YES; + CLANG_ENABLE_OBJC_ARC = YES; + CLANG_WARN_BLOCK_CAPTURE_AUTORELEASING = YES; + CLANG_WARN_BOOL_CONVERSION = YES; + CLANG_WARN_COMMA = YES; + CLANG_WARN_CONSTANT_CONVERSION = YES; + CLANG_WARN_DIRECT_OBJC_ISA_USAGE = YES_ERROR; + CLANG_WARN_DOCUMENTATION_COMMENTS = YES; + CLANG_WARN_EMPTY_BODY = YES; + CLANG_WARN_ENUM_CONVERSION = YES; + CLANG_WARN_INFINITE_RECURSION = YES; + CLANG_WARN_INT_CONVERSION = YES; + CLANG_WARN_NON_LITERAL_NULL_CONVERSION = YES; + CLANG_WARN_OBJC_LITERAL_CONVERSION = YES; + CLANG_WARN_OBJC_ROOT_CLASS = YES_ERROR; + CLANG_WARN_RANGE_LOOP_ANALYSIS = YES; + CLANG_WARN_STRICT_PROTOTYPES = YES; + CLANG_WARN_SUSPICIOUS_MOVE = YES; + CLANG_WARN_UNGUARDED_AVAILABILITY = YES_AGGRESSIVE; + CLANG_WARN_UNREACHABLE_CODE = YES; + CLANG_WARN__DUPLICATE_METHOD_MATCH = YES; + CODE_SIGN_IDENTITY = "iPhone Developer"; + COPY_PHASE_STRIP = NO; + DEBUG_INFORMATION_FORMAT = "dwarf-with-dsym"; + ENABLE_NS_ASSERTIONS = NO; + ENABLE_STRICT_OBJC_MSGSEND = YES; + GCC_C_LANGUAGE_STANDARD = gnu11; + GCC_NO_COMMON_BLOCKS = YES; + GCC_WARN_64_TO_32_BIT_CONVERSION = YES; + GCC_WARN_ABOUT_RETURN_TYPE = YES_ERROR; + GCC_WARN_UNDECLARED_SELECTOR = YES; + GCC_WARN_UNINITIALIZED_AUTOS = YES_AGGRESSIVE; + GCC_WARN_UNUSED_FUNCTION = YES; + GCC_WARN_UNUSED_VARIABLE = YES; + IPHONEOS_DEPLOYMENT_TARGET = 11.0; + MTL_ENABLE_DEBUG_INFO = NO; + SDKROOT = iphoneos; + SWIFT_OPTIMIZATION_LEVEL = "-Owholemodule"; + VALIDATE_PRODUCT = YES; + }; + name = Release; + }; + AE9957801FA704B000397D38 /* Debug */ = { + isa = XCBuildConfiguration; + buildSettings = { + ASSETCATALOG_COMPILER_APPICON_NAME = AppIcon; + CODE_SIGN_STYLE = Automatic; + INFOPLIST_FILE = meetingRooms/Info.plist; + LD_RUNPATH_SEARCH_PATHS = "$(inherited) @executable_path/Frameworks"; + PRODUCT_BUNDLE_IDENTIFIER = "--------.meetingRooms"; + PRODUCT_NAME = "$(TARGET_NAME)"; + SWIFT_VERSION = 4.0; + TARGETED_DEVICE_FAMILY = "1,2"; + }; + name = Debug; + }; + AE9957811FA704B000397D38 /* Release */ = { + isa = XCBuildConfiguration; + buildSettings = { + ASSETCATALOG_COMPILER_APPICON_NAME = AppIcon; + CODE_SIGN_STYLE = Automatic; + INFOPLIST_FILE = meetingRooms/Info.plist; + LD_RUNPATH_SEARCH_PATHS = "$(inherited) @executable_path/Frameworks"; + PRODUCT_BUNDLE_IDENTIFIER = "--------.meetingRooms"; + PRODUCT_NAME = "$(TARGET_NAME)"; + SWIFT_VERSION = 4.0; + TARGETED_DEVICE_FAMILY = "1,2"; + }; + name = Release; + }; + AE9957831FA704B000397D38 /* Debug */ = { + isa = XCBuildConfiguration; + buildSettings = { + ALWAYS_EMBED_SWIFT_STANDARD_LIBRARIES = YES; + BUNDLE_LOADER = "$(TEST_HOST)"; + CODE_SIGN_STYLE = Automatic; + INFOPLIST_FILE = meetingRoomsTests/Info.plist; + LD_RUNPATH_SEARCH_PATHS = "$(inherited) @executable_path/Frameworks @loader_path/Frameworks"; + PRODUCT_BUNDLE_IDENTIFIER = "--------.meetingRoomsTests"; + PRODUCT_NAME = "$(TARGET_NAME)"; + SWIFT_VERSION = 4.0; + TARGETED_DEVICE_FAMILY = "1,2"; + TEST_HOST = "$(BUILT_PRODUCTS_DIR)/meetingRooms.app/meetingRooms"; + }; + name = Debug; + }; + AE9957841FA704B000397D38 /* Release */ = { + isa = XCBuildConfiguration; + buildSettings = { + ALWAYS_EMBED_SWIFT_STANDARD_LIBRARIES = YES; + BUNDLE_LOADER = "$(TEST_HOST)"; + CODE_SIGN_STYLE = Automatic; + INFOPLIST_FILE = meetingRoomsTests/Info.plist; + LD_RUNPATH_SEARCH_PATHS = "$(inherited) @executable_path/Frameworks @loader_path/Frameworks"; + PRODUCT_BUNDLE_IDENTIFIER = "--------.meetingRoomsTests"; + PRODUCT_NAME = "$(TARGET_NAME)"; + SWIFT_VERSION = 4.0; + TARGETED_DEVICE_FAMILY = "1,2"; + TEST_HOST = "$(BUILT_PRODUCTS_DIR)/meetingRooms.app/meetingRooms"; + }; + name = Release; + }; + AE9957861FA704B000397D38 /* Debug */ = { + isa = XCBuildConfiguration; + buildSettings = { + ALWAYS_EMBED_SWIFT_STANDARD_LIBRARIES = YES; + CODE_SIGN_STYLE = Automatic; + INFOPLIST_FILE = meetingRoomsUITests/Info.plist; + LD_RUNPATH_SEARCH_PATHS = "$(inherited) @executable_path/Frameworks @loader_path/Frameworks"; + PRODUCT_BUNDLE_IDENTIFIER = "--------.meetingRoomsUITests"; + PRODUCT_NAME = "$(TARGET_NAME)"; + SWIFT_VERSION = 4.0; + TARGETED_DEVICE_FAMILY = "1,2"; + TEST_TARGET_NAME = meetingRooms; + }; + name = Debug; + }; + AE9957871FA704B000397D38 /* Release */ = { + isa = XCBuildConfiguration; + buildSettings = { + ALWAYS_EMBED_SWIFT_STANDARD_LIBRARIES = YES; + CODE_SIGN_STYLE = Automatic; + INFOPLIST_FILE = meetingRoomsUITests/Info.plist; + LD_RUNPATH_SEARCH_PATHS = "$(inherited) @executable_path/Frameworks @loader_path/Frameworks"; + PRODUCT_BUNDLE_IDENTIFIER = "--------.meetingRoomsUITests"; + PRODUCT_NAME = "$(TARGET_NAME)"; + SWIFT_VERSION = 4.0; + TARGETED_DEVICE_FAMILY = "1,2"; + TEST_TARGET_NAME = meetingRooms; + }; + name = Release; + }; +/* End XCBuildConfiguration section */ + +/* Begin XCConfigurationList section */ + AE9957521FA704AF00397D38 /* Build configuration list for PBXProject "meetingRooms" */ = { + isa = XCConfigurationList; + buildConfigurations = ( + AE99577D1FA704B000397D38 /* Debug */, + AE99577E1FA704B000397D38 /* Release */, + ); + defaultConfigurationIsVisible = 0; + defaultConfigurationName = Release; + }; + AE99577F1FA704B000397D38 /* Build configuration list for PBXNativeTarget "meetingRooms" */ = { + isa = XCConfigurationList; + buildConfigurations = ( + AE9957801FA704B000397D38 /* Debug */, + AE9957811FA704B000397D38 /* Release */, + ); + defaultConfigurationIsVisible = 0; + defaultConfigurationName = Release; + }; + AE9957821FA704B000397D38 /* Build configuration list for PBXNativeTarget "meetingRoomsTests" */ = { + isa = XCConfigurationList; + buildConfigurations = ( + AE9957831FA704B000397D38 /* Debug */, + AE9957841FA704B000397D38 /* Release */, + ); + defaultConfigurationIsVisible = 0; + defaultConfigurationName = Release; + }; + AE9957851FA704B000397D38 /* Build configuration list for PBXNativeTarget "meetingRoomsUITests" */ = { + isa = XCConfigurationList; + buildConfigurations = ( + AE9957861FA704B000397D38 /* Debug */, + AE9957871FA704B000397D38 /* Release */, + ); + defaultConfigurationIsVisible = 0; + defaultConfigurationName = Release; + }; +/* End XCConfigurationList section */ + }; + rootObject = AE99574F1FA704AF00397D38 /* Project object */; +} diff --git "a/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/meetingRooms_nav/meetingRooms.xcodeproj/project.xcworkspace/contents.xcworkspacedata" "b/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/meetingRooms_nav/meetingRooms.xcodeproj/project.xcworkspace/contents.xcworkspacedata" new file mode 100644 index 0000000..8491799 --- /dev/null +++ "b/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/meetingRooms_nav/meetingRooms.xcodeproj/project.xcworkspace/contents.xcworkspacedata" @@ -0,0 +1,7 @@ + + + + + diff --git "a/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/meetingRooms_nav/meetingRooms/AppDelegate.swift" "b/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/meetingRooms_nav/meetingRooms/AppDelegate.swift" new file mode 100644 index 0000000..fc60321 --- /dev/null +++ "b/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/meetingRooms_nav/meetingRooms/AppDelegate.swift" @@ -0,0 +1,46 @@ +// +// AppDelegate.swift +// meetingRooms +// +// Created by 황도증 on 2017. 10. 30.. +// Copyright © 2017년 황도증. All rights reserved. +// + +import UIKit + +@UIApplicationMain +class AppDelegate: UIResponder, UIApplicationDelegate { + + var window: UIWindow? + + + func application(_ application: UIApplication, didFinishLaunchingWithOptions launchOptions: [UIApplicationLaunchOptionsKey: Any]?) -> Bool { + // Override point for customization after application launch. + return true + } + + func applicationWillResignActive(_ application: UIApplication) { + // Sent when the application is about to move from active to inactive state. This can occur for certain types of temporary interruptions (such as an incoming phone call or SMS message) or when the user quits the application and it begins the transition to the background state. + // Use this method to pause ongoing tasks, disable timers, and invalidate graphics rendering callbacks. Games should use this method to pause the game. + } + + func applicationDidEnterBackground(_ application: UIApplication) { + // Use this method to release shared resources, save user data, invalidate timers, and store enough application state information to restore your application to its current state in case it is terminated later. + // If your application supports background execution, this method is called instead of applicationWillTerminate: when the user quits. + } + + func applicationWillEnterForeground(_ application: UIApplication) { + // Called as part of the transition from the background to the active state; here you can undo many of the changes made on entering the background. + } + + func applicationDidBecomeActive(_ application: UIApplication) { + // Restart any tasks that were paused (or not yet started) while the application was inactive. If the application was previously in the background, optionally refresh the user interface. + } + + func applicationWillTerminate(_ application: UIApplication) { + // Called when the application is about to terminate. Save data if appropriate. See also applicationDidEnterBackground:. + } + + +} + diff --git "a/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/meetingRooms_nav/meetingRooms/Assets.xcassets/AppIcon.appiconset/Contents.json" "b/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/meetingRooms_nav/meetingRooms/Assets.xcassets/AppIcon.appiconset/Contents.json" new file mode 100644 index 0000000..d8db8d6 --- /dev/null +++ "b/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/meetingRooms_nav/meetingRooms/Assets.xcassets/AppIcon.appiconset/Contents.json" @@ -0,0 +1,98 @@ +{ + "images" : [ + { + "idiom" : "iphone", + "size" : "20x20", + "scale" : "2x" + }, + { + "idiom" : "iphone", + "size" : "20x20", + "scale" : "3x" + }, + { + "idiom" : "iphone", + "size" : "29x29", + "scale" : "2x" + }, + { + "idiom" : "iphone", + "size" : "29x29", + "scale" : "3x" + }, + { + "idiom" : "iphone", + "size" : "40x40", + "scale" : "2x" + }, + { + "idiom" : "iphone", + "size" : "40x40", + "scale" : "3x" + }, + { + "idiom" : "iphone", + "size" : "60x60", + "scale" : "2x" + }, + { + "idiom" : "iphone", + "size" : "60x60", + "scale" : "3x" + }, + { + "idiom" : "ipad", + "size" : "20x20", + "scale" : "1x" + }, + { + "idiom" : "ipad", + "size" : "20x20", + "scale" : "2x" + }, + { + "idiom" : "ipad", + "size" : "29x29", + "scale" : "1x" + }, + { + "idiom" : "ipad", + "size" : "29x29", + "scale" : "2x" + }, + { + "idiom" : "ipad", + "size" : "40x40", + "scale" : "1x" + }, + { + "idiom" : "ipad", + "size" : "40x40", + "scale" : "2x" + }, + { + "idiom" : "ipad", + "size" : "76x76", + "scale" : "1x" + }, + { + "idiom" : "ipad", + "size" : "76x76", + "scale" : "2x" + }, + { + "idiom" : "ipad", + "size" : "83.5x83.5", + "scale" : "2x" + }, + { + "idiom" : "ios-marketing", + "size" : "1024x1024", + "scale" : "1x" + } + ], + "info" : { + "version" : 1, + "author" : "xcode" + } +} \ No newline at end of file diff --git "a/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/meetingRooms_nav/meetingRooms/Base.lproj/LaunchScreen.storyboard" "b/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/meetingRooms_nav/meetingRooms/Base.lproj/LaunchScreen.storyboard" new file mode 100644 index 0000000..f83f6fd --- /dev/null +++ "b/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/meetingRooms_nav/meetingRooms/Base.lproj/LaunchScreen.storyboard" @@ -0,0 +1,25 @@ + + + + + + + + + + + + + + + + + + + + + + + + + diff --git "a/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/meetingRooms_nav/meetingRooms/Base.lproj/Main.storyboard" "b/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/meetingRooms_nav/meetingRooms/Base.lproj/Main.storyboard" new file mode 100644 index 0000000..ad8d924 --- /dev/null +++ "b/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/meetingRooms_nav/meetingRooms/Base.lproj/Main.storyboard" @@ -0,0 +1,137 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + diff --git "a/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/meetingRooms_nav/meetingRooms/BranchListViewController.swift" "b/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/meetingRooms_nav/meetingRooms/BranchListViewController.swift" new file mode 100644 index 0000000..cb19e7c --- /dev/null +++ "b/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/meetingRooms_nav/meetingRooms/BranchListViewController.swift" @@ -0,0 +1,105 @@ +// +// BranchListViewController.swift +// meetingRooms +// +// Created by 황도증 on 2017. 11. 9.. +// Copyright © 2017년 황도증. All rights reserved. +// + +import UIKit + +class BranchListViewController: UITableViewController { + + override func viewDidLoad() { + super.viewDidLoad() + + // Uncomment the following line to preserve selection between presentations + // self.clearsSelectionOnViewWillAppear = false + + // Uncomment the following line to display an Edit button in the navigation bar for this view controller. + // self.navigationItem.rightBarButtonItem = self.editButtonItem + } + + override func didReceiveMemoryWarning() { + super.didReceiveMemoryWarning() + // Dispose of any resources that can be recreated. + } + + // MARK: - Table view data source + + override func numberOfSections(in tableView: UITableView) -> Int { + // #warning Incomplete implementation, return the number of sections + return 1 + } + + override func tableView(_ tableView: UITableView, numberOfRowsInSection section: Int) -> Int { + // #warning Incomplete implementation, return the number of rows + let rowCount = dataCenter.branches.count + return rowCount + } + + + override func tableView(_ tableView: UITableView, cellForRowAt indexPath: IndexPath) -> UITableViewCell { + let cell = tableView.dequeueReusableCell(withIdentifier: "BranchCell", for: indexPath) + + // Configure the cell... + let branch = dataCenter.branches[indexPath.row] + cell.textLabel?.text = branch.name + + return cell + } + + + /* + // Override to support conditional editing of the table view. + override func tableView(_ tableView: UITableView, canEditRowAt indexPath: IndexPath) -> Bool { + // Return false if you do not want the specified item to be editable. + return true + } + */ + + /* + // Override to support editing the table view. + override func tableView(_ tableView: UITableView, commit editingStyle: UITableViewCellEditingStyle, forRowAt indexPath: IndexPath) { + if editingStyle == .delete { + // Delete the row from the data source + tableView.deleteRows(at: [indexPath], with: .fade) + } else if editingStyle == .insert { + // Create a new instance of the appropriate class, insert it into the array, and add a new row to the table view + } + } + */ + + /* + // Override to support rearranging the table view. + override func tableView(_ tableView: UITableView, moveRowAt fromIndexPath: IndexPath, to: IndexPath) { + + } + */ + + /* + // Override to support conditional rearranging of the table view. + override func tableView(_ tableView: UITableView, canMoveRowAt indexPath: IndexPath) -> Bool { + // Return false if you do not want the item to be re-orderable. + return true + } + */ + + + // MARK: - Navigation + + // In a storyboard-based application, you will often want to do a little preparation before navigation + override func prepare(for segue: UIStoryboardSegue, sender: Any?) { + // Get the new view controller using segue.destinationViewController. + // Pass the selected object to the new view controller. + + if segue.identifier == "ServiceSegue" { + if let destination = segue.destination as? ServiceListViewController { + if let selectedIndex = self.tableView.indexPathForSelectedRow?.row { + destination.branch = dataCenter.branches[selectedIndex] as Branch + } + } + } + + } +} diff --git "a/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/meetingRooms_nav/meetingRooms/DataCenter.swift" "b/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/meetingRooms_nav/meetingRooms/DataCenter.swift" new file mode 100644 index 0000000..4231269 --- /dev/null +++ "b/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/meetingRooms_nav/meetingRooms/DataCenter.swift" @@ -0,0 +1,66 @@ +// +// DataCenter.swift +// meetingRooms +// +// Created by 황도증 on 2017. 11. 9.. +// Copyright © 2017년 황도증. All rights reserved. +// + +import Foundation + +let dataCenter:DataCenter = DataCenter() + +class DataCenter { + var branches:[Branch] = [] + + init (){ + let banksyRoom = MeetingRoom(name:"Banksy", capacity: 4) + let kahloRoom = MeetingRoom(name:"Kahlo", capacity: 8) + let riveraRoom = MeetingRoom(name:"Rivera", capacity: 8) + let picasoRoom = MeetingRoom(name:"Picaso", capacity: 10) + + let vehicleService = Service(name: "차량예약") + let meetingRoomService = Service(name: "회의실예약") + let visitorService = Service(name: "방문자예약") + let deskService = Service(name: "데스크예약") + meetingRoomService.items = [banksyRoom, kahloRoom, riveraRoom, picasoRoom] + + let pangyoBranch = Branch(name: "판교점") + let samsungBranch = Branch(name: "삼성점") + let yeoksamBranch = Branch(name: "역삼점") + let sinrimBranch = Branch(name: "신림점") + let songdooBranch = Branch(name: "송도점") + let anamBranch = Branch(name: "안암점") + pangyoBranch.services = [vehicleService, meetingRoomService, visitorService, deskService] + + branches += [pangyoBranch, samsungBranch, yeoksamBranch, sinrimBranch, songdooBranch, anamBranch] + } +} + +class Branch { + let name:String + var services:[Service]? + + init(name:String) { + self.name = name + } +} + +class Service { + let name:String + var items:[MeetingRoom]? + + init(name:String) { + self.name = name + } +} + +class MeetingRoom { + let name:String + let capacity:Int + + init(name:String, capacity:Int) { + self.name = name + self.capacity = capacity + } +} diff --git "a/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/meetingRooms_nav/meetingRooms/Info.plist" "b/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/meetingRooms_nav/meetingRooms/Info.plist" new file mode 100644 index 0000000..16be3b6 --- /dev/null +++ "b/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/meetingRooms_nav/meetingRooms/Info.plist" @@ -0,0 +1,45 @@ + + + + + CFBundleDevelopmentRegion + $(DEVELOPMENT_LANGUAGE) + CFBundleExecutable + $(EXECUTABLE_NAME) + CFBundleIdentifier + $(PRODUCT_BUNDLE_IDENTIFIER) + CFBundleInfoDictionaryVersion + 6.0 + CFBundleName + $(PRODUCT_NAME) + CFBundlePackageType + APPL + CFBundleShortVersionString + 1.0 + CFBundleVersion + 1 + LSRequiresIPhoneOS + + UILaunchStoryboardName + LaunchScreen + UIMainStoryboardFile + Main + UIRequiredDeviceCapabilities + + armv7 + + UISupportedInterfaceOrientations + + UIInterfaceOrientationPortrait + UIInterfaceOrientationLandscapeLeft + UIInterfaceOrientationLandscapeRight + + UISupportedInterfaceOrientations~ipad + + UIInterfaceOrientationPortrait + UIInterfaceOrientationPortraitUpsideDown + UIInterfaceOrientationLandscapeLeft + UIInterfaceOrientationLandscapeRight + + + diff --git "a/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/meetingRooms_nav/meetingRooms/MeetingRoomListViewController.swift" "b/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/meetingRooms_nav/meetingRooms/MeetingRoomListViewController.swift" new file mode 100644 index 0000000..0d523b3 --- /dev/null +++ "b/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/meetingRooms_nav/meetingRooms/MeetingRoomListViewController.swift" @@ -0,0 +1,111 @@ +// +// MeetingRoomListViewController.swift +// meetingRooms +// +// Created by 황도증 on 2017. 10. 30.. +// Copyright © 2017년 황도증. All rights reserved. +// + +import UIKit + +class MeetingRoomListViewController: UITableViewController { + + var service:Service? + + override func viewDidLoad() { + super.viewDidLoad() + + // Uncomment the following line to preserve selection between presentations + // self.clearsSelectionOnViewWillAppear = false + + // Uncomment the following line to display an Edit button in the navigation bar for this view controller. + // self.navigationItem.rightBarButtonItem = self.editButtonItem + + self.title = service?.name + } + + override func didReceiveMemoryWarning() { + super.didReceiveMemoryWarning() + // Dispose of any resources that can be recreated. + } + + // MARK: - Table view data source + + override func numberOfSections(in tableView: UITableView) -> Int { + // #warning Incomplete implementation, return the number of sections + return 1 + } + + override func tableView(_ tableView: UITableView, numberOfRowsInSection section: Int) -> Int { + // #warning Incomplete implementation, return the number of rows + //let categoryValues = Array(meetingRooms.values)[section] + //let orderMeetingRoooms = meetingRooms.sorted(by: {$0.1.first!.1 < $1.1.first!.1}) + guard let rowCount = service?.items?.count else { + return 0 + } + return rowCount + } + + + override func tableView(_ tableView: UITableView, cellForRowAt indexPath: IndexPath) -> UITableViewCell { + let cell = tableView.dequeueReusableCell(withIdentifier: "ItemCell", for: indexPath) + + //let orderMeetingRoooms = meetingRooms.sorted(by: {$0.1.first!.1 < $1.1.first!.1}) + // Configure the cell... + //let categoryValue = Array(meetingRooms.values)[indexPath.section] + + guard let meetingRoom = service?.items?[indexPath.row] else { + return cell + } + + cell.textLabel!.text = meetingRoom.name + cell.detailTextLabel!.text = String(meetingRoom.capacity) + return cell + } + + /* + // Override to support conditional editing of the table view. + override func tableView(_ tableView: UITableView, canEditRowAt indexPath: IndexPath) -> Bool { + // Return false if you do not want the specified item to be editable. + return true + } + */ + + /* + // Override to support editing the table view. + override func tableView(_ tableView: UITableView, commit editingStyle: UITableViewCellEditingStyle, forRowAt indexPath: IndexPath) { + if editingStyle == .delete { + // Delete the row from the data source + tableView.deleteRows(at: [indexPath], with: .fade) + } else if editingStyle == .insert { + // Create a new instance of the appropriate class, insert it into the array, and add a new row to the table view + } + } + */ + + /* + // Override to support rearranging the table view. + override func tableView(_ tableView: UITableView, moveRowAt fromIndexPath: IndexPath, to: IndexPath) { + + } + */ + + /* + // Override to support conditional rearranging of the table view. + override func tableView(_ tableView: UITableView, canMoveRowAt indexPath: IndexPath) -> Bool { + // Return false if you do not want the item to be re-orderable. + return true + } + */ + + + // MARK: - Navigation +/* + // In a storyboard-based application, you will often want to do a little preparation before navigation + override func prepare(for segue: UIStoryboardSegue, sender: Any?) { + // Get the new view controller using segue.destinationViewController. + // Pass the selected object to the new view controller. + + } + */ +} diff --git "a/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/meetingRooms_nav/meetingRooms/ServiceListViewController.swift" "b/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/meetingRooms_nav/meetingRooms/ServiceListViewController.swift" new file mode 100644 index 0000000..b153586 --- /dev/null +++ "b/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/meetingRooms_nav/meetingRooms/ServiceListViewController.swift" @@ -0,0 +1,113 @@ +// +// ServiceListViewController.swift +// meetingRooms +// +// Created by 황도증 on 2017. 11. 9.. +// Copyright © 2017년 황도증. All rights reserved. +// + +import UIKit + +class ServiceListViewController: UITableViewController { + + var branch:Branch? + + override func viewDidLoad() { + super.viewDidLoad() + + // Uncomment the following line to preserve selection between presentations + // self.clearsSelectionOnViewWillAppear = false + + // Uncomment the following line to display an Edit button in the navigation bar for this view controller. + // self.navigationItem.rightBarButtonItem = self.editButtonItem + self.title = branch?.name + self.navigationItem.title = "\(branch!.name) 정보" + } + + override func didReceiveMemoryWarning() { + super.didReceiveMemoryWarning() + // Dispose of any resources that can be recreated. + } + + // MARK: - Table view data source + + override func numberOfSections(in tableView: UITableView) -> Int { + // #warning Incomplete implementation, return the number of sections + return 1 + } + + override func tableView(_ tableView: UITableView, numberOfRowsInSection section: Int) -> Int { + // #warning Incomplete implementation, return the number of rows + guard let rowCount = branch?.services?.count else { + return 0 + } + return rowCount + } + + + override func tableView(_ tableView: UITableView, cellForRowAt indexPath: IndexPath) -> UITableViewCell { + let cell = tableView.dequeueReusableCell(withIdentifier: "ServiceCell", for: indexPath) + + // Configure the cell... + guard let service = branch?.services?[indexPath.row] else { + return cell + } + + cell.textLabel?.text = service.name + + return cell + } + + + /* + // Override to support conditional editing of the table view. + override func tableView(_ tableView: UITableView, canEditRowAt indexPath: IndexPath) -> Bool { + // Return false if you do not want the specified item to be editable. + return true + } + */ + + /* + // Override to support editing the table view. + override func tableView(_ tableView: UITableView, commit editingStyle: UITableViewCellEditingStyle, forRowAt indexPath: IndexPath) { + if editingStyle == .delete { + // Delete the row from the data source + tableView.deleteRows(at: [indexPath], with: .fade) + } else if editingStyle == .insert { + // Create a new instance of the appropriate class, insert it into the array, and add a new row to the table view + } + } + */ + + /* + // Override to support rearranging the table view. + override func tableView(_ tableView: UITableView, moveRowAt fromIndexPath: IndexPath, to: IndexPath) { + + } + */ + + /* + // Override to support conditional rearranging of the table view. + override func tableView(_ tableView: UITableView, canMoveRowAt indexPath: IndexPath) -> Bool { + // Return false if you do not want the item to be re-orderable. + return true + } + */ + + + // MARK: - Navigation + + // In a storyboard-based application, you will often want to do a little preparation before navigation + override func prepare(for segue: UIStoryboardSegue, sender: Any?) { + // Get the new view controller using segue.destinationViewController. + // Pass the selected object to the new view controller. + if segue.identifier == "MeetingRoomSegue" { + guard let destination = segue.destination as? MeetingRoomListViewController, let selectedIndex = self.tableView.indexPathForSelectedRow?.row, let service = branch?.services?[selectedIndex] else { + return + } + destination.service = service + } + } + + +} diff --git "a/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/meetingRooms_nav/meetingRooms/ViewController.swift" "b/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/meetingRooms_nav/meetingRooms/ViewController.swift" new file mode 100644 index 0000000..24bd9b0 --- /dev/null +++ "b/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/meetingRooms_nav/meetingRooms/ViewController.swift" @@ -0,0 +1,25 @@ +// +// ViewController.swift +// meetingRooms +// +// Created by 황도증 on 2017. 10. 30.. +// Copyright © 2017년 황도증. All rights reserved. +// + +import UIKit + +class ViewController: UIViewController { + + override func viewDidLoad() { + super.viewDidLoad() + // Do any additional setup after loading the view, typically from a nib. + } + + override func didReceiveMemoryWarning() { + super.didReceiveMemoryWarning() + // Dispose of any resources that can be recreated. + } + + +} + diff --git "a/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/meetingRooms_nav/meetingRoomsTests/Info.plist" "b/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/meetingRooms_nav/meetingRoomsTests/Info.plist" new file mode 100644 index 0000000..6c40a6c --- /dev/null +++ "b/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/meetingRooms_nav/meetingRoomsTests/Info.plist" @@ -0,0 +1,22 @@ + + + + + CFBundleDevelopmentRegion + $(DEVELOPMENT_LANGUAGE) + CFBundleExecutable + $(EXECUTABLE_NAME) + CFBundleIdentifier + $(PRODUCT_BUNDLE_IDENTIFIER) + CFBundleInfoDictionaryVersion + 6.0 + CFBundleName + $(PRODUCT_NAME) + CFBundlePackageType + BNDL + CFBundleShortVersionString + 1.0 + CFBundleVersion + 1 + + diff --git "a/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/meetingRooms_nav/meetingRoomsTests/meetingRoomsTests.swift" "b/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/meetingRooms_nav/meetingRoomsTests/meetingRoomsTests.swift" new file mode 100644 index 0000000..bfbd8d6 --- /dev/null +++ "b/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/meetingRooms_nav/meetingRoomsTests/meetingRoomsTests.swift" @@ -0,0 +1,36 @@ +// +// meetingRoomsTests.swift +// meetingRoomsTests +// +// Created by 황도증 on 2017. 10. 30.. +// Copyright © 2017년 황도증. All rights reserved. +// + +import XCTest +@testable import meetingRooms + +class meetingRoomsTests: XCTestCase { + + override func setUp() { + super.setUp() + // Put setup code here. This method is called before the invocation of each test method in the class. + } + + override func tearDown() { + // Put teardown code here. This method is called after the invocation of each test method in the class. + super.tearDown() + } + + func testExample() { + // This is an example of a functional test case. + // Use XCTAssert and related functions to verify your tests produce the correct results. + } + + func testPerformanceExample() { + // This is an example of a performance test case. + self.measure { + // Put the code you want to measure the time of here. + } + } + +} diff --git "a/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/meetingRooms_nav/meetingRoomsUITests/Info.plist" "b/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/meetingRooms_nav/meetingRoomsUITests/Info.plist" new file mode 100644 index 0000000..6c40a6c --- /dev/null +++ "b/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/meetingRooms_nav/meetingRoomsUITests/Info.plist" @@ -0,0 +1,22 @@ + + + + + CFBundleDevelopmentRegion + $(DEVELOPMENT_LANGUAGE) + CFBundleExecutable + $(EXECUTABLE_NAME) + CFBundleIdentifier + $(PRODUCT_BUNDLE_IDENTIFIER) + CFBundleInfoDictionaryVersion + 6.0 + CFBundleName + $(PRODUCT_NAME) + CFBundlePackageType + BNDL + CFBundleShortVersionString + 1.0 + CFBundleVersion + 1 + + diff --git "a/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/meetingRooms_nav/meetingRoomsUITests/meetingRoomsUITests.swift" "b/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/meetingRooms_nav/meetingRoomsUITests/meetingRoomsUITests.swift" new file mode 100644 index 0000000..4873bfa --- /dev/null +++ "b/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/meetingRooms_nav/meetingRoomsUITests/meetingRoomsUITests.swift" @@ -0,0 +1,36 @@ +// +// meetingRoomsUITests.swift +// meetingRoomsUITests +// +// Created by 황도증 on 2017. 10. 30.. +// Copyright © 2017년 황도증. All rights reserved. +// + +import XCTest + +class meetingRoomsUITests: XCTestCase { + + override func setUp() { + super.setUp() + + // Put setup code here. This method is called before the invocation of each test method in the class. + + // In UI tests it is usually best to stop immediately when a failure occurs. + continueAfterFailure = false + // UI tests must launch the application that they test. Doing this in setup will make sure it happens for each test method. + XCUIApplication().launch() + + // In UI tests it’s important to set the initial state - such as interface orientation - required for your tests before they run. The setUp method is a good place to do this. + } + + override func tearDown() { + // Put teardown code here. This method is called after the invocation of each test method in the class. + super.tearDown() + } + + func testExample() { + // Use recording to get started writing UI tests. + // Use XCTAssert and related functions to verify your tests produce the correct results. + } + +} diff --git "a/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/meetingRooms_plist/meetingRooms.xcodeproj/project.pbxproj" "b/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/meetingRooms_plist/meetingRooms.xcodeproj/project.pbxproj" new file mode 100644 index 0000000..b4485a0 --- /dev/null +++ "b/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/meetingRooms_plist/meetingRooms.xcodeproj/project.pbxproj" @@ -0,0 +1,597 @@ +// !$*UTF8*$! +{ + archiveVersion = 1; + classes = { + }; + objectVersion = 48; + objects = { + +/* Begin PBXBuildFile section */ + AE99575B1FA704AF00397D38 /* AppDelegate.swift in Sources */ = {isa = PBXBuildFile; fileRef = AE99575A1FA704AF00397D38 /* AppDelegate.swift */; }; + AE99575D1FA704AF00397D38 /* ViewController.swift in Sources */ = {isa = PBXBuildFile; fileRef = AE99575C1FA704AF00397D38 /* ViewController.swift */; }; + AE9957601FA704AF00397D38 /* Main.storyboard in Resources */ = {isa = PBXBuildFile; fileRef = AE99575E1FA704AF00397D38 /* Main.storyboard */; }; + AE9957621FA704AF00397D38 /* Assets.xcassets in Resources */ = {isa = PBXBuildFile; fileRef = AE9957611FA704AF00397D38 /* Assets.xcassets */; }; + AE9957651FA704AF00397D38 /* LaunchScreen.storyboard in Resources */ = {isa = PBXBuildFile; fileRef = AE9957631FA704AF00397D38 /* LaunchScreen.storyboard */; }; + AE9957701FA704AF00397D38 /* meetingRoomsTests.swift in Sources */ = {isa = PBXBuildFile; fileRef = AE99576F1FA704AF00397D38 /* meetingRoomsTests.swift */; }; + AE99577B1FA704B000397D38 /* meetingRoomsUITests.swift in Sources */ = {isa = PBXBuildFile; fileRef = AE99577A1FA704B000397D38 /* meetingRoomsUITests.swift */; }; + AE9957891FA7054800397D38 /* MeetingRoomListViewController.swift in Sources */ = {isa = PBXBuildFile; fileRef = AE9957881FA7054800397D38 /* MeetingRoomListViewController.swift */; }; + AEB3189D1FB4641000AEB094 /* DataCenter.swift in Sources */ = {isa = PBXBuildFile; fileRef = AEB3189C1FB4641000AEB094 /* DataCenter.swift */; }; + AEB3189F1FB4684600AEB094 /* BranchListViewController.swift in Sources */ = {isa = PBXBuildFile; fileRef = AEB3189E1FB4684600AEB094 /* BranchListViewController.swift */; }; + AEB318A11FB4685800AEB094 /* ServiceListViewController.swift in Sources */ = {isa = PBXBuildFile; fileRef = AEB318A01FB4685800AEB094 /* ServiceListViewController.swift */; }; + AEB318A31FB4807F00AEB094 /* RoomInfoViewController.swift in Sources */ = {isa = PBXBuildFile; fileRef = AEB318A21FB4807F00AEB094 /* RoomInfoViewController.swift */; }; + AEB318A51FB485D300AEB094 /* ReservationListViewController.swift in Sources */ = {isa = PBXBuildFile; fileRef = AEB318A41FB485D300AEB094 /* ReservationListViewController.swift */; }; + AEB318A71FB4861600AEB094 /* ReserveRoomViewController.swift in Sources */ = {isa = PBXBuildFile; fileRef = AEB318A61FB4861600AEB094 /* ReserveRoomViewController.swift */; }; + AEB318A91FB4975F00AEB094 /* TintColorViewController.swift in Sources */ = {isa = PBXBuildFile; fileRef = AEB318A81FB4975F00AEB094 /* TintColorViewController.swift */; }; + AEB318AB1FB49D1900AEB094 /* EquipmentDefault.plist in Resources */ = {isa = PBXBuildFile; fileRef = AEB318AA1FB49D1900AEB094 /* EquipmentDefault.plist */; }; + AEB318AD1FB4C41A00AEB094 /* EquipmentsListViewController.swift in Sources */ = {isa = PBXBuildFile; fileRef = AEB318AC1FB4C41A00AEB094 /* EquipmentsListViewController.swift */; }; +/* End PBXBuildFile section */ + +/* Begin PBXContainerItemProxy section */ + AE99576C1FA704AF00397D38 /* PBXContainerItemProxy */ = { + isa = PBXContainerItemProxy; + containerPortal = AE99574F1FA704AF00397D38 /* Project object */; + proxyType = 1; + remoteGlobalIDString = AE9957561FA704AF00397D38; + remoteInfo = meetingRooms; + }; + AE9957771FA704B000397D38 /* PBXContainerItemProxy */ = { + isa = PBXContainerItemProxy; + containerPortal = AE99574F1FA704AF00397D38 /* Project object */; + proxyType = 1; + remoteGlobalIDString = AE9957561FA704AF00397D38; + remoteInfo = meetingRooms; + }; +/* End PBXContainerItemProxy section */ + +/* Begin PBXFileReference section */ + AE9957571FA704AF00397D38 /* meetingRooms.app */ = {isa = PBXFileReference; explicitFileType = wrapper.application; includeInIndex = 0; path = meetingRooms.app; sourceTree = BUILT_PRODUCTS_DIR; }; + AE99575A1FA704AF00397D38 /* AppDelegate.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = AppDelegate.swift; sourceTree = ""; }; + AE99575C1FA704AF00397D38 /* ViewController.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = ViewController.swift; sourceTree = ""; }; + AE99575F1FA704AF00397D38 /* Base */ = {isa = PBXFileReference; lastKnownFileType = file.storyboard; name = Base; path = Base.lproj/Main.storyboard; sourceTree = ""; }; + AE9957611FA704AF00397D38 /* Assets.xcassets */ = {isa = PBXFileReference; lastKnownFileType = folder.assetcatalog; path = Assets.xcassets; sourceTree = ""; }; + AE9957641FA704AF00397D38 /* Base */ = {isa = PBXFileReference; lastKnownFileType = file.storyboard; name = Base; path = Base.lproj/LaunchScreen.storyboard; sourceTree = ""; }; + AE9957661FA704AF00397D38 /* Info.plist */ = {isa = PBXFileReference; lastKnownFileType = text.plist.xml; path = Info.plist; sourceTree = ""; }; + AE99576B1FA704AF00397D38 /* meetingRoomsTests.xctest */ = {isa = PBXFileReference; explicitFileType = wrapper.cfbundle; includeInIndex = 0; path = meetingRoomsTests.xctest; sourceTree = BUILT_PRODUCTS_DIR; }; + AE99576F1FA704AF00397D38 /* meetingRoomsTests.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = meetingRoomsTests.swift; sourceTree = ""; }; + AE9957711FA704AF00397D38 /* Info.plist */ = {isa = PBXFileReference; lastKnownFileType = text.plist.xml; path = Info.plist; sourceTree = ""; }; + AE9957761FA704B000397D38 /* meetingRoomsUITests.xctest */ = {isa = PBXFileReference; explicitFileType = wrapper.cfbundle; includeInIndex = 0; path = meetingRoomsUITests.xctest; sourceTree = BUILT_PRODUCTS_DIR; }; + AE99577A1FA704B000397D38 /* meetingRoomsUITests.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = meetingRoomsUITests.swift; sourceTree = ""; }; + AE99577C1FA704B000397D38 /* Info.plist */ = {isa = PBXFileReference; lastKnownFileType = text.plist.xml; path = Info.plist; sourceTree = ""; }; + AE9957881FA7054800397D38 /* MeetingRoomListViewController.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = MeetingRoomListViewController.swift; sourceTree = ""; }; + AEB3189C1FB4641000AEB094 /* DataCenter.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = DataCenter.swift; sourceTree = ""; }; + AEB3189E1FB4684600AEB094 /* BranchListViewController.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = BranchListViewController.swift; sourceTree = ""; }; + AEB318A01FB4685800AEB094 /* ServiceListViewController.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = ServiceListViewController.swift; sourceTree = ""; }; + AEB318A21FB4807F00AEB094 /* RoomInfoViewController.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = RoomInfoViewController.swift; sourceTree = ""; }; + AEB318A41FB485D300AEB094 /* ReservationListViewController.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = ReservationListViewController.swift; sourceTree = ""; }; + AEB318A61FB4861600AEB094 /* ReserveRoomViewController.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = ReserveRoomViewController.swift; sourceTree = ""; }; + AEB318A81FB4975F00AEB094 /* TintColorViewController.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = TintColorViewController.swift; sourceTree = ""; }; + AEB318AA1FB49D1900AEB094 /* EquipmentDefault.plist */ = {isa = PBXFileReference; lastKnownFileType = text.plist.xml; path = EquipmentDefault.plist; sourceTree = ""; }; + AEB318AC1FB4C41A00AEB094 /* EquipmentsListViewController.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = EquipmentsListViewController.swift; sourceTree = ""; }; +/* End PBXFileReference section */ + +/* Begin PBXFrameworksBuildPhase section */ + AE9957541FA704AF00397D38 /* Frameworks */ = { + isa = PBXFrameworksBuildPhase; + buildActionMask = 2147483647; + files = ( + ); + runOnlyForDeploymentPostprocessing = 0; + }; + AE9957681FA704AF00397D38 /* Frameworks */ = { + isa = PBXFrameworksBuildPhase; + buildActionMask = 2147483647; + files = ( + ); + runOnlyForDeploymentPostprocessing = 0; + }; + AE9957731FA704B000397D38 /* Frameworks */ = { + isa = PBXFrameworksBuildPhase; + buildActionMask = 2147483647; + files = ( + ); + runOnlyForDeploymentPostprocessing = 0; + }; +/* End PBXFrameworksBuildPhase section */ + +/* Begin PBXGroup section */ + AE99574E1FA704AF00397D38 = { + isa = PBXGroup; + children = ( + AE9957591FA704AF00397D38 /* meetingRooms */, + AE99576E1FA704AF00397D38 /* meetingRoomsTests */, + AE9957791FA704B000397D38 /* meetingRoomsUITests */, + AE9957581FA704AF00397D38 /* Products */, + ); + sourceTree = ""; + }; + AE9957581FA704AF00397D38 /* Products */ = { + isa = PBXGroup; + children = ( + AE9957571FA704AF00397D38 /* meetingRooms.app */, + AE99576B1FA704AF00397D38 /* meetingRoomsTests.xctest */, + AE9957761FA704B000397D38 /* meetingRoomsUITests.xctest */, + ); + name = Products; + sourceTree = ""; + }; + AE9957591FA704AF00397D38 /* meetingRooms */ = { + isa = PBXGroup; + children = ( + AE99575A1FA704AF00397D38 /* AppDelegate.swift */, + AEB318AA1FB49D1900AEB094 /* EquipmentDefault.plist */, + AEB318AC1FB4C41A00AEB094 /* EquipmentsListViewController.swift */, + AE99575C1FA704AF00397D38 /* ViewController.swift */, + AE99575E1FA704AF00397D38 /* Main.storyboard */, + AEB318A81FB4975F00AEB094 /* TintColorViewController.swift */, + AEB318A61FB4861600AEB094 /* ReserveRoomViewController.swift */, + AEB318A41FB485D300AEB094 /* ReservationListViewController.swift */, + AEB318A21FB4807F00AEB094 /* RoomInfoViewController.swift */, + AEB3189C1FB4641000AEB094 /* DataCenter.swift */, + AEB3189E1FB4684600AEB094 /* BranchListViewController.swift */, + AEB318A01FB4685800AEB094 /* ServiceListViewController.swift */, + AE9957881FA7054800397D38 /* MeetingRoomListViewController.swift */, + AE9957611FA704AF00397D38 /* Assets.xcassets */, + AE9957631FA704AF00397D38 /* LaunchScreen.storyboard */, + AE9957661FA704AF00397D38 /* Info.plist */, + ); + path = meetingRooms; + sourceTree = ""; + }; + AE99576E1FA704AF00397D38 /* meetingRoomsTests */ = { + isa = PBXGroup; + children = ( + AE99576F1FA704AF00397D38 /* meetingRoomsTests.swift */, + AE9957711FA704AF00397D38 /* Info.plist */, + ); + path = meetingRoomsTests; + sourceTree = ""; + }; + AE9957791FA704B000397D38 /* meetingRoomsUITests */ = { + isa = PBXGroup; + children = ( + AE99577A1FA704B000397D38 /* meetingRoomsUITests.swift */, + AE99577C1FA704B000397D38 /* Info.plist */, + ); + path = meetingRoomsUITests; + sourceTree = ""; + }; +/* End PBXGroup section */ + +/* Begin PBXNativeTarget section */ + AE9957561FA704AF00397D38 /* meetingRooms */ = { + isa = PBXNativeTarget; + buildConfigurationList = AE99577F1FA704B000397D38 /* Build configuration list for PBXNativeTarget "meetingRooms" */; + buildPhases = ( + AE9957531FA704AF00397D38 /* Sources */, + AE9957541FA704AF00397D38 /* Frameworks */, + AE9957551FA704AF00397D38 /* Resources */, + ); + buildRules = ( + ); + dependencies = ( + ); + name = meetingRooms; + productName = meetingRooms; + productReference = AE9957571FA704AF00397D38 /* meetingRooms.app */; + productType = "com.apple.product-type.application"; + }; + AE99576A1FA704AF00397D38 /* meetingRoomsTests */ = { + isa = PBXNativeTarget; + buildConfigurationList = AE9957821FA704B000397D38 /* Build configuration list for PBXNativeTarget "meetingRoomsTests" */; + buildPhases = ( + AE9957671FA704AF00397D38 /* Sources */, + AE9957681FA704AF00397D38 /* Frameworks */, + AE9957691FA704AF00397D38 /* Resources */, + ); + buildRules = ( + ); + dependencies = ( + AE99576D1FA704AF00397D38 /* PBXTargetDependency */, + ); + name = meetingRoomsTests; + productName = meetingRoomsTests; + productReference = AE99576B1FA704AF00397D38 /* meetingRoomsTests.xctest */; + productType = "com.apple.product-type.bundle.unit-test"; + }; + AE9957751FA704B000397D38 /* meetingRoomsUITests */ = { + isa = PBXNativeTarget; + buildConfigurationList = AE9957851FA704B000397D38 /* Build configuration list for PBXNativeTarget "meetingRoomsUITests" */; + buildPhases = ( + AE9957721FA704B000397D38 /* Sources */, + AE9957731FA704B000397D38 /* Frameworks */, + AE9957741FA704B000397D38 /* Resources */, + ); + buildRules = ( + ); + dependencies = ( + AE9957781FA704B000397D38 /* PBXTargetDependency */, + ); + name = meetingRoomsUITests; + productName = meetingRoomsUITests; + productReference = AE9957761FA704B000397D38 /* meetingRoomsUITests.xctest */; + productType = "com.apple.product-type.bundle.ui-testing"; + }; +/* End PBXNativeTarget section */ + +/* Begin PBXProject section */ + AE99574F1FA704AF00397D38 /* Project object */ = { + isa = PBXProject; + attributes = { + LastSwiftUpdateCheck = 0900; + LastUpgradeCheck = 0900; + ORGANIZATIONNAME = "황도증"; + TargetAttributes = { + AE9957561FA704AF00397D38 = { + CreatedOnToolsVersion = 9.0.1; + ProvisioningStyle = Automatic; + }; + AE99576A1FA704AF00397D38 = { + CreatedOnToolsVersion = 9.0.1; + ProvisioningStyle = Automatic; + TestTargetID = AE9957561FA704AF00397D38; + }; + AE9957751FA704B000397D38 = { + CreatedOnToolsVersion = 9.0.1; + ProvisioningStyle = Automatic; + TestTargetID = AE9957561FA704AF00397D38; + }; + }; + }; + buildConfigurationList = AE9957521FA704AF00397D38 /* Build configuration list for PBXProject "meetingRooms" */; + compatibilityVersion = "Xcode 8.0"; + developmentRegion = en; + hasScannedForEncodings = 0; + knownRegions = ( + en, + Base, + ); + mainGroup = AE99574E1FA704AF00397D38; + productRefGroup = AE9957581FA704AF00397D38 /* Products */; + projectDirPath = ""; + projectRoot = ""; + targets = ( + AE9957561FA704AF00397D38 /* meetingRooms */, + AE99576A1FA704AF00397D38 /* meetingRoomsTests */, + AE9957751FA704B000397D38 /* meetingRoomsUITests */, + ); + }; +/* End PBXProject section */ + +/* Begin PBXResourcesBuildPhase section */ + AE9957551FA704AF00397D38 /* Resources */ = { + isa = PBXResourcesBuildPhase; + buildActionMask = 2147483647; + files = ( + AE9957651FA704AF00397D38 /* LaunchScreen.storyboard in Resources */, + AEB318AB1FB49D1900AEB094 /* EquipmentDefault.plist in Resources */, + AE9957621FA704AF00397D38 /* Assets.xcassets in Resources */, + AE9957601FA704AF00397D38 /* Main.storyboard in Resources */, + ); + runOnlyForDeploymentPostprocessing = 0; + }; + AE9957691FA704AF00397D38 /* Resources */ = { + isa = PBXResourcesBuildPhase; + buildActionMask = 2147483647; + files = ( + ); + runOnlyForDeploymentPostprocessing = 0; + }; + AE9957741FA704B000397D38 /* Resources */ = { + isa = PBXResourcesBuildPhase; + buildActionMask = 2147483647; + files = ( + ); + runOnlyForDeploymentPostprocessing = 0; + }; +/* End PBXResourcesBuildPhase section */ + +/* Begin PBXSourcesBuildPhase section */ + AE9957531FA704AF00397D38 /* Sources */ = { + isa = PBXSourcesBuildPhase; + buildActionMask = 2147483647; + files = ( + AEB318A31FB4807F00AEB094 /* RoomInfoViewController.swift in Sources */, + AE99575D1FA704AF00397D38 /* ViewController.swift in Sources */, + AE99575B1FA704AF00397D38 /* AppDelegate.swift in Sources */, + AEB318AD1FB4C41A00AEB094 /* EquipmentsListViewController.swift in Sources */, + AEB318A51FB485D300AEB094 /* ReservationListViewController.swift in Sources */, + AEB3189D1FB4641000AEB094 /* DataCenter.swift in Sources */, + AEB3189F1FB4684600AEB094 /* BranchListViewController.swift in Sources */, + AEB318A11FB4685800AEB094 /* ServiceListViewController.swift in Sources */, + AE9957891FA7054800397D38 /* MeetingRoomListViewController.swift in Sources */, + AEB318A71FB4861600AEB094 /* ReserveRoomViewController.swift in Sources */, + AEB318A91FB4975F00AEB094 /* TintColorViewController.swift in Sources */, + ); + runOnlyForDeploymentPostprocessing = 0; + }; + AE9957671FA704AF00397D38 /* Sources */ = { + isa = PBXSourcesBuildPhase; + buildActionMask = 2147483647; + files = ( + AE9957701FA704AF00397D38 /* meetingRoomsTests.swift in Sources */, + ); + runOnlyForDeploymentPostprocessing = 0; + }; + AE9957721FA704B000397D38 /* Sources */ = { + isa = PBXSourcesBuildPhase; + buildActionMask = 2147483647; + files = ( + AE99577B1FA704B000397D38 /* meetingRoomsUITests.swift in Sources */, + ); + runOnlyForDeploymentPostprocessing = 0; + }; +/* End PBXSourcesBuildPhase section */ + +/* Begin PBXTargetDependency section */ + AE99576D1FA704AF00397D38 /* PBXTargetDependency */ = { + isa = PBXTargetDependency; + target = AE9957561FA704AF00397D38 /* meetingRooms */; + targetProxy = AE99576C1FA704AF00397D38 /* PBXContainerItemProxy */; + }; + AE9957781FA704B000397D38 /* PBXTargetDependency */ = { + isa = PBXTargetDependency; + target = AE9957561FA704AF00397D38 /* meetingRooms */; + targetProxy = AE9957771FA704B000397D38 /* PBXContainerItemProxy */; + }; +/* End PBXTargetDependency section */ + +/* Begin PBXVariantGroup section */ + AE99575E1FA704AF00397D38 /* Main.storyboard */ = { + isa = PBXVariantGroup; + children = ( + AE99575F1FA704AF00397D38 /* Base */, + ); + name = Main.storyboard; + sourceTree = ""; + }; + AE9957631FA704AF00397D38 /* LaunchScreen.storyboard */ = { + isa = PBXVariantGroup; + children = ( + AE9957641FA704AF00397D38 /* Base */, + ); + name = LaunchScreen.storyboard; + sourceTree = ""; + }; +/* End PBXVariantGroup section */ + +/* Begin XCBuildConfiguration section */ + AE99577D1FA704B000397D38 /* Debug */ = { + isa = XCBuildConfiguration; + buildSettings = { + ALWAYS_SEARCH_USER_PATHS = NO; + CLANG_ANALYZER_NONNULL = YES; + CLANG_ANALYZER_NUMBER_OBJECT_CONVERSION = YES_AGGRESSIVE; + CLANG_CXX_LANGUAGE_STANDARD = "gnu++14"; + CLANG_CXX_LIBRARY = "libc++"; + CLANG_ENABLE_MODULES = YES; + CLANG_ENABLE_OBJC_ARC = YES; + CLANG_WARN_BLOCK_CAPTURE_AUTORELEASING = YES; + CLANG_WARN_BOOL_CONVERSION = YES; + CLANG_WARN_COMMA = YES; + CLANG_WARN_CONSTANT_CONVERSION = YES; + CLANG_WARN_DIRECT_OBJC_ISA_USAGE = YES_ERROR; + CLANG_WARN_DOCUMENTATION_COMMENTS = YES; + CLANG_WARN_EMPTY_BODY = YES; + CLANG_WARN_ENUM_CONVERSION = YES; + CLANG_WARN_INFINITE_RECURSION = YES; + CLANG_WARN_INT_CONVERSION = YES; + CLANG_WARN_NON_LITERAL_NULL_CONVERSION = YES; + CLANG_WARN_OBJC_LITERAL_CONVERSION = YES; + CLANG_WARN_OBJC_ROOT_CLASS = YES_ERROR; + CLANG_WARN_RANGE_LOOP_ANALYSIS = YES; + CLANG_WARN_STRICT_PROTOTYPES = YES; + CLANG_WARN_SUSPICIOUS_MOVE = YES; + CLANG_WARN_UNGUARDED_AVAILABILITY = YES_AGGRESSIVE; + CLANG_WARN_UNREACHABLE_CODE = YES; + CLANG_WARN__DUPLICATE_METHOD_MATCH = YES; + CODE_SIGN_IDENTITY = "iPhone Developer"; + COPY_PHASE_STRIP = NO; + DEBUG_INFORMATION_FORMAT = dwarf; + ENABLE_STRICT_OBJC_MSGSEND = YES; + ENABLE_TESTABILITY = YES; + GCC_C_LANGUAGE_STANDARD = gnu11; + GCC_DYNAMIC_NO_PIC = NO; + GCC_NO_COMMON_BLOCKS = YES; + GCC_OPTIMIZATION_LEVEL = 0; + GCC_PREPROCESSOR_DEFINITIONS = ( + "DEBUG=1", + "$(inherited)", + ); + GCC_WARN_64_TO_32_BIT_CONVERSION = YES; + GCC_WARN_ABOUT_RETURN_TYPE = YES_ERROR; + GCC_WARN_UNDECLARED_SELECTOR = YES; + GCC_WARN_UNINITIALIZED_AUTOS = YES_AGGRESSIVE; + GCC_WARN_UNUSED_FUNCTION = YES; + GCC_WARN_UNUSED_VARIABLE = YES; + IPHONEOS_DEPLOYMENT_TARGET = 11.0; + MTL_ENABLE_DEBUG_INFO = YES; + ONLY_ACTIVE_ARCH = YES; + SDKROOT = iphoneos; + SWIFT_ACTIVE_COMPILATION_CONDITIONS = DEBUG; + SWIFT_OPTIMIZATION_LEVEL = "-Onone"; + }; + name = Debug; + }; + AE99577E1FA704B000397D38 /* Release */ = { + isa = XCBuildConfiguration; + buildSettings = { + ALWAYS_SEARCH_USER_PATHS = NO; + CLANG_ANALYZER_NONNULL = YES; + CLANG_ANALYZER_NUMBER_OBJECT_CONVERSION = YES_AGGRESSIVE; + CLANG_CXX_LANGUAGE_STANDARD = "gnu++14"; + CLANG_CXX_LIBRARY = "libc++"; + CLANG_ENABLE_MODULES = YES; + CLANG_ENABLE_OBJC_ARC = YES; + CLANG_WARN_BLOCK_CAPTURE_AUTORELEASING = YES; + CLANG_WARN_BOOL_CONVERSION = YES; + CLANG_WARN_COMMA = YES; + CLANG_WARN_CONSTANT_CONVERSION = YES; + CLANG_WARN_DIRECT_OBJC_ISA_USAGE = YES_ERROR; + CLANG_WARN_DOCUMENTATION_COMMENTS = YES; + CLANG_WARN_EMPTY_BODY = YES; + CLANG_WARN_ENUM_CONVERSION = YES; + CLANG_WARN_INFINITE_RECURSION = YES; + CLANG_WARN_INT_CONVERSION = YES; + CLANG_WARN_NON_LITERAL_NULL_CONVERSION = YES; + CLANG_WARN_OBJC_LITERAL_CONVERSION = YES; + CLANG_WARN_OBJC_ROOT_CLASS = YES_ERROR; + CLANG_WARN_RANGE_LOOP_ANALYSIS = YES; + CLANG_WARN_STRICT_PROTOTYPES = YES; + CLANG_WARN_SUSPICIOUS_MOVE = YES; + CLANG_WARN_UNGUARDED_AVAILABILITY = YES_AGGRESSIVE; + CLANG_WARN_UNREACHABLE_CODE = YES; + CLANG_WARN__DUPLICATE_METHOD_MATCH = YES; + CODE_SIGN_IDENTITY = "iPhone Developer"; + COPY_PHASE_STRIP = NO; + DEBUG_INFORMATION_FORMAT = "dwarf-with-dsym"; + ENABLE_NS_ASSERTIONS = NO; + ENABLE_STRICT_OBJC_MSGSEND = YES; + GCC_C_LANGUAGE_STANDARD = gnu11; + GCC_NO_COMMON_BLOCKS = YES; + GCC_WARN_64_TO_32_BIT_CONVERSION = YES; + GCC_WARN_ABOUT_RETURN_TYPE = YES_ERROR; + GCC_WARN_UNDECLARED_SELECTOR = YES; + GCC_WARN_UNINITIALIZED_AUTOS = YES_AGGRESSIVE; + GCC_WARN_UNUSED_FUNCTION = YES; + GCC_WARN_UNUSED_VARIABLE = YES; + IPHONEOS_DEPLOYMENT_TARGET = 11.0; + MTL_ENABLE_DEBUG_INFO = NO; + SDKROOT = iphoneos; + SWIFT_OPTIMIZATION_LEVEL = "-Owholemodule"; + VALIDATE_PRODUCT = YES; + }; + name = Release; + }; + AE9957801FA704B000397D38 /* Debug */ = { + isa = XCBuildConfiguration; + buildSettings = { + ASSETCATALOG_COMPILER_APPICON_NAME = AppIcon; + CODE_SIGN_STYLE = Automatic; + INFOPLIST_FILE = meetingRooms/Info.plist; + LD_RUNPATH_SEARCH_PATHS = "$(inherited) @executable_path/Frameworks"; + PRODUCT_BUNDLE_IDENTIFIER = "--------.meetingRooms"; + PRODUCT_NAME = "$(TARGET_NAME)"; + SWIFT_VERSION = 4.0; + TARGETED_DEVICE_FAMILY = "1,2"; + }; + name = Debug; + }; + AE9957811FA704B000397D38 /* Release */ = { + isa = XCBuildConfiguration; + buildSettings = { + ASSETCATALOG_COMPILER_APPICON_NAME = AppIcon; + CODE_SIGN_STYLE = Automatic; + INFOPLIST_FILE = meetingRooms/Info.plist; + LD_RUNPATH_SEARCH_PATHS = "$(inherited) @executable_path/Frameworks"; + PRODUCT_BUNDLE_IDENTIFIER = "--------.meetingRooms"; + PRODUCT_NAME = "$(TARGET_NAME)"; + SWIFT_VERSION = 4.0; + TARGETED_DEVICE_FAMILY = "1,2"; + }; + name = Release; + }; + AE9957831FA704B000397D38 /* Debug */ = { + isa = XCBuildConfiguration; + buildSettings = { + ALWAYS_EMBED_SWIFT_STANDARD_LIBRARIES = YES; + BUNDLE_LOADER = "$(TEST_HOST)"; + CODE_SIGN_STYLE = Automatic; + INFOPLIST_FILE = meetingRoomsTests/Info.plist; + LD_RUNPATH_SEARCH_PATHS = "$(inherited) @executable_path/Frameworks @loader_path/Frameworks"; + PRODUCT_BUNDLE_IDENTIFIER = "--------.meetingRoomsTests"; + PRODUCT_NAME = "$(TARGET_NAME)"; + SWIFT_VERSION = 4.0; + TARGETED_DEVICE_FAMILY = "1,2"; + TEST_HOST = "$(BUILT_PRODUCTS_DIR)/meetingRooms.app/meetingRooms"; + }; + name = Debug; + }; + AE9957841FA704B000397D38 /* Release */ = { + isa = XCBuildConfiguration; + buildSettings = { + ALWAYS_EMBED_SWIFT_STANDARD_LIBRARIES = YES; + BUNDLE_LOADER = "$(TEST_HOST)"; + CODE_SIGN_STYLE = Automatic; + INFOPLIST_FILE = meetingRoomsTests/Info.plist; + LD_RUNPATH_SEARCH_PATHS = "$(inherited) @executable_path/Frameworks @loader_path/Frameworks"; + PRODUCT_BUNDLE_IDENTIFIER = "--------.meetingRoomsTests"; + PRODUCT_NAME = "$(TARGET_NAME)"; + SWIFT_VERSION = 4.0; + TARGETED_DEVICE_FAMILY = "1,2"; + TEST_HOST = "$(BUILT_PRODUCTS_DIR)/meetingRooms.app/meetingRooms"; + }; + name = Release; + }; + AE9957861FA704B000397D38 /* Debug */ = { + isa = XCBuildConfiguration; + buildSettings = { + ALWAYS_EMBED_SWIFT_STANDARD_LIBRARIES = YES; + CODE_SIGN_STYLE = Automatic; + INFOPLIST_FILE = meetingRoomsUITests/Info.plist; + LD_RUNPATH_SEARCH_PATHS = "$(inherited) @executable_path/Frameworks @loader_path/Frameworks"; + PRODUCT_BUNDLE_IDENTIFIER = "--------.meetingRoomsUITests"; + PRODUCT_NAME = "$(TARGET_NAME)"; + SWIFT_VERSION = 4.0; + TARGETED_DEVICE_FAMILY = "1,2"; + TEST_TARGET_NAME = meetingRooms; + }; + name = Debug; + }; + AE9957871FA704B000397D38 /* Release */ = { + isa = XCBuildConfiguration; + buildSettings = { + ALWAYS_EMBED_SWIFT_STANDARD_LIBRARIES = YES; + CODE_SIGN_STYLE = Automatic; + INFOPLIST_FILE = meetingRoomsUITests/Info.plist; + LD_RUNPATH_SEARCH_PATHS = "$(inherited) @executable_path/Frameworks @loader_path/Frameworks"; + PRODUCT_BUNDLE_IDENTIFIER = "--------.meetingRoomsUITests"; + PRODUCT_NAME = "$(TARGET_NAME)"; + SWIFT_VERSION = 4.0; + TARGETED_DEVICE_FAMILY = "1,2"; + TEST_TARGET_NAME = meetingRooms; + }; + name = Release; + }; +/* End XCBuildConfiguration section */ + +/* Begin XCConfigurationList section */ + AE9957521FA704AF00397D38 /* Build configuration list for PBXProject "meetingRooms" */ = { + isa = XCConfigurationList; + buildConfigurations = ( + AE99577D1FA704B000397D38 /* Debug */, + AE99577E1FA704B000397D38 /* Release */, + ); + defaultConfigurationIsVisible = 0; + defaultConfigurationName = Release; + }; + AE99577F1FA704B000397D38 /* Build configuration list for PBXNativeTarget "meetingRooms" */ = { + isa = XCConfigurationList; + buildConfigurations = ( + AE9957801FA704B000397D38 /* Debug */, + AE9957811FA704B000397D38 /* Release */, + ); + defaultConfigurationIsVisible = 0; + defaultConfigurationName = Release; + }; + AE9957821FA704B000397D38 /* Build configuration list for PBXNativeTarget "meetingRoomsTests" */ = { + isa = XCConfigurationList; + buildConfigurations = ( + AE9957831FA704B000397D38 /* Debug */, + AE9957841FA704B000397D38 /* Release */, + ); + defaultConfigurationIsVisible = 0; + defaultConfigurationName = Release; + }; + AE9957851FA704B000397D38 /* Build configuration list for PBXNativeTarget "meetingRoomsUITests" */ = { + isa = XCConfigurationList; + buildConfigurations = ( + AE9957861FA704B000397D38 /* Debug */, + AE9957871FA704B000397D38 /* Release */, + ); + defaultConfigurationIsVisible = 0; + defaultConfigurationName = Release; + }; +/* End XCConfigurationList section */ + }; + rootObject = AE99574F1FA704AF00397D38 /* Project object */; +} diff --git "a/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/meetingRooms_plist/meetingRooms.xcodeproj/project.xcworkspace/contents.xcworkspacedata" "b/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/meetingRooms_plist/meetingRooms.xcodeproj/project.xcworkspace/contents.xcworkspacedata" new file mode 100644 index 0000000..8491799 --- /dev/null +++ "b/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/meetingRooms_plist/meetingRooms.xcodeproj/project.xcworkspace/contents.xcworkspacedata" @@ -0,0 +1,7 @@ + + + + + diff --git "a/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/meetingRooms_plist/meetingRooms/AppDelegate.swift" "b/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/meetingRooms_plist/meetingRooms/AppDelegate.swift" new file mode 100644 index 0000000..28b9c84 --- /dev/null +++ "b/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/meetingRooms_plist/meetingRooms/AppDelegate.swift" @@ -0,0 +1,50 @@ +// +// AppDelegate.swift +// meetingRooms +// +// Created by 황도증 on 2017. 10. 30.. +// Copyright © 2017년 황도증. All rights reserved. +// + +import UIKit + +@UIApplicationMain +class AppDelegate: UIResponder, UIApplicationDelegate { + + var window: UIWindow? + + func application(_ application: UIApplication, didFinishLaunchingWithOptions launchOptions: [UIApplicationLaunchOptionsKey: Any]?) -> Bool { + // Override point for customization after application launch. + return true + } + + func applicationWillResignActive(_ application: UIApplication) { + // Sent when the application is about to move from active to inactive state. This can occur for certain types of temporary interruptions (such as an incoming phone call or SMS message) or when the user quits the application and it begins the transition to the background state. + // Use this method to pause ongoing tasks, disable timers, and invalidate graphics rendering callbacks. Games should use this method to pause the game. + } + + func applicationDidEnterBackground(_ application: UIApplication) { + // Use this method to release shared resources, save user data, invalidate timers, and store enough application state information to restore your application to its current state in case it is terminated later. + // If your application supports background execution, this method is called instead of applicationWillTerminate: when the user quits. + } + + func applicationWillEnterForeground(_ application: UIApplication) { + // Called as part of the transition from the background to the active state; here you can undo many of the changes made on entering the background. + } + + func applicationDidBecomeActive(_ application: UIApplication) { + // Restart any tasks that were paused (or not yet started) while the application was inactive. If the application was previously in the background, optionally refresh the user interface. + let userDefaultColor = UserDefaults.standard.integer(forKey: TintColorKey) + guard let defaultColor = TintColor(rawValue: userDefaultColor)?.color else { + return + } + applyTintColor(color: defaultColor) + } + + func applicationWillTerminate(_ application: UIApplication) { + // Called when the application is about to terminate. Save data if appropriate. See also applicationDidEnterBackground:. + } + + +} + diff --git "a/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/meetingRooms_plist/meetingRooms/Assets.xcassets/AppIcon.appiconset/Contents.json" "b/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/meetingRooms_plist/meetingRooms/Assets.xcassets/AppIcon.appiconset/Contents.json" new file mode 100644 index 0000000..d8db8d6 --- /dev/null +++ "b/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/meetingRooms_plist/meetingRooms/Assets.xcassets/AppIcon.appiconset/Contents.json" @@ -0,0 +1,98 @@ +{ + "images" : [ + { + "idiom" : "iphone", + "size" : "20x20", + "scale" : "2x" + }, + { + "idiom" : "iphone", + "size" : "20x20", + "scale" : "3x" + }, + { + "idiom" : "iphone", + "size" : "29x29", + "scale" : "2x" + }, + { + "idiom" : "iphone", + "size" : "29x29", + "scale" : "3x" + }, + { + "idiom" : "iphone", + "size" : "40x40", + "scale" : "2x" + }, + { + "idiom" : "iphone", + "size" : "40x40", + "scale" : "3x" + }, + { + "idiom" : "iphone", + "size" : "60x60", + "scale" : "2x" + }, + { + "idiom" : "iphone", + "size" : "60x60", + "scale" : "3x" + }, + { + "idiom" : "ipad", + "size" : "20x20", + "scale" : "1x" + }, + { + "idiom" : "ipad", + "size" : "20x20", + "scale" : "2x" + }, + { + "idiom" : "ipad", + "size" : "29x29", + "scale" : "1x" + }, + { + "idiom" : "ipad", + "size" : "29x29", + "scale" : "2x" + }, + { + "idiom" : "ipad", + "size" : "40x40", + "scale" : "1x" + }, + { + "idiom" : "ipad", + "size" : "40x40", + "scale" : "2x" + }, + { + "idiom" : "ipad", + "size" : "76x76", + "scale" : "1x" + }, + { + "idiom" : "ipad", + "size" : "76x76", + "scale" : "2x" + }, + { + "idiom" : "ipad", + "size" : "83.5x83.5", + "scale" : "2x" + }, + { + "idiom" : "ios-marketing", + "size" : "1024x1024", + "scale" : "1x" + } + ], + "info" : { + "version" : 1, + "author" : "xcode" + } +} \ No newline at end of file diff --git "a/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/meetingRooms_plist/meetingRooms/Base.lproj/LaunchScreen.storyboard" "b/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/meetingRooms_plist/meetingRooms/Base.lproj/LaunchScreen.storyboard" new file mode 100644 index 0000000..f83f6fd --- /dev/null +++ "b/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/meetingRooms_plist/meetingRooms/Base.lproj/LaunchScreen.storyboard" @@ -0,0 +1,25 @@ + + + + + + + + + + + + + + + + + + + + + + + + + diff --git "a/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/meetingRooms_plist/meetingRooms/Base.lproj/Main.storyboard" "b/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/meetingRooms_plist/meetingRooms/Base.lproj/Main.storyboard" new file mode 100644 index 0000000..639f10e --- /dev/null +++ "b/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/meetingRooms_plist/meetingRooms/Base.lproj/Main.storyboard" @@ -0,0 +1,632 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + diff --git "a/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/meetingRooms_plist/meetingRooms/BranchListViewController.swift" "b/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/meetingRooms_plist/meetingRooms/BranchListViewController.swift" new file mode 100644 index 0000000..fa28525 --- /dev/null +++ "b/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/meetingRooms_plist/meetingRooms/BranchListViewController.swift" @@ -0,0 +1,119 @@ +// +// BranchListViewController.swift +// meetingRooms +// +// Created by 황도증 on 2017. 11. 9.. +// Copyright © 2017년 황도증. All rights reserved. +// + +import UIKit + +class BranchListViewController: UITableViewController { + + override func viewDidLoad() { + super.viewDidLoad() + + // Uncomment the following line to preserve selection between presentations + // self.clearsSelectionOnViewWillAppear = false + + // Uncomment the following line to display an Edit button in the navigation bar for this view controller. + // self.navigationItem.rightBarButtonItem = self.editButtonItem + + self.navigationController?.isToolbarHidden = true + } + + override func didReceiveMemoryWarning() { + super.didReceiveMemoryWarning() + // Dispose of any resources that can be recreated. + } + + // MARK: - Table view data source + + override func numberOfSections(in tableView: UITableView) -> Int { + // #warning Incomplete implementation, return the number of sections + return 1 + } + + @IBAction func locationTurnOn(_ sender: Any) { + let locationAlert = UIAlertController(title:"위치정보요청", message: "위치정보를 기반으로 가까운 지점을 자동으로 선택할 수 있습니다.", preferredStyle: .actionSheet) + + let locationAction = UIAlertAction(title: "위치정보켜기", style: .default, handler: {(action:UIAlertAction) -> Void in print("위치정보켜기 선택")}) + + let openMapAction = UIAlertAction(title: "지도에서 열기", style: .default, handler: {(action:UIAlertAction) -> Void in print("지도앱에서 열기 선택")}) + + locationAlert.addAction(locationAction) + locationAlert.addAction(openMapAction) + + self.present(locationAlert, animated: true, completion: nil) + } + override func tableView(_ tableView: UITableView, numberOfRowsInSection section: Int) -> Int { + // #warning Incomplete implementation, return the number of rows + let rowCount = dataCenter.branches.count + return rowCount + } + + + override func tableView(_ tableView: UITableView, cellForRowAt indexPath: IndexPath) -> UITableViewCell { + let cell = tableView.dequeueReusableCell(withIdentifier: "BranchCell", for: indexPath) + + // Configure the cell... + let branch = dataCenter.branches[indexPath.row] + cell.textLabel?.text = branch.name + + return cell + } + + + /* + // Override to support conditional editing of the table view. + override func tableView(_ tableView: UITableView, canEditRowAt indexPath: IndexPath) -> Bool { + // Return false if you do not want the specified item to be editable. + return true + } + */ + + /* + // Override to support editing the table view. + override func tableView(_ tableView: UITableView, commit editingStyle: UITableViewCellEditingStyle, forRowAt indexPath: IndexPath) { + if editingStyle == .delete { + // Delete the row from the data source + tableView.deleteRows(at: [indexPath], with: .fade) + } else if editingStyle == .insert { + // Create a new instance of the appropriate class, insert it into the array, and add a new row to the table view + } + } + */ + + /* + // Override to support rearranging the table view. + override func tableView(_ tableView: UITableView, moveRowAt fromIndexPath: IndexPath, to: IndexPath) { + + } + */ + + /* + // Override to support conditional rearranging of the table view. + override func tableView(_ tableView: UITableView, canMoveRowAt indexPath: IndexPath) -> Bool { + // Return false if you do not want the item to be re-orderable. + return true + } + */ + + + // MARK: - Navigation + + // In a storyboard-based application, you will often want to do a little preparation before navigation + override func prepare(for segue: UIStoryboardSegue, sender: Any?) { + // Get the new view controller using segue.destinationViewController. + // Pass the selected object to the new view controller. + + if segue.identifier == "ServiceSegue" { + if let destination = segue.destination as? ServiceListViewController { + if let selectedIndex = self.tableView.indexPathForSelectedRow?.row { + destination.branch = dataCenter.branches[selectedIndex] as Branch + } + } + } + + } +} diff --git "a/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/meetingRooms_plist/meetingRooms/DataCenter.swift" "b/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/meetingRooms_plist/meetingRooms/DataCenter.swift" new file mode 100644 index 0000000..7476872 --- /dev/null +++ "b/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/meetingRooms_plist/meetingRooms/DataCenter.swift" @@ -0,0 +1,84 @@ +// +// DataCenter.swift +// meetingRooms +// +// Created by 황도증 on 2017. 11. 9.. +// Copyright © 2017년 황도증. All rights reserved. +// + +import Foundation + +let dataCenter:DataCenter = DataCenter() + +class DataCenter { + var branches:[Branch] = [] + + init (){ + let banksyRoom = MeetingRoom(name:"Banksy", capacity: 4) + let kahloRoom = MeetingRoom(name:"Kahlo", capacity: 8) + let riveraRoom = MeetingRoom(name:"Rivera", capacity: 8) + let picasoRoom = MeetingRoom(name:"Picaso", capacity: 10) + + let vehicleService = Service(name: "차량예약") + let meetingRoomService = Service(name: "회의실예약") + let visitorService = Service(name: "방문자예약") + let deskService = Service(name: "데스크예약") + meetingRoomService.items = [banksyRoom, kahloRoom, riveraRoom, picasoRoom] + + let pangyoBranch = Branch(name: "판교점") + let samsungBranch = Branch(name: "삼성점") + let yeoksamBranch = Branch(name: "역삼점") + let sinrimBranch = Branch(name: "신림점") + let songdooBranch = Branch(name: "송도점") + let anamBranch = Branch(name: "안암점") + pangyoBranch.services = [vehicleService, meetingRoomService, visitorService, deskService] + + branches += [pangyoBranch, samsungBranch, yeoksamBranch, sinrimBranch, songdooBranch, anamBranch] + } +} + +class Branch { + let name:String + var services:[Service]? + + init(name:String) { + self.name = name + } +} + +class Service { + let name:String + var items:[MeetingRoom]? + + init(name:String) { + self.name = name + } +} + +class MeetingRoom { + let name:String + let capacity:Int + var reservations:[Reservation]? + + init(name:String, capacity:Int) { + self.name = name + self.capacity = capacity + } +} + +class Reservation { + var hostName:String + var date:NSDate + var attendees:Int + var equipments:[String] + var catering:Bool + + init() { + self.hostName = "host of meeting" + self.date = NSDate() + self.attendees = 1 + self.equipments = [] + self.catering = false + } + +} diff --git "a/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/meetingRooms_plist/meetingRooms/EquipmentDefault.plist" "b/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/meetingRooms_plist/meetingRooms/EquipmentDefault.plist" new file mode 100644 index 0000000..50f805e --- /dev/null +++ "b/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/meetingRooms_plist/meetingRooms/EquipmentDefault.plist" @@ -0,0 +1,30 @@ + + + + + + amount + 12 + name + HDYE 22 + + + amount + 33 + name + DFO 33 + + + amount + 2 + name + WNJ 12 + + + amount + 15 + name + HP 2019 + + + diff --git "a/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/meetingRooms_plist/meetingRooms/EquipmentsListViewController.swift" "b/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/meetingRooms_plist/meetingRooms/EquipmentsListViewController.swift" new file mode 100644 index 0000000..9831526 --- /dev/null +++ "b/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/meetingRooms_plist/meetingRooms/EquipmentsListViewController.swift" @@ -0,0 +1,120 @@ +// +// EquipmentsListViewController.swift +// meetingRooms +// +// Created by 황도증 on 2017. 11. 10.. +// Copyright © 2017년 황도증. All rights reserved. +// + +import UIKit + +let EquipmentFileName = "EquipmentDefault" + +class EquipmentsListViewController: UITableViewController { + + var equipments:Array = [] + + override func viewDidLoad() { + super.viewDidLoad() + + // Uncomment the following line to preserve selection between presentations + // self.clearsSelectionOnViewWillAppear = false + + // Uncomment the following line to display an Edit button in the navigation bar for this view controller. + // self.navigationItem.rightBarButtonItem = self.editButtonItem + + guard let equipmentURL = Bundle.main.url(forResource: EquipmentFileName, withExtension: "plist") else { + print("no file") + return + } + if let equipmentArray = NSArray(contentsOf: equipmentURL) { + print(equipmentArray) + equipments.append(equipmentArray) + } + } + + override func didReceiveMemoryWarning() { + super.didReceiveMemoryWarning() + // Dispose of any resources that can be recreated. + } + + // MARK: - Table view data source + + override func numberOfSections(in tableView: UITableView) -> Int { + // #warning Incomplete implementation, return the number of sections + return 1 + } + + override func tableView(_ tableView: UITableView, numberOfRowsInSection section: Int) -> Int { + // #warning Incomplete implementation, return the number of rows + return equipments.count + } + + + override func tableView(_ tableView: UITableView, cellForRowAt indexPath: IndexPath) -> UITableViewCell { + let cell = tableView.dequeueReusableCell(withIdentifier: "EquipmentCell", for: indexPath) + + // Configure the cell... + guard let equipment = equipments[indexPath.row] as? [String:AnyObject] else { + print("error") + return cell + } + + if let name = equipment["name"] as? String { + cell.textLabel?.text = name + } + + if let amount = equipment["amount"] as? Int { + cell.detailTextLabel?.text = String(amount) + } + + return cell + } + + + /* + // Override to support conditional editing of the table view. + override func tableView(_ tableView: UITableView, canEditRowAt indexPath: IndexPath) -> Bool { + // Return false if you do not want the specified item to be editable. + return true + } + */ + + /* + // Override to support editing the table view. + override func tableView(_ tableView: UITableView, commit editingStyle: UITableViewCellEditingStyle, forRowAt indexPath: IndexPath) { + if editingStyle == .delete { + // Delete the row from the data source + tableView.deleteRows(at: [indexPath], with: .fade) + } else if editingStyle == .insert { + // Create a new instance of the appropriate class, insert it into the array, and add a new row to the table view + } + } + */ + + /* + // Override to support rearranging the table view. + override func tableView(_ tableView: UITableView, moveRowAt fromIndexPath: IndexPath, to: IndexPath) { + + } + */ + + /* + // Override to support conditional rearranging of the table view. + override func tableView(_ tableView: UITableView, canMoveRowAt indexPath: IndexPath) -> Bool { + // Return false if you do not want the item to be re-orderable. + return true + } + */ + + /* + // MARK: - Navigation + + // In a storyboard-based application, you will often want to do a little preparation before navigation + override func prepare(for segue: UIStoryboardSegue, sender: Any?) { + // Get the new view controller using segue.destinationViewController. + // Pass the selected object to the new view controller. + } + */ + +} diff --git "a/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/meetingRooms_plist/meetingRooms/Info.plist" "b/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/meetingRooms_plist/meetingRooms/Info.plist" new file mode 100644 index 0000000..16be3b6 --- /dev/null +++ "b/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/meetingRooms_plist/meetingRooms/Info.plist" @@ -0,0 +1,45 @@ + + + + + CFBundleDevelopmentRegion + $(DEVELOPMENT_LANGUAGE) + CFBundleExecutable + $(EXECUTABLE_NAME) + CFBundleIdentifier + $(PRODUCT_BUNDLE_IDENTIFIER) + CFBundleInfoDictionaryVersion + 6.0 + CFBundleName + $(PRODUCT_NAME) + CFBundlePackageType + APPL + CFBundleShortVersionString + 1.0 + CFBundleVersion + 1 + LSRequiresIPhoneOS + + UILaunchStoryboardName + LaunchScreen + UIMainStoryboardFile + Main + UIRequiredDeviceCapabilities + + armv7 + + UISupportedInterfaceOrientations + + UIInterfaceOrientationPortrait + UIInterfaceOrientationLandscapeLeft + UIInterfaceOrientationLandscapeRight + + UISupportedInterfaceOrientations~ipad + + UIInterfaceOrientationPortrait + UIInterfaceOrientationPortraitUpsideDown + UIInterfaceOrientationLandscapeLeft + UIInterfaceOrientationLandscapeRight + + + diff --git "a/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/meetingRooms_plist/meetingRooms/MeetingRoomListViewController.swift" "b/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/meetingRooms_plist/meetingRooms/MeetingRoomListViewController.swift" new file mode 100644 index 0000000..b56d5ae --- /dev/null +++ "b/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/meetingRooms_plist/meetingRooms/MeetingRoomListViewController.swift" @@ -0,0 +1,117 @@ +// +// MeetingRoomListViewController.swift +// meetingRooms +// +// Created by 황도증 on 2017. 10. 30.. +// Copyright © 2017년 황도증. All rights reserved. +// + +import UIKit + +class MeetingRoomListViewController: UITableViewController { + + var service:Service? + + override func viewDidLoad() { + super.viewDidLoad() + + // Uncomment the following line to preserve selection between presentations + // self.clearsSelectionOnViewWillAppear = false + + // Uncomment the following line to display an Edit button in the navigation bar for this view controller. + // self.navigationItem.rightBarButtonItem = self.editButtonItem + + self.title = service?.name + } + + override func didReceiveMemoryWarning() { + super.didReceiveMemoryWarning() + // Dispose of any resources that can be recreated. + } + + // MARK: - Table view data source + + override func numberOfSections(in tableView: UITableView) -> Int { + // #warning Incomplete implementation, return the number of sections + return 1 + } + + override func tableView(_ tableView: UITableView, numberOfRowsInSection section: Int) -> Int { + // #warning Incomplete implementation, return the number of rows + //let categoryValues = Array(meetingRooms.values)[section] + //let orderMeetingRoooms = meetingRooms.sorted(by: {$0.1.first!.1 < $1.1.first!.1}) + guard let rowCount = service?.items?.count else { + return 0 + } + return rowCount + } + + + override func tableView(_ tableView: UITableView, cellForRowAt indexPath: IndexPath) -> UITableViewCell { + let cell = tableView.dequeueReusableCell(withIdentifier: "ItemCell", for: indexPath) + + //let orderMeetingRoooms = meetingRooms.sorted(by: {$0.1.first!.1 < $1.1.first!.1}) + // Configure the cell... + //let categoryValue = Array(meetingRooms.values)[indexPath.section] + + guard let meetingRoom = service?.items?[indexPath.row] else { + return cell + } + + cell.textLabel!.text = meetingRoom.name + cell.detailTextLabel!.text = String(meetingRoom.capacity) + return cell + } + + /* + // Override to support conditional editing of the table view. + override func tableView(_ tableView: UITableView, canEditRowAt indexPath: IndexPath) -> Bool { + // Return false if you do not want the specified item to be editable. + return true + } + */ + + /* + // Override to support editing the table view. + override func tableView(_ tableView: UITableView, commit editingStyle: UITableViewCellEditingStyle, forRowAt indexPath: IndexPath) { + if editingStyle == .delete { + // Delete the row from the data source + tableView.deleteRows(at: [indexPath], with: .fade) + } else if editingStyle == .insert { + // Create a new instance of the appropriate class, insert it into the array, and add a new row to the table view + } + } + */ + + /* + // Override to support rearranging the table view. + override func tableView(_ tableView: UITableView, moveRowAt fromIndexPath: IndexPath, to: IndexPath) { + + } + */ + + /* + // Override to support conditional rearranging of the table view. + override func tableView(_ tableView: UITableView, canMoveRowAt indexPath: IndexPath) -> Bool { + // Return false if you do not want the item to be re-orderable. + return true + } + */ + + + // MARK: - Navigation + + // In a storyboard-based application, you will often want to do a little preparation before navigation + override func prepare(for segue: UIStoryboardSegue, sender: Any?) { + // Get the new view controller using segue.destinationViewController. + // Pass the selected object to the new view controller. + if segue.identifier == "ReservationSegue" { + guard let destination = segue.destination as? ReservationListViewController, let selectedIndex = self.tableView.indexPathForSelectedRow?.row, let meetingRoom = service?.items?[selectedIndex] else { + return + } + destination.meetingRoom = meetingRoom + } + + } + +} diff --git "a/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/meetingRooms_plist/meetingRooms/ReservationListViewController.swift" "b/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/meetingRooms_plist/meetingRooms/ReservationListViewController.swift" new file mode 100644 index 0000000..7da14de --- /dev/null +++ "b/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/meetingRooms_plist/meetingRooms/ReservationListViewController.swift" @@ -0,0 +1,119 @@ +// +// ReservationListViewController.swift +// meetingRooms +// +// Created by 황도증 on 2017. 11. 9.. +// Copyright © 2017년 황도증. All rights reserved. +// + +import UIKit + +class ReservationListViewController: UITableViewController { + + var meetingRoom:MeetingRoom? + var newReservation:Reservation? + + override func viewDidLoad() { + super.viewDidLoad() + + // Uncomment the following line to preserve selection between presentations + // self.clearsSelectionOnViewWillAppear = false + + // Uncomment the following line to display an Edit button in the navigation bar for this view controller. + // self.navigationItem.rightBarButtonItem = self.editButtonItem + } + + override func didReceiveMemoryWarning() { + super.didReceiveMemoryWarning() + // Dispose of any resources that can be recreated. + } + + func addNewItem(reservation:Reservation) { + if (self.meetingRoom?.reservations?.append(reservation)) == nil { + self.meetingRoom?.reservations = [reservation] + } + self.tableView.reloadData() + } + + @IBAction func unwindToReservationList(segue:UIStoryboardSegue) { + + } + + + // MARK: - Table view data source + + override func numberOfSections(in tableView: UITableView) -> Int { + // #warning Incomplete implementation, return the number of sections + return 1 + } + + override func tableView(_ tableView: UITableView, numberOfRowsInSection section: Int) -> Int { + // #warning Incomplete implementation, return the number of rows + guard let rowCount = meetingRoom?.reservations?.count else { + return 0 + } + return rowCount + } + + + override func tableView(_ tableView: UITableView, cellForRowAt indexPath: IndexPath) -> UITableViewCell { + let cell = tableView.dequeueReusableCell(withIdentifier: "ReservationCell", for: indexPath) + + // Configure the cell... + guard let reservation = meetingRoom?.reservations?[indexPath.row] else { + return cell + } + + cell.textLabel?.text = reservation.date.description + cell.detailTextLabel?.text = reservation.hostName + + return cell + } + + + /* + // Override to support conditional editing of the table view. + override func tableView(_ tableView: UITableView, canEditRowAt indexPath: IndexPath) -> Bool { + // Return false if you do not want the specified item to be editable. + return true + } + */ + + /* + // Override to support editing the table view. + override func tableView(_ tableView: UITableView, commit editingStyle: UITableViewCellEditingStyle, forRowAt indexPath: IndexPath) { + if editingStyle == .delete { + // Delete the row from the data source + tableView.deleteRows(at: [indexPath], with: .fade) + } else if editingStyle == .insert { + // Create a new instance of the appropriate class, insert it into the array, and add a new row to the table view + } + } + */ + + /* + // Override to support rearranging the table view. + override func tableView(_ tableView: UITableView, moveRowAt fromIndexPath: IndexPath, to: IndexPath) { + + } + */ + + /* + // Override to support conditional rearranging of the table view. + override func tableView(_ tableView: UITableView, canMoveRowAt indexPath: IndexPath) -> Bool { + // Return false if you do not want the item to be re-orderable. + return true + } + */ + + /* + // MARK: - Navigation + + // In a storyboard-based application, you will often want to do a little preparation before navigation + override func prepare(for segue: UIStoryboardSegue, sender: Any?) { + // Get the new view controller using segue.destinationViewController. + // Pass the selected object to the new view controller. + } + */ + +} diff --git "a/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/meetingRooms_plist/meetingRooms/ReserveRoomViewController.swift" "b/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/meetingRooms_plist/meetingRooms/ReserveRoomViewController.swift" new file mode 100644 index 0000000..b976043 --- /dev/null +++ "b/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/meetingRooms_plist/meetingRooms/ReserveRoomViewController.swift" @@ -0,0 +1,154 @@ +// +// ReserveRoomViewController.swift +// meetingRooms +// +// Created by 황도증 on 2017. 11. 9.. +// Copyright © 2017년 황도증. All rights reserved. +// + +import UIKit + +class ReserveRoomViewController: UITableViewController { + + @IBOutlet weak var hostNameField: UITextField! + @IBOutlet weak var datePicker: UIDatePicker! + @IBOutlet weak var attendeesField: UITextField! + @IBOutlet weak var equipmentField: UITextField! + @IBOutlet weak var cateringSwitch: UISwitch! + + + override func viewDidLoad() { + super.viewDidLoad() + + // Uncomment the following line to preserve selection between presentations + // self.clearsSelectionOnViewWillAppear = false + + // Uncomment the following line to display an Edit button in the navigation bar for this view controller. + // self.navigationItem.rightBarButtonItem = self.editButtonItem + } + + override func didReceiveMemoryWarning() { + super.didReceiveMemoryWarning() + // Dispose of any resources that can be recreated. + } + + func newReservation() -> Reservation? { + let reservation = Reservation() + let host = hostNameField.text + + if (host?.isEmpty)! { + return nil + } + reservation.hostName = host! + reservation.date = datePicker.date as NSDate + + if let equipmentArray = equipmentField.text?.split(separator: ",").map(String.init) { + reservation.equipments = equipmentArray + } + reservation.catering = cateringSwitch.isOn + return reservation + } + + @IBAction func cancelReservation(_ sender: Any) { + self.dismiss(animated: true, completion: nil) + } + + @IBAction func makeReservation(_ sender: Any) { + guard let reservation = newReservation() else { + self.dismiss(animated: true, completion: nil) + return + } + + switch self.presentingViewController { + case let tapbarC as UITabBarController: + if let navigationC = tapbarC.selectedViewController as? UINavigationController, let reservationListVC = navigationC.topViewController as? ReservationListViewController { + reservationListVC.addNewItem(reservation: reservation) + } + case let navigationC as UINavigationController: + if let reservationListVC = navigationC.topViewController as? ReservationListViewController { + reservationListVC.addNewItem(reservation: reservation) + } + case let reservationListVC as ReservationListViewController: + reservationListVC.addNewItem(reservation: reservation) + default: + break + } + + self.dismiss(animated: true, completion: nil) + } + + + // MARK: - Table view data source +/* + override func numberOfSections(in tableView: UITableView) -> Int { + // #warning Incomplete implementation, return the number of sections + return 0 + } + + override func tableView(_ tableView: UITableView, numberOfRowsInSection section: Int) -> Int { + // #warning Incomplete implementation, return the number of rows + return 0 + } +*/ + /* + override func tableView(_ tableView: UITableView, cellForRowAt indexPath: IndexPath) -> UITableViewCell { + let cell = tableView.dequeueReusableCell(withIdentifier: "reuseIdentifier", for: indexPath) + + // Configure the cell... + + return cell + } + */ + + /* + // Override to support conditional editing of the table view. + override func tableView(_ tableView: UITableView, canEditRowAt indexPath: IndexPath) -> Bool { + // Return false if you do not want the specified item to be editable. + return true + } + */ + + /* + // Override to support editing the table view. + override func tableView(_ tableView: UITableView, commit editingStyle: UITableViewCellEditingStyle, forRowAt indexPath: IndexPath) { + if editingStyle == .delete { + // Delete the row from the data source + tableView.deleteRows(at: [indexPath], with: .fade) + } else if editingStyle == .insert { + // Create a new instance of the appropriate class, insert it into the array, and add a new row to the table view + } + } + */ + + /* + // Override to support rearranging the table view. + override func tableView(_ tableView: UITableView, moveRowAt fromIndexPath: IndexPath, to: IndexPath) { + + } + */ + + /* + // Override to support conditional rearranging of the table view. + override func tableView(_ tableView: UITableView, canMoveRowAt indexPath: IndexPath) -> Bool { + // Return false if you do not want the item to be re-orderable. + return true + } + */ + + + // MARK: - Navigation + + // In a storyboard-based application, you will often want to do a little preparation before navigation + override func prepare(for segue: UIStoryboardSegue, sender: Any?) { + // Get the new view controller using segue.destinationViewController. + // Pass the selected object to the new view controller. + if segue.identifier == "ReserveDone" { + guard let reservation = newReservation(), let reservationListVC = segue.destination as? ReservationListViewController else { + return + } + reservationListVC.addNewItem(reservation: reservation) + } + } + + +} diff --git "a/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/meetingRooms_plist/meetingRooms/RoomInfoViewController.swift" "b/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/meetingRooms_plist/meetingRooms/RoomInfoViewController.swift" new file mode 100644 index 0000000..61bf80d --- /dev/null +++ "b/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/meetingRooms_plist/meetingRooms/RoomInfoViewController.swift" @@ -0,0 +1,98 @@ +// +// RoomInfoViewController.swift +// meetingRooms +// +// Created by 황도증 on 2017. 11. 9.. +// Copyright © 2017년 황도증. All rights reserved. +// + +import UIKit + +class RoomInfoViewController: UITableViewController { + + override func viewDidLoad() { + super.viewDidLoad() + + // Uncomment the following line to preserve selection between presentations + // self.clearsSelectionOnViewWillAppear = false + + // Uncomment the following line to display an Edit button in the navigation bar for this view controller. + // self.navigationItem.rightBarButtonItem = self.editButtonItem + } + + override func didReceiveMemoryWarning() { + super.didReceiveMemoryWarning() + // Dispose of any resources that can be recreated. + } + @IBAction func modalDismiss(_ sender: Any) { + self.dismiss(animated: true, completion: nil) + } + /* + // MARK: - Table view data source + + override func numberOfSections(in tableView: UITableView) -> Int { + // #warning Incomplete implementation, return the number of sections + return 0 + } + + override func tableView(_ tableView: UITableView, numberOfRowsInSection section: Int) -> Int { + // #warning Incomplete implementation, return the number of rows + return 0 + } +*/ + /* + override func tableView(_ tableView: UITableView, cellForRowAt indexPath: IndexPath) -> UITableViewCell { + let cell = tableView.dequeueReusableCell(withIdentifier: "reuseIdentifier", for: indexPath) + + // Configure the cell... + + return cell + } + */ + + /* + // Override to support conditional editing of the table view. + override func tableView(_ tableView: UITableView, canEditRowAt indexPath: IndexPath) -> Bool { + // Return false if you do not want the specified item to be editable. + return true + } + */ + + /* + // Override to support editing the table view. + override func tableView(_ tableView: UITableView, commit editingStyle: UITableViewCellEditingStyle, forRowAt indexPath: IndexPath) { + if editingStyle == .delete { + // Delete the row from the data source + tableView.deleteRows(at: [indexPath], with: .fade) + } else if editingStyle == .insert { + // Create a new instance of the appropriate class, insert it into the array, and add a new row to the table view + } + } + */ + + /* + // Override to support rearranging the table view. + override func tableView(_ tableView: UITableView, moveRowAt fromIndexPath: IndexPath, to: IndexPath) { + + } + */ + + /* + // Override to support conditional rearranging of the table view. + override func tableView(_ tableView: UITableView, canMoveRowAt indexPath: IndexPath) -> Bool { + // Return false if you do not want the item to be re-orderable. + return true + } + */ + + /* + // MARK: - Navigation + + // In a storyboard-based application, you will often want to do a little preparation before navigation + override func prepare(for segue: UIStoryboardSegue, sender: Any?) { + // Get the new view controller using segue.destinationViewController. + // Pass the selected object to the new view controller. + } + */ + +} diff --git "a/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/meetingRooms_plist/meetingRooms/ServiceListViewController.swift" "b/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/meetingRooms_plist/meetingRooms/ServiceListViewController.swift" new file mode 100644 index 0000000..091d906 --- /dev/null +++ "b/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/meetingRooms_plist/meetingRooms/ServiceListViewController.swift" @@ -0,0 +1,113 @@ +// +// ServiceListViewController.swift +// meetingRooms +// +// Created by 황도증 on 2017. 11. 9.. +// Copyright © 2017년 황도증. All rights reserved. +// + +import UIKit + +class ServiceListViewController: UITableViewController { + + var branch:Branch? + + override func viewDidLoad() { + super.viewDidLoad() + + // Uncomment the following line to preserve selection between presentations + // self.clearsSelectionOnViewWillAppear = false + + // Uncomment the following line to display an Edit button in the navigation bar for this view controller. + // self.navigationItem.rightBarButtonItem = self.editButtonItem + self.title = branch?.name + self.navigationController?.isToolbarHidden = false + } + + override func didReceiveMemoryWarning() { + super.didReceiveMemoryWarning() + // Dispose of any resources that can be recreated. + } + + // MARK: - Table view data source + + override func numberOfSections(in tableView: UITableView) -> Int { + // #warning Incomplete implementation, return the number of sections + return 1 + } + + override func tableView(_ tableView: UITableView, numberOfRowsInSection section: Int) -> Int { + // #warning Incomplete implementation, return the number of rows + guard let rowCount = branch?.services?.count else { + return 0 + } + return rowCount + } + + + override func tableView(_ tableView: UITableView, cellForRowAt indexPath: IndexPath) -> UITableViewCell { + let cell = tableView.dequeueReusableCell(withIdentifier: "ServiceCell", for: indexPath) + + // Configure the cell... + guard let service = branch?.services?[indexPath.row] else { + return cell + } + + cell.textLabel?.text = service.name + + return cell + } + + + /* + // Override to support conditional editing of the table view. + override func tableView(_ tableView: UITableView, canEditRowAt indexPath: IndexPath) -> Bool { + // Return false if you do not want the specified item to be editable. + return true + } + */ + + /* + // Override to support editing the table view. + override func tableView(_ tableView: UITableView, commit editingStyle: UITableViewCellEditingStyle, forRowAt indexPath: IndexPath) { + if editingStyle == .delete { + // Delete the row from the data source + tableView.deleteRows(at: [indexPath], with: .fade) + } else if editingStyle == .insert { + // Create a new instance of the appropriate class, insert it into the array, and add a new row to the table view + } + } + */ + + /* + // Override to support rearranging the table view. + override func tableView(_ tableView: UITableView, moveRowAt fromIndexPath: IndexPath, to: IndexPath) { + + } + */ + + /* + // Override to support conditional rearranging of the table view. + override func tableView(_ tableView: UITableView, canMoveRowAt indexPath: IndexPath) -> Bool { + // Return false if you do not want the item to be re-orderable. + return true + } + */ + + + // MARK: - Navigation + + // In a storyboard-based application, you will often want to do a little preparation before navigation + override func prepare(for segue: UIStoryboardSegue, sender: Any?) { + // Get the new view controller using segue.destinationViewController. + // Pass the selected object to the new view controller. + if segue.identifier == "MeetingRoomSegue" { + guard let destination = segue.destination as? MeetingRoomListViewController, let selectedIndex = self.tableView.indexPathForSelectedRow?.row, let service = branch?.services?[selectedIndex] else { + return + } + destination.service = service + } + } + + +} diff --git "a/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/meetingRooms_plist/meetingRooms/TintColorViewController.swift" "b/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/meetingRooms_plist/meetingRooms/TintColorViewController.swift" new file mode 100644 index 0000000..9ba2c19 --- /dev/null +++ "b/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/meetingRooms_plist/meetingRooms/TintColorViewController.swift" @@ -0,0 +1,76 @@ +// +// TintColorViewController.swift +// meetingRooms +// +// Created by 황도증 on 2017. 11. 9.. +// Copyright © 2017년 황도증. All rights reserved. +// + +import UIKit + +enum TintColor:Int { + case Blue = 0, Red, Green, Purple + + var color:UIColor { get { + switch self { + case .Blue: + return UIColor.blue + case .Red: + return UIColor.red + case .Green: + return UIColor.green + case .Purple: + return UIColor.purple + } + } + + } +} + +let TintColorKey = "TintColor" + +func applyTintColor(color:UIColor) { + guard let window = UIApplication.shared.keyWindow else { + return + } + window.tintColor = color +} + +class TintColorViewController: UIViewController { + + @IBOutlet weak var tintColorSeg: UISegmentedControl! + + override func viewDidLoad() { + super.viewDidLoad() + + // Do any additional setup after loading the view. + let userDefaultColor = UserDefaults.standard.integer(forKey: TintColorKey) + self.tintColorSeg.selectedSegmentIndex = userDefaultColor + } + + override func didReceiveMemoryWarning() { + super.didReceiveMemoryWarning() + // Dispose of any resources that can be recreated. + } + + @IBAction func tintColorChanged(_ sender: Any) { + let selectedIndex = self.tintColorSeg.selectedSegmentIndex + UserDefaults.standard.set(selectedIndex, forKey: TintColorKey) + + guard let changedColor = TintColor(rawValue: selectedIndex)?.color else { + return + } + applyTintColor(color: changedColor) + } + + /* + // MARK: - Navigation + + // In a storyboard-based application, you will often want to do a little preparation before navigation + override func prepare(for segue: UIStoryboardSegue, sender: Any?) { + // Get the new view controller using segue.destinationViewController. + // Pass the selected object to the new view controller. + } + */ + +} diff --git "a/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/meetingRooms_plist/meetingRooms/ViewController.swift" "b/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/meetingRooms_plist/meetingRooms/ViewController.swift" new file mode 100644 index 0000000..24bd9b0 --- /dev/null +++ "b/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/meetingRooms_plist/meetingRooms/ViewController.swift" @@ -0,0 +1,25 @@ +// +// ViewController.swift +// meetingRooms +// +// Created by 황도증 on 2017. 10. 30.. +// Copyright © 2017년 황도증. All rights reserved. +// + +import UIKit + +class ViewController: UIViewController { + + override func viewDidLoad() { + super.viewDidLoad() + // Do any additional setup after loading the view, typically from a nib. + } + + override func didReceiveMemoryWarning() { + super.didReceiveMemoryWarning() + // Dispose of any resources that can be recreated. + } + + +} + diff --git "a/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/meetingRooms_plist/meetingRoomsTests/Info.plist" "b/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/meetingRooms_plist/meetingRoomsTests/Info.plist" new file mode 100644 index 0000000..6c40a6c --- /dev/null +++ "b/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/meetingRooms_plist/meetingRoomsTests/Info.plist" @@ -0,0 +1,22 @@ + + + + + CFBundleDevelopmentRegion + $(DEVELOPMENT_LANGUAGE) + CFBundleExecutable + $(EXECUTABLE_NAME) + CFBundleIdentifier + $(PRODUCT_BUNDLE_IDENTIFIER) + CFBundleInfoDictionaryVersion + 6.0 + CFBundleName + $(PRODUCT_NAME) + CFBundlePackageType + BNDL + CFBundleShortVersionString + 1.0 + CFBundleVersion + 1 + + diff --git "a/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/meetingRooms_plist/meetingRoomsTests/meetingRoomsTests.swift" "b/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/meetingRooms_plist/meetingRoomsTests/meetingRoomsTests.swift" new file mode 100644 index 0000000..bfbd8d6 --- /dev/null +++ "b/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/meetingRooms_plist/meetingRoomsTests/meetingRoomsTests.swift" @@ -0,0 +1,36 @@ +// +// meetingRoomsTests.swift +// meetingRoomsTests +// +// Created by 황도증 on 2017. 10. 30.. +// Copyright © 2017년 황도증. All rights reserved. +// + +import XCTest +@testable import meetingRooms + +class meetingRoomsTests: XCTestCase { + + override func setUp() { + super.setUp() + // Put setup code here. This method is called before the invocation of each test method in the class. + } + + override func tearDown() { + // Put teardown code here. This method is called after the invocation of each test method in the class. + super.tearDown() + } + + func testExample() { + // This is an example of a functional test case. + // Use XCTAssert and related functions to verify your tests produce the correct results. + } + + func testPerformanceExample() { + // This is an example of a performance test case. + self.measure { + // Put the code you want to measure the time of here. + } + } + +} diff --git "a/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/meetingRooms_plist/meetingRoomsUITests/Info.plist" "b/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/meetingRooms_plist/meetingRoomsUITests/Info.plist" new file mode 100644 index 0000000..6c40a6c --- /dev/null +++ "b/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/meetingRooms_plist/meetingRoomsUITests/Info.plist" @@ -0,0 +1,22 @@ + + + + + CFBundleDevelopmentRegion + $(DEVELOPMENT_LANGUAGE) + CFBundleExecutable + $(EXECUTABLE_NAME) + CFBundleIdentifier + $(PRODUCT_BUNDLE_IDENTIFIER) + CFBundleInfoDictionaryVersion + 6.0 + CFBundleName + $(PRODUCT_NAME) + CFBundlePackageType + BNDL + CFBundleShortVersionString + 1.0 + CFBundleVersion + 1 + + diff --git "a/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/meetingRooms_plist/meetingRoomsUITests/meetingRoomsUITests.swift" "b/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/meetingRooms_plist/meetingRoomsUITests/meetingRoomsUITests.swift" new file mode 100644 index 0000000..4873bfa --- /dev/null +++ "b/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/meetingRooms_plist/meetingRoomsUITests/meetingRoomsUITests.swift" @@ -0,0 +1,36 @@ +// +// meetingRoomsUITests.swift +// meetingRoomsUITests +// +// Created by 황도증 on 2017. 10. 30.. +// Copyright © 2017년 황도증. All rights reserved. +// + +import XCTest + +class meetingRoomsUITests: XCTestCase { + + override func setUp() { + super.setUp() + + // Put setup code here. This method is called before the invocation of each test method in the class. + + // In UI tests it is usually best to stop immediately when a failure occurs. + continueAfterFailure = false + // UI tests must launch the application that they test. Doing this in setup will make sure it happens for each test method. + XCUIApplication().launch() + + // In UI tests it’s important to set the initial state - such as interface orientation - required for your tests before they run. The setUp method is a good place to do this. + } + + override func tearDown() { + // Put teardown code here. This method is called after the invocation of each test method in the class. + super.tearDown() + } + + func testExample() { + // Use recording to get started writing UI tests. + // Use XCTAssert and related functions to verify your tests produce the correct results. + } + +} diff --git "a/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/meetingRooms_tap&tool/meetingRooms.xcodeproj/project.pbxproj" "b/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/meetingRooms_tap&tool/meetingRooms.xcodeproj/project.pbxproj" new file mode 100644 index 0000000..d0ea954 --- /dev/null +++ "b/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/meetingRooms_tap&tool/meetingRooms.xcodeproj/project.pbxproj" @@ -0,0 +1,573 @@ +// !$*UTF8*$! +{ + archiveVersion = 1; + classes = { + }; + objectVersion = 48; + objects = { + +/* Begin PBXBuildFile section */ + AE99575B1FA704AF00397D38 /* AppDelegate.swift in Sources */ = {isa = PBXBuildFile; fileRef = AE99575A1FA704AF00397D38 /* AppDelegate.swift */; }; + AE99575D1FA704AF00397D38 /* ViewController.swift in Sources */ = {isa = PBXBuildFile; fileRef = AE99575C1FA704AF00397D38 /* ViewController.swift */; }; + AE9957601FA704AF00397D38 /* Main.storyboard in Resources */ = {isa = PBXBuildFile; fileRef = AE99575E1FA704AF00397D38 /* Main.storyboard */; }; + AE9957621FA704AF00397D38 /* Assets.xcassets in Resources */ = {isa = PBXBuildFile; fileRef = AE9957611FA704AF00397D38 /* Assets.xcassets */; }; + AE9957651FA704AF00397D38 /* LaunchScreen.storyboard in Resources */ = {isa = PBXBuildFile; fileRef = AE9957631FA704AF00397D38 /* LaunchScreen.storyboard */; }; + AE9957701FA704AF00397D38 /* meetingRoomsTests.swift in Sources */ = {isa = PBXBuildFile; fileRef = AE99576F1FA704AF00397D38 /* meetingRoomsTests.swift */; }; + AE99577B1FA704B000397D38 /* meetingRoomsUITests.swift in Sources */ = {isa = PBXBuildFile; fileRef = AE99577A1FA704B000397D38 /* meetingRoomsUITests.swift */; }; + AE9957891FA7054800397D38 /* MeetingRoomListViewController.swift in Sources */ = {isa = PBXBuildFile; fileRef = AE9957881FA7054800397D38 /* MeetingRoomListViewController.swift */; }; + AEB3189D1FB4641000AEB094 /* DataCenter.swift in Sources */ = {isa = PBXBuildFile; fileRef = AEB3189C1FB4641000AEB094 /* DataCenter.swift */; }; + AEB3189F1FB4684600AEB094 /* BranchListViewController.swift in Sources */ = {isa = PBXBuildFile; fileRef = AEB3189E1FB4684600AEB094 /* BranchListViewController.swift */; }; + AEB318A11FB4685800AEB094 /* ServiceListViewController.swift in Sources */ = {isa = PBXBuildFile; fileRef = AEB318A01FB4685800AEB094 /* ServiceListViewController.swift */; }; +/* End PBXBuildFile section */ + +/* Begin PBXContainerItemProxy section */ + AE99576C1FA704AF00397D38 /* PBXContainerItemProxy */ = { + isa = PBXContainerItemProxy; + containerPortal = AE99574F1FA704AF00397D38 /* Project object */; + proxyType = 1; + remoteGlobalIDString = AE9957561FA704AF00397D38; + remoteInfo = meetingRooms; + }; + AE9957771FA704B000397D38 /* PBXContainerItemProxy */ = { + isa = PBXContainerItemProxy; + containerPortal = AE99574F1FA704AF00397D38 /* Project object */; + proxyType = 1; + remoteGlobalIDString = AE9957561FA704AF00397D38; + remoteInfo = meetingRooms; + }; +/* End PBXContainerItemProxy section */ + +/* Begin PBXFileReference section */ + AE9957571FA704AF00397D38 /* meetingRooms.app */ = {isa = PBXFileReference; explicitFileType = wrapper.application; includeInIndex = 0; path = meetingRooms.app; sourceTree = BUILT_PRODUCTS_DIR; }; + AE99575A1FA704AF00397D38 /* AppDelegate.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = AppDelegate.swift; sourceTree = ""; }; + AE99575C1FA704AF00397D38 /* ViewController.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = ViewController.swift; sourceTree = ""; }; + AE99575F1FA704AF00397D38 /* Base */ = {isa = PBXFileReference; lastKnownFileType = file.storyboard; name = Base; path = Base.lproj/Main.storyboard; sourceTree = ""; }; + AE9957611FA704AF00397D38 /* Assets.xcassets */ = {isa = PBXFileReference; lastKnownFileType = folder.assetcatalog; path = Assets.xcassets; sourceTree = ""; }; + AE9957641FA704AF00397D38 /* Base */ = {isa = PBXFileReference; lastKnownFileType = file.storyboard; name = Base; path = Base.lproj/LaunchScreen.storyboard; sourceTree = ""; }; + AE9957661FA704AF00397D38 /* Info.plist */ = {isa = PBXFileReference; lastKnownFileType = text.plist.xml; path = Info.plist; sourceTree = ""; }; + AE99576B1FA704AF00397D38 /* meetingRoomsTests.xctest */ = {isa = PBXFileReference; explicitFileType = wrapper.cfbundle; includeInIndex = 0; path = meetingRoomsTests.xctest; sourceTree = BUILT_PRODUCTS_DIR; }; + AE99576F1FA704AF00397D38 /* meetingRoomsTests.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = meetingRoomsTests.swift; sourceTree = ""; }; + AE9957711FA704AF00397D38 /* Info.plist */ = {isa = PBXFileReference; lastKnownFileType = text.plist.xml; path = Info.plist; sourceTree = ""; }; + AE9957761FA704B000397D38 /* meetingRoomsUITests.xctest */ = {isa = PBXFileReference; explicitFileType = wrapper.cfbundle; includeInIndex = 0; path = meetingRoomsUITests.xctest; sourceTree = BUILT_PRODUCTS_DIR; }; + AE99577A1FA704B000397D38 /* meetingRoomsUITests.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = meetingRoomsUITests.swift; sourceTree = ""; }; + AE99577C1FA704B000397D38 /* Info.plist */ = {isa = PBXFileReference; lastKnownFileType = text.plist.xml; path = Info.plist; sourceTree = ""; }; + AE9957881FA7054800397D38 /* MeetingRoomListViewController.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = MeetingRoomListViewController.swift; sourceTree = ""; }; + AEB3189C1FB4641000AEB094 /* DataCenter.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = DataCenter.swift; sourceTree = ""; }; + AEB3189E1FB4684600AEB094 /* BranchListViewController.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = BranchListViewController.swift; sourceTree = ""; }; + AEB318A01FB4685800AEB094 /* ServiceListViewController.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = ServiceListViewController.swift; sourceTree = ""; }; +/* End PBXFileReference section */ + +/* Begin PBXFrameworksBuildPhase section */ + AE9957541FA704AF00397D38 /* Frameworks */ = { + isa = PBXFrameworksBuildPhase; + buildActionMask = 2147483647; + files = ( + ); + runOnlyForDeploymentPostprocessing = 0; + }; + AE9957681FA704AF00397D38 /* Frameworks */ = { + isa = PBXFrameworksBuildPhase; + buildActionMask = 2147483647; + files = ( + ); + runOnlyForDeploymentPostprocessing = 0; + }; + AE9957731FA704B000397D38 /* Frameworks */ = { + isa = PBXFrameworksBuildPhase; + buildActionMask = 2147483647; + files = ( + ); + runOnlyForDeploymentPostprocessing = 0; + }; +/* End PBXFrameworksBuildPhase section */ + +/* Begin PBXGroup section */ + AE99574E1FA704AF00397D38 = { + isa = PBXGroup; + children = ( + AE9957591FA704AF00397D38 /* meetingRooms */, + AE99576E1FA704AF00397D38 /* meetingRoomsTests */, + AE9957791FA704B000397D38 /* meetingRoomsUITests */, + AE9957581FA704AF00397D38 /* Products */, + ); + sourceTree = ""; + }; + AE9957581FA704AF00397D38 /* Products */ = { + isa = PBXGroup; + children = ( + AE9957571FA704AF00397D38 /* meetingRooms.app */, + AE99576B1FA704AF00397D38 /* meetingRoomsTests.xctest */, + AE9957761FA704B000397D38 /* meetingRoomsUITests.xctest */, + ); + name = Products; + sourceTree = ""; + }; + AE9957591FA704AF00397D38 /* meetingRooms */ = { + isa = PBXGroup; + children = ( + AE99575A1FA704AF00397D38 /* AppDelegate.swift */, + AE99575C1FA704AF00397D38 /* ViewController.swift */, + AE99575E1FA704AF00397D38 /* Main.storyboard */, + AEB3189C1FB4641000AEB094 /* DataCenter.swift */, + AEB3189E1FB4684600AEB094 /* BranchListViewController.swift */, + AEB318A01FB4685800AEB094 /* ServiceListViewController.swift */, + AE9957881FA7054800397D38 /* MeetingRoomListViewController.swift */, + AE9957611FA704AF00397D38 /* Assets.xcassets */, + AE9957631FA704AF00397D38 /* LaunchScreen.storyboard */, + AE9957661FA704AF00397D38 /* Info.plist */, + ); + path = meetingRooms; + sourceTree = ""; + }; + AE99576E1FA704AF00397D38 /* meetingRoomsTests */ = { + isa = PBXGroup; + children = ( + AE99576F1FA704AF00397D38 /* meetingRoomsTests.swift */, + AE9957711FA704AF00397D38 /* Info.plist */, + ); + path = meetingRoomsTests; + sourceTree = ""; + }; + AE9957791FA704B000397D38 /* meetingRoomsUITests */ = { + isa = PBXGroup; + children = ( + AE99577A1FA704B000397D38 /* meetingRoomsUITests.swift */, + AE99577C1FA704B000397D38 /* Info.plist */, + ); + path = meetingRoomsUITests; + sourceTree = ""; + }; +/* End PBXGroup section */ + +/* Begin PBXNativeTarget section */ + AE9957561FA704AF00397D38 /* meetingRooms */ = { + isa = PBXNativeTarget; + buildConfigurationList = AE99577F1FA704B000397D38 /* Build configuration list for PBXNativeTarget "meetingRooms" */; + buildPhases = ( + AE9957531FA704AF00397D38 /* Sources */, + AE9957541FA704AF00397D38 /* Frameworks */, + AE9957551FA704AF00397D38 /* Resources */, + ); + buildRules = ( + ); + dependencies = ( + ); + name = meetingRooms; + productName = meetingRooms; + productReference = AE9957571FA704AF00397D38 /* meetingRooms.app */; + productType = "com.apple.product-type.application"; + }; + AE99576A1FA704AF00397D38 /* meetingRoomsTests */ = { + isa = PBXNativeTarget; + buildConfigurationList = AE9957821FA704B000397D38 /* Build configuration list for PBXNativeTarget "meetingRoomsTests" */; + buildPhases = ( + AE9957671FA704AF00397D38 /* Sources */, + AE9957681FA704AF00397D38 /* Frameworks */, + AE9957691FA704AF00397D38 /* Resources */, + ); + buildRules = ( + ); + dependencies = ( + AE99576D1FA704AF00397D38 /* PBXTargetDependency */, + ); + name = meetingRoomsTests; + productName = meetingRoomsTests; + productReference = AE99576B1FA704AF00397D38 /* meetingRoomsTests.xctest */; + productType = "com.apple.product-type.bundle.unit-test"; + }; + AE9957751FA704B000397D38 /* meetingRoomsUITests */ = { + isa = PBXNativeTarget; + buildConfigurationList = AE9957851FA704B000397D38 /* Build configuration list for PBXNativeTarget "meetingRoomsUITests" */; + buildPhases = ( + AE9957721FA704B000397D38 /* Sources */, + AE9957731FA704B000397D38 /* Frameworks */, + AE9957741FA704B000397D38 /* Resources */, + ); + buildRules = ( + ); + dependencies = ( + AE9957781FA704B000397D38 /* PBXTargetDependency */, + ); + name = meetingRoomsUITests; + productName = meetingRoomsUITests; + productReference = AE9957761FA704B000397D38 /* meetingRoomsUITests.xctest */; + productType = "com.apple.product-type.bundle.ui-testing"; + }; +/* End PBXNativeTarget section */ + +/* Begin PBXProject section */ + AE99574F1FA704AF00397D38 /* Project object */ = { + isa = PBXProject; + attributes = { + LastSwiftUpdateCheck = 0900; + LastUpgradeCheck = 0900; + ORGANIZATIONNAME = "황도증"; + TargetAttributes = { + AE9957561FA704AF00397D38 = { + CreatedOnToolsVersion = 9.0.1; + ProvisioningStyle = Automatic; + }; + AE99576A1FA704AF00397D38 = { + CreatedOnToolsVersion = 9.0.1; + ProvisioningStyle = Automatic; + TestTargetID = AE9957561FA704AF00397D38; + }; + AE9957751FA704B000397D38 = { + CreatedOnToolsVersion = 9.0.1; + ProvisioningStyle = Automatic; + TestTargetID = AE9957561FA704AF00397D38; + }; + }; + }; + buildConfigurationList = AE9957521FA704AF00397D38 /* Build configuration list for PBXProject "meetingRooms" */; + compatibilityVersion = "Xcode 8.0"; + developmentRegion = en; + hasScannedForEncodings = 0; + knownRegions = ( + en, + Base, + ); + mainGroup = AE99574E1FA704AF00397D38; + productRefGroup = AE9957581FA704AF00397D38 /* Products */; + projectDirPath = ""; + projectRoot = ""; + targets = ( + AE9957561FA704AF00397D38 /* meetingRooms */, + AE99576A1FA704AF00397D38 /* meetingRoomsTests */, + AE9957751FA704B000397D38 /* meetingRoomsUITests */, + ); + }; +/* End PBXProject section */ + +/* Begin PBXResourcesBuildPhase section */ + AE9957551FA704AF00397D38 /* Resources */ = { + isa = PBXResourcesBuildPhase; + buildActionMask = 2147483647; + files = ( + AE9957651FA704AF00397D38 /* LaunchScreen.storyboard in Resources */, + AE9957621FA704AF00397D38 /* Assets.xcassets in Resources */, + AE9957601FA704AF00397D38 /* Main.storyboard in Resources */, + ); + runOnlyForDeploymentPostprocessing = 0; + }; + AE9957691FA704AF00397D38 /* Resources */ = { + isa = PBXResourcesBuildPhase; + buildActionMask = 2147483647; + files = ( + ); + runOnlyForDeploymentPostprocessing = 0; + }; + AE9957741FA704B000397D38 /* Resources */ = { + isa = PBXResourcesBuildPhase; + buildActionMask = 2147483647; + files = ( + ); + runOnlyForDeploymentPostprocessing = 0; + }; +/* End PBXResourcesBuildPhase section */ + +/* Begin PBXSourcesBuildPhase section */ + AE9957531FA704AF00397D38 /* Sources */ = { + isa = PBXSourcesBuildPhase; + buildActionMask = 2147483647; + files = ( + AE99575D1FA704AF00397D38 /* ViewController.swift in Sources */, + AE99575B1FA704AF00397D38 /* AppDelegate.swift in Sources */, + AEB3189D1FB4641000AEB094 /* DataCenter.swift in Sources */, + AEB3189F1FB4684600AEB094 /* BranchListViewController.swift in Sources */, + AEB318A11FB4685800AEB094 /* ServiceListViewController.swift in Sources */, + AE9957891FA7054800397D38 /* MeetingRoomListViewController.swift in Sources */, + ); + runOnlyForDeploymentPostprocessing = 0; + }; + AE9957671FA704AF00397D38 /* Sources */ = { + isa = PBXSourcesBuildPhase; + buildActionMask = 2147483647; + files = ( + AE9957701FA704AF00397D38 /* meetingRoomsTests.swift in Sources */, + ); + runOnlyForDeploymentPostprocessing = 0; + }; + AE9957721FA704B000397D38 /* Sources */ = { + isa = PBXSourcesBuildPhase; + buildActionMask = 2147483647; + files = ( + AE99577B1FA704B000397D38 /* meetingRoomsUITests.swift in Sources */, + ); + runOnlyForDeploymentPostprocessing = 0; + }; +/* End PBXSourcesBuildPhase section */ + +/* Begin PBXTargetDependency section */ + AE99576D1FA704AF00397D38 /* PBXTargetDependency */ = { + isa = PBXTargetDependency; + target = AE9957561FA704AF00397D38 /* meetingRooms */; + targetProxy = AE99576C1FA704AF00397D38 /* PBXContainerItemProxy */; + }; + AE9957781FA704B000397D38 /* PBXTargetDependency */ = { + isa = PBXTargetDependency; + target = AE9957561FA704AF00397D38 /* meetingRooms */; + targetProxy = AE9957771FA704B000397D38 /* PBXContainerItemProxy */; + }; +/* End PBXTargetDependency section */ + +/* Begin PBXVariantGroup section */ + AE99575E1FA704AF00397D38 /* Main.storyboard */ = { + isa = PBXVariantGroup; + children = ( + AE99575F1FA704AF00397D38 /* Base */, + ); + name = Main.storyboard; + sourceTree = ""; + }; + AE9957631FA704AF00397D38 /* LaunchScreen.storyboard */ = { + isa = PBXVariantGroup; + children = ( + AE9957641FA704AF00397D38 /* Base */, + ); + name = LaunchScreen.storyboard; + sourceTree = ""; + }; +/* End PBXVariantGroup section */ + +/* Begin XCBuildConfiguration section */ + AE99577D1FA704B000397D38 /* Debug */ = { + isa = XCBuildConfiguration; + buildSettings = { + ALWAYS_SEARCH_USER_PATHS = NO; + CLANG_ANALYZER_NONNULL = YES; + CLANG_ANALYZER_NUMBER_OBJECT_CONVERSION = YES_AGGRESSIVE; + CLANG_CXX_LANGUAGE_STANDARD = "gnu++14"; + CLANG_CXX_LIBRARY = "libc++"; + CLANG_ENABLE_MODULES = YES; + CLANG_ENABLE_OBJC_ARC = YES; + CLANG_WARN_BLOCK_CAPTURE_AUTORELEASING = YES; + CLANG_WARN_BOOL_CONVERSION = YES; + CLANG_WARN_COMMA = YES; + CLANG_WARN_CONSTANT_CONVERSION = YES; + CLANG_WARN_DIRECT_OBJC_ISA_USAGE = YES_ERROR; + CLANG_WARN_DOCUMENTATION_COMMENTS = YES; + CLANG_WARN_EMPTY_BODY = YES; + CLANG_WARN_ENUM_CONVERSION = YES; + CLANG_WARN_INFINITE_RECURSION = YES; + CLANG_WARN_INT_CONVERSION = YES; + CLANG_WARN_NON_LITERAL_NULL_CONVERSION = YES; + CLANG_WARN_OBJC_LITERAL_CONVERSION = YES; + CLANG_WARN_OBJC_ROOT_CLASS = YES_ERROR; + CLANG_WARN_RANGE_LOOP_ANALYSIS = YES; + CLANG_WARN_STRICT_PROTOTYPES = YES; + CLANG_WARN_SUSPICIOUS_MOVE = YES; + CLANG_WARN_UNGUARDED_AVAILABILITY = YES_AGGRESSIVE; + CLANG_WARN_UNREACHABLE_CODE = YES; + CLANG_WARN__DUPLICATE_METHOD_MATCH = YES; + CODE_SIGN_IDENTITY = "iPhone Developer"; + COPY_PHASE_STRIP = NO; + DEBUG_INFORMATION_FORMAT = dwarf; + ENABLE_STRICT_OBJC_MSGSEND = YES; + ENABLE_TESTABILITY = YES; + GCC_C_LANGUAGE_STANDARD = gnu11; + GCC_DYNAMIC_NO_PIC = NO; + GCC_NO_COMMON_BLOCKS = YES; + GCC_OPTIMIZATION_LEVEL = 0; + GCC_PREPROCESSOR_DEFINITIONS = ( + "DEBUG=1", + "$(inherited)", + ); + GCC_WARN_64_TO_32_BIT_CONVERSION = YES; + GCC_WARN_ABOUT_RETURN_TYPE = YES_ERROR; + GCC_WARN_UNDECLARED_SELECTOR = YES; + GCC_WARN_UNINITIALIZED_AUTOS = YES_AGGRESSIVE; + GCC_WARN_UNUSED_FUNCTION = YES; + GCC_WARN_UNUSED_VARIABLE = YES; + IPHONEOS_DEPLOYMENT_TARGET = 11.0; + MTL_ENABLE_DEBUG_INFO = YES; + ONLY_ACTIVE_ARCH = YES; + SDKROOT = iphoneos; + SWIFT_ACTIVE_COMPILATION_CONDITIONS = DEBUG; + SWIFT_OPTIMIZATION_LEVEL = "-Onone"; + }; + name = Debug; + }; + AE99577E1FA704B000397D38 /* Release */ = { + isa = XCBuildConfiguration; + buildSettings = { + ALWAYS_SEARCH_USER_PATHS = NO; + CLANG_ANALYZER_NONNULL = YES; + CLANG_ANALYZER_NUMBER_OBJECT_CONVERSION = YES_AGGRESSIVE; + CLANG_CXX_LANGUAGE_STANDARD = "gnu++14"; + CLANG_CXX_LIBRARY = "libc++"; + CLANG_ENABLE_MODULES = YES; + CLANG_ENABLE_OBJC_ARC = YES; + CLANG_WARN_BLOCK_CAPTURE_AUTORELEASING = YES; + CLANG_WARN_BOOL_CONVERSION = YES; + CLANG_WARN_COMMA = YES; + CLANG_WARN_CONSTANT_CONVERSION = YES; + CLANG_WARN_DIRECT_OBJC_ISA_USAGE = YES_ERROR; + CLANG_WARN_DOCUMENTATION_COMMENTS = YES; + CLANG_WARN_EMPTY_BODY = YES; + CLANG_WARN_ENUM_CONVERSION = YES; + CLANG_WARN_INFINITE_RECURSION = YES; + CLANG_WARN_INT_CONVERSION = YES; + CLANG_WARN_NON_LITERAL_NULL_CONVERSION = YES; + CLANG_WARN_OBJC_LITERAL_CONVERSION = YES; + CLANG_WARN_OBJC_ROOT_CLASS = YES_ERROR; + CLANG_WARN_RANGE_LOOP_ANALYSIS = YES; + CLANG_WARN_STRICT_PROTOTYPES = YES; + CLANG_WARN_SUSPICIOUS_MOVE = YES; + CLANG_WARN_UNGUARDED_AVAILABILITY = YES_AGGRESSIVE; + CLANG_WARN_UNREACHABLE_CODE = YES; + CLANG_WARN__DUPLICATE_METHOD_MATCH = YES; + CODE_SIGN_IDENTITY = "iPhone Developer"; + COPY_PHASE_STRIP = NO; + DEBUG_INFORMATION_FORMAT = "dwarf-with-dsym"; + ENABLE_NS_ASSERTIONS = NO; + ENABLE_STRICT_OBJC_MSGSEND = YES; + GCC_C_LANGUAGE_STANDARD = gnu11; + GCC_NO_COMMON_BLOCKS = YES; + GCC_WARN_64_TO_32_BIT_CONVERSION = YES; + GCC_WARN_ABOUT_RETURN_TYPE = YES_ERROR; + GCC_WARN_UNDECLARED_SELECTOR = YES; + GCC_WARN_UNINITIALIZED_AUTOS = YES_AGGRESSIVE; + GCC_WARN_UNUSED_FUNCTION = YES; + GCC_WARN_UNUSED_VARIABLE = YES; + IPHONEOS_DEPLOYMENT_TARGET = 11.0; + MTL_ENABLE_DEBUG_INFO = NO; + SDKROOT = iphoneos; + SWIFT_OPTIMIZATION_LEVEL = "-Owholemodule"; + VALIDATE_PRODUCT = YES; + }; + name = Release; + }; + AE9957801FA704B000397D38 /* Debug */ = { + isa = XCBuildConfiguration; + buildSettings = { + ASSETCATALOG_COMPILER_APPICON_NAME = AppIcon; + CODE_SIGN_STYLE = Automatic; + INFOPLIST_FILE = meetingRooms/Info.plist; + LD_RUNPATH_SEARCH_PATHS = "$(inherited) @executable_path/Frameworks"; + PRODUCT_BUNDLE_IDENTIFIER = "--------.meetingRooms"; + PRODUCT_NAME = "$(TARGET_NAME)"; + SWIFT_VERSION = 4.0; + TARGETED_DEVICE_FAMILY = "1,2"; + }; + name = Debug; + }; + AE9957811FA704B000397D38 /* Release */ = { + isa = XCBuildConfiguration; + buildSettings = { + ASSETCATALOG_COMPILER_APPICON_NAME = AppIcon; + CODE_SIGN_STYLE = Automatic; + INFOPLIST_FILE = meetingRooms/Info.plist; + LD_RUNPATH_SEARCH_PATHS = "$(inherited) @executable_path/Frameworks"; + PRODUCT_BUNDLE_IDENTIFIER = "--------.meetingRooms"; + PRODUCT_NAME = "$(TARGET_NAME)"; + SWIFT_VERSION = 4.0; + TARGETED_DEVICE_FAMILY = "1,2"; + }; + name = Release; + }; + AE9957831FA704B000397D38 /* Debug */ = { + isa = XCBuildConfiguration; + buildSettings = { + ALWAYS_EMBED_SWIFT_STANDARD_LIBRARIES = YES; + BUNDLE_LOADER = "$(TEST_HOST)"; + CODE_SIGN_STYLE = Automatic; + INFOPLIST_FILE = meetingRoomsTests/Info.plist; + LD_RUNPATH_SEARCH_PATHS = "$(inherited) @executable_path/Frameworks @loader_path/Frameworks"; + PRODUCT_BUNDLE_IDENTIFIER = "--------.meetingRoomsTests"; + PRODUCT_NAME = "$(TARGET_NAME)"; + SWIFT_VERSION = 4.0; + TARGETED_DEVICE_FAMILY = "1,2"; + TEST_HOST = "$(BUILT_PRODUCTS_DIR)/meetingRooms.app/meetingRooms"; + }; + name = Debug; + }; + AE9957841FA704B000397D38 /* Release */ = { + isa = XCBuildConfiguration; + buildSettings = { + ALWAYS_EMBED_SWIFT_STANDARD_LIBRARIES = YES; + BUNDLE_LOADER = "$(TEST_HOST)"; + CODE_SIGN_STYLE = Automatic; + INFOPLIST_FILE = meetingRoomsTests/Info.plist; + LD_RUNPATH_SEARCH_PATHS = "$(inherited) @executable_path/Frameworks @loader_path/Frameworks"; + PRODUCT_BUNDLE_IDENTIFIER = "--------.meetingRoomsTests"; + PRODUCT_NAME = "$(TARGET_NAME)"; + SWIFT_VERSION = 4.0; + TARGETED_DEVICE_FAMILY = "1,2"; + TEST_HOST = "$(BUILT_PRODUCTS_DIR)/meetingRooms.app/meetingRooms"; + }; + name = Release; + }; + AE9957861FA704B000397D38 /* Debug */ = { + isa = XCBuildConfiguration; + buildSettings = { + ALWAYS_EMBED_SWIFT_STANDARD_LIBRARIES = YES; + CODE_SIGN_STYLE = Automatic; + INFOPLIST_FILE = meetingRoomsUITests/Info.plist; + LD_RUNPATH_SEARCH_PATHS = "$(inherited) @executable_path/Frameworks @loader_path/Frameworks"; + PRODUCT_BUNDLE_IDENTIFIER = "--------.meetingRoomsUITests"; + PRODUCT_NAME = "$(TARGET_NAME)"; + SWIFT_VERSION = 4.0; + TARGETED_DEVICE_FAMILY = "1,2"; + TEST_TARGET_NAME = meetingRooms; + }; + name = Debug; + }; + AE9957871FA704B000397D38 /* Release */ = { + isa = XCBuildConfiguration; + buildSettings = { + ALWAYS_EMBED_SWIFT_STANDARD_LIBRARIES = YES; + CODE_SIGN_STYLE = Automatic; + INFOPLIST_FILE = meetingRoomsUITests/Info.plist; + LD_RUNPATH_SEARCH_PATHS = "$(inherited) @executable_path/Frameworks @loader_path/Frameworks"; + PRODUCT_BUNDLE_IDENTIFIER = "--------.meetingRoomsUITests"; + PRODUCT_NAME = "$(TARGET_NAME)"; + SWIFT_VERSION = 4.0; + TARGETED_DEVICE_FAMILY = "1,2"; + TEST_TARGET_NAME = meetingRooms; + }; + name = Release; + }; +/* End XCBuildConfiguration section */ + +/* Begin XCConfigurationList section */ + AE9957521FA704AF00397D38 /* Build configuration list for PBXProject "meetingRooms" */ = { + isa = XCConfigurationList; + buildConfigurations = ( + AE99577D1FA704B000397D38 /* Debug */, + AE99577E1FA704B000397D38 /* Release */, + ); + defaultConfigurationIsVisible = 0; + defaultConfigurationName = Release; + }; + AE99577F1FA704B000397D38 /* Build configuration list for PBXNativeTarget "meetingRooms" */ = { + isa = XCConfigurationList; + buildConfigurations = ( + AE9957801FA704B000397D38 /* Debug */, + AE9957811FA704B000397D38 /* Release */, + ); + defaultConfigurationIsVisible = 0; + defaultConfigurationName = Release; + }; + AE9957821FA704B000397D38 /* Build configuration list for PBXNativeTarget "meetingRoomsTests" */ = { + isa = XCConfigurationList; + buildConfigurations = ( + AE9957831FA704B000397D38 /* Debug */, + AE9957841FA704B000397D38 /* Release */, + ); + defaultConfigurationIsVisible = 0; + defaultConfigurationName = Release; + }; + AE9957851FA704B000397D38 /* Build configuration list for PBXNativeTarget "meetingRoomsUITests" */ = { + isa = XCConfigurationList; + buildConfigurations = ( + AE9957861FA704B000397D38 /* Debug */, + AE9957871FA704B000397D38 /* Release */, + ); + defaultConfigurationIsVisible = 0; + defaultConfigurationName = Release; + }; +/* End XCConfigurationList section */ + }; + rootObject = AE99574F1FA704AF00397D38 /* Project object */; +} diff --git "a/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/meetingRooms_tap&tool/meetingRooms.xcodeproj/project.xcworkspace/contents.xcworkspacedata" "b/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/meetingRooms_tap&tool/meetingRooms.xcodeproj/project.xcworkspace/contents.xcworkspacedata" new file mode 100644 index 0000000..8491799 --- /dev/null +++ "b/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/meetingRooms_tap&tool/meetingRooms.xcodeproj/project.xcworkspace/contents.xcworkspacedata" @@ -0,0 +1,7 @@ + + + + + diff --git "a/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/meetingRooms_tap&tool/meetingRooms/AppDelegate.swift" "b/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/meetingRooms_tap&tool/meetingRooms/AppDelegate.swift" new file mode 100644 index 0000000..fc60321 --- /dev/null +++ "b/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/meetingRooms_tap&tool/meetingRooms/AppDelegate.swift" @@ -0,0 +1,46 @@ +// +// AppDelegate.swift +// meetingRooms +// +// Created by 황도증 on 2017. 10. 30.. +// Copyright © 2017년 황도증. All rights reserved. +// + +import UIKit + +@UIApplicationMain +class AppDelegate: UIResponder, UIApplicationDelegate { + + var window: UIWindow? + + + func application(_ application: UIApplication, didFinishLaunchingWithOptions launchOptions: [UIApplicationLaunchOptionsKey: Any]?) -> Bool { + // Override point for customization after application launch. + return true + } + + func applicationWillResignActive(_ application: UIApplication) { + // Sent when the application is about to move from active to inactive state. This can occur for certain types of temporary interruptions (such as an incoming phone call or SMS message) or when the user quits the application and it begins the transition to the background state. + // Use this method to pause ongoing tasks, disable timers, and invalidate graphics rendering callbacks. Games should use this method to pause the game. + } + + func applicationDidEnterBackground(_ application: UIApplication) { + // Use this method to release shared resources, save user data, invalidate timers, and store enough application state information to restore your application to its current state in case it is terminated later. + // If your application supports background execution, this method is called instead of applicationWillTerminate: when the user quits. + } + + func applicationWillEnterForeground(_ application: UIApplication) { + // Called as part of the transition from the background to the active state; here you can undo many of the changes made on entering the background. + } + + func applicationDidBecomeActive(_ application: UIApplication) { + // Restart any tasks that were paused (or not yet started) while the application was inactive. If the application was previously in the background, optionally refresh the user interface. + } + + func applicationWillTerminate(_ application: UIApplication) { + // Called when the application is about to terminate. Save data if appropriate. See also applicationDidEnterBackground:. + } + + +} + diff --git "a/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/meetingRooms_tap&tool/meetingRooms/Assets.xcassets/AppIcon.appiconset/Contents.json" "b/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/meetingRooms_tap&tool/meetingRooms/Assets.xcassets/AppIcon.appiconset/Contents.json" new file mode 100644 index 0000000..d8db8d6 --- /dev/null +++ "b/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/meetingRooms_tap&tool/meetingRooms/Assets.xcassets/AppIcon.appiconset/Contents.json" @@ -0,0 +1,98 @@ +{ + "images" : [ + { + "idiom" : "iphone", + "size" : "20x20", + "scale" : "2x" + }, + { + "idiom" : "iphone", + "size" : "20x20", + "scale" : "3x" + }, + { + "idiom" : "iphone", + "size" : "29x29", + "scale" : "2x" + }, + { + "idiom" : "iphone", + "size" : "29x29", + "scale" : "3x" + }, + { + "idiom" : "iphone", + "size" : "40x40", + "scale" : "2x" + }, + { + "idiom" : "iphone", + "size" : "40x40", + "scale" : "3x" + }, + { + "idiom" : "iphone", + "size" : "60x60", + "scale" : "2x" + }, + { + "idiom" : "iphone", + "size" : "60x60", + "scale" : "3x" + }, + { + "idiom" : "ipad", + "size" : "20x20", + "scale" : "1x" + }, + { + "idiom" : "ipad", + "size" : "20x20", + "scale" : "2x" + }, + { + "idiom" : "ipad", + "size" : "29x29", + "scale" : "1x" + }, + { + "idiom" : "ipad", + "size" : "29x29", + "scale" : "2x" + }, + { + "idiom" : "ipad", + "size" : "40x40", + "scale" : "1x" + }, + { + "idiom" : "ipad", + "size" : "40x40", + "scale" : "2x" + }, + { + "idiom" : "ipad", + "size" : "76x76", + "scale" : "1x" + }, + { + "idiom" : "ipad", + "size" : "76x76", + "scale" : "2x" + }, + { + "idiom" : "ipad", + "size" : "83.5x83.5", + "scale" : "2x" + }, + { + "idiom" : "ios-marketing", + "size" : "1024x1024", + "scale" : "1x" + } + ], + "info" : { + "version" : 1, + "author" : "xcode" + } +} \ No newline at end of file diff --git "a/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/meetingRooms_tap&tool/meetingRooms/Base.lproj/LaunchScreen.storyboard" "b/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/meetingRooms_tap&tool/meetingRooms/Base.lproj/LaunchScreen.storyboard" new file mode 100644 index 0000000..f83f6fd --- /dev/null +++ "b/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/meetingRooms_tap&tool/meetingRooms/Base.lproj/LaunchScreen.storyboard" @@ -0,0 +1,25 @@ + + + + + + + + + + + + + + + + + + + + + + + + + diff --git "a/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/meetingRooms_tap&tool/meetingRooms/Base.lproj/Main.storyboard" "b/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/meetingRooms_tap&tool/meetingRooms/Base.lproj/Main.storyboard" new file mode 100644 index 0000000..b215d80 --- /dev/null +++ "b/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/meetingRooms_tap&tool/meetingRooms/Base.lproj/Main.storyboard" @@ -0,0 +1,253 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + diff --git "a/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/meetingRooms_tap&tool/meetingRooms/BranchListViewController.swift" "b/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/meetingRooms_tap&tool/meetingRooms/BranchListViewController.swift" new file mode 100644 index 0000000..a05adab --- /dev/null +++ "b/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/meetingRooms_tap&tool/meetingRooms/BranchListViewController.swift" @@ -0,0 +1,107 @@ +// +// BranchListViewController.swift +// meetingRooms +// +// Created by 황도증 on 2017. 11. 9.. +// Copyright © 2017년 황도증. All rights reserved. +// + +import UIKit + +class BranchListViewController: UITableViewController { + + override func viewDidLoad() { + super.viewDidLoad() + + // Uncomment the following line to preserve selection between presentations + // self.clearsSelectionOnViewWillAppear = false + + // Uncomment the following line to display an Edit button in the navigation bar for this view controller. + // self.navigationItem.rightBarButtonItem = self.editButtonItem + + self.navigationController?.isToolbarHidden = true + } + + override func didReceiveMemoryWarning() { + super.didReceiveMemoryWarning() + // Dispose of any resources that can be recreated. + } + + // MARK: - Table view data source + + override func numberOfSections(in tableView: UITableView) -> Int { + // #warning Incomplete implementation, return the number of sections + return 1 + } + + override func tableView(_ tableView: UITableView, numberOfRowsInSection section: Int) -> Int { + // #warning Incomplete implementation, return the number of rows + let rowCount = dataCenter.branches.count + return rowCount + } + + + override func tableView(_ tableView: UITableView, cellForRowAt indexPath: IndexPath) -> UITableViewCell { + let cell = tableView.dequeueReusableCell(withIdentifier: "BranchCell", for: indexPath) + + // Configure the cell... + let branch = dataCenter.branches[indexPath.row] + cell.textLabel?.text = branch.name + + return cell + } + + + /* + // Override to support conditional editing of the table view. + override func tableView(_ tableView: UITableView, canEditRowAt indexPath: IndexPath) -> Bool { + // Return false if you do not want the specified item to be editable. + return true + } + */ + + /* + // Override to support editing the table view. + override func tableView(_ tableView: UITableView, commit editingStyle: UITableViewCellEditingStyle, forRowAt indexPath: IndexPath) { + if editingStyle == .delete { + // Delete the row from the data source + tableView.deleteRows(at: [indexPath], with: .fade) + } else if editingStyle == .insert { + // Create a new instance of the appropriate class, insert it into the array, and add a new row to the table view + } + } + */ + + /* + // Override to support rearranging the table view. + override func tableView(_ tableView: UITableView, moveRowAt fromIndexPath: IndexPath, to: IndexPath) { + + } + */ + + /* + // Override to support conditional rearranging of the table view. + override func tableView(_ tableView: UITableView, canMoveRowAt indexPath: IndexPath) -> Bool { + // Return false if you do not want the item to be re-orderable. + return true + } + */ + + + // MARK: - Navigation + + // In a storyboard-based application, you will often want to do a little preparation before navigation + override func prepare(for segue: UIStoryboardSegue, sender: Any?) { + // Get the new view controller using segue.destinationViewController. + // Pass the selected object to the new view controller. + + if segue.identifier == "ServiceSegue" { + if let destination = segue.destination as? ServiceListViewController { + if let selectedIndex = self.tableView.indexPathForSelectedRow?.row { + destination.branch = dataCenter.branches[selectedIndex] as Branch + } + } + } + + } +} diff --git "a/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/meetingRooms_tap&tool/meetingRooms/DataCenter.swift" "b/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/meetingRooms_tap&tool/meetingRooms/DataCenter.swift" new file mode 100644 index 0000000..4231269 --- /dev/null +++ "b/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/meetingRooms_tap&tool/meetingRooms/DataCenter.swift" @@ -0,0 +1,66 @@ +// +// DataCenter.swift +// meetingRooms +// +// Created by 황도증 on 2017. 11. 9.. +// Copyright © 2017년 황도증. All rights reserved. +// + +import Foundation + +let dataCenter:DataCenter = DataCenter() + +class DataCenter { + var branches:[Branch] = [] + + init (){ + let banksyRoom = MeetingRoom(name:"Banksy", capacity: 4) + let kahloRoom = MeetingRoom(name:"Kahlo", capacity: 8) + let riveraRoom = MeetingRoom(name:"Rivera", capacity: 8) + let picasoRoom = MeetingRoom(name:"Picaso", capacity: 10) + + let vehicleService = Service(name: "차량예약") + let meetingRoomService = Service(name: "회의실예약") + let visitorService = Service(name: "방문자예약") + let deskService = Service(name: "데스크예약") + meetingRoomService.items = [banksyRoom, kahloRoom, riveraRoom, picasoRoom] + + let pangyoBranch = Branch(name: "판교점") + let samsungBranch = Branch(name: "삼성점") + let yeoksamBranch = Branch(name: "역삼점") + let sinrimBranch = Branch(name: "신림점") + let songdooBranch = Branch(name: "송도점") + let anamBranch = Branch(name: "안암점") + pangyoBranch.services = [vehicleService, meetingRoomService, visitorService, deskService] + + branches += [pangyoBranch, samsungBranch, yeoksamBranch, sinrimBranch, songdooBranch, anamBranch] + } +} + +class Branch { + let name:String + var services:[Service]? + + init(name:String) { + self.name = name + } +} + +class Service { + let name:String + var items:[MeetingRoom]? + + init(name:String) { + self.name = name + } +} + +class MeetingRoom { + let name:String + let capacity:Int + + init(name:String, capacity:Int) { + self.name = name + self.capacity = capacity + } +} diff --git "a/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/meetingRooms_tap&tool/meetingRooms/Info.plist" "b/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/meetingRooms_tap&tool/meetingRooms/Info.plist" new file mode 100644 index 0000000..16be3b6 --- /dev/null +++ "b/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/meetingRooms_tap&tool/meetingRooms/Info.plist" @@ -0,0 +1,45 @@ + + + + + CFBundleDevelopmentRegion + $(DEVELOPMENT_LANGUAGE) + CFBundleExecutable + $(EXECUTABLE_NAME) + CFBundleIdentifier + $(PRODUCT_BUNDLE_IDENTIFIER) + CFBundleInfoDictionaryVersion + 6.0 + CFBundleName + $(PRODUCT_NAME) + CFBundlePackageType + APPL + CFBundleShortVersionString + 1.0 + CFBundleVersion + 1 + LSRequiresIPhoneOS + + UILaunchStoryboardName + LaunchScreen + UIMainStoryboardFile + Main + UIRequiredDeviceCapabilities + + armv7 + + UISupportedInterfaceOrientations + + UIInterfaceOrientationPortrait + UIInterfaceOrientationLandscapeLeft + UIInterfaceOrientationLandscapeRight + + UISupportedInterfaceOrientations~ipad + + UIInterfaceOrientationPortrait + UIInterfaceOrientationPortraitUpsideDown + UIInterfaceOrientationLandscapeLeft + UIInterfaceOrientationLandscapeRight + + + diff --git "a/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/meetingRooms_tap&tool/meetingRooms/MeetingRoomListViewController.swift" "b/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/meetingRooms_tap&tool/meetingRooms/MeetingRoomListViewController.swift" new file mode 100644 index 0000000..0d523b3 --- /dev/null +++ "b/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/meetingRooms_tap&tool/meetingRooms/MeetingRoomListViewController.swift" @@ -0,0 +1,111 @@ +// +// MeetingRoomListViewController.swift +// meetingRooms +// +// Created by 황도증 on 2017. 10. 30.. +// Copyright © 2017년 황도증. All rights reserved. +// + +import UIKit + +class MeetingRoomListViewController: UITableViewController { + + var service:Service? + + override func viewDidLoad() { + super.viewDidLoad() + + // Uncomment the following line to preserve selection between presentations + // self.clearsSelectionOnViewWillAppear = false + + // Uncomment the following line to display an Edit button in the navigation bar for this view controller. + // self.navigationItem.rightBarButtonItem = self.editButtonItem + + self.title = service?.name + } + + override func didReceiveMemoryWarning() { + super.didReceiveMemoryWarning() + // Dispose of any resources that can be recreated. + } + + // MARK: - Table view data source + + override func numberOfSections(in tableView: UITableView) -> Int { + // #warning Incomplete implementation, return the number of sections + return 1 + } + + override func tableView(_ tableView: UITableView, numberOfRowsInSection section: Int) -> Int { + // #warning Incomplete implementation, return the number of rows + //let categoryValues = Array(meetingRooms.values)[section] + //let orderMeetingRoooms = meetingRooms.sorted(by: {$0.1.first!.1 < $1.1.first!.1}) + guard let rowCount = service?.items?.count else { + return 0 + } + return rowCount + } + + + override func tableView(_ tableView: UITableView, cellForRowAt indexPath: IndexPath) -> UITableViewCell { + let cell = tableView.dequeueReusableCell(withIdentifier: "ItemCell", for: indexPath) + + //let orderMeetingRoooms = meetingRooms.sorted(by: {$0.1.first!.1 < $1.1.first!.1}) + // Configure the cell... + //let categoryValue = Array(meetingRooms.values)[indexPath.section] + + guard let meetingRoom = service?.items?[indexPath.row] else { + return cell + } + + cell.textLabel!.text = meetingRoom.name + cell.detailTextLabel!.text = String(meetingRoom.capacity) + return cell + } + + /* + // Override to support conditional editing of the table view. + override func tableView(_ tableView: UITableView, canEditRowAt indexPath: IndexPath) -> Bool { + // Return false if you do not want the specified item to be editable. + return true + } + */ + + /* + // Override to support editing the table view. + override func tableView(_ tableView: UITableView, commit editingStyle: UITableViewCellEditingStyle, forRowAt indexPath: IndexPath) { + if editingStyle == .delete { + // Delete the row from the data source + tableView.deleteRows(at: [indexPath], with: .fade) + } else if editingStyle == .insert { + // Create a new instance of the appropriate class, insert it into the array, and add a new row to the table view + } + } + */ + + /* + // Override to support rearranging the table view. + override func tableView(_ tableView: UITableView, moveRowAt fromIndexPath: IndexPath, to: IndexPath) { + + } + */ + + /* + // Override to support conditional rearranging of the table view. + override func tableView(_ tableView: UITableView, canMoveRowAt indexPath: IndexPath) -> Bool { + // Return false if you do not want the item to be re-orderable. + return true + } + */ + + + // MARK: - Navigation +/* + // In a storyboard-based application, you will often want to do a little preparation before navigation + override func prepare(for segue: UIStoryboardSegue, sender: Any?) { + // Get the new view controller using segue.destinationViewController. + // Pass the selected object to the new view controller. + + } + */ +} diff --git "a/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/meetingRooms_tap&tool/meetingRooms/ServiceListViewController.swift" "b/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/meetingRooms_tap&tool/meetingRooms/ServiceListViewController.swift" new file mode 100644 index 0000000..091d906 --- /dev/null +++ "b/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/meetingRooms_tap&tool/meetingRooms/ServiceListViewController.swift" @@ -0,0 +1,113 @@ +// +// ServiceListViewController.swift +// meetingRooms +// +// Created by 황도증 on 2017. 11. 9.. +// Copyright © 2017년 황도증. All rights reserved. +// + +import UIKit + +class ServiceListViewController: UITableViewController { + + var branch:Branch? + + override func viewDidLoad() { + super.viewDidLoad() + + // Uncomment the following line to preserve selection between presentations + // self.clearsSelectionOnViewWillAppear = false + + // Uncomment the following line to display an Edit button in the navigation bar for this view controller. + // self.navigationItem.rightBarButtonItem = self.editButtonItem + self.title = branch?.name + self.navigationController?.isToolbarHidden = false + } + + override func didReceiveMemoryWarning() { + super.didReceiveMemoryWarning() + // Dispose of any resources that can be recreated. + } + + // MARK: - Table view data source + + override func numberOfSections(in tableView: UITableView) -> Int { + // #warning Incomplete implementation, return the number of sections + return 1 + } + + override func tableView(_ tableView: UITableView, numberOfRowsInSection section: Int) -> Int { + // #warning Incomplete implementation, return the number of rows + guard let rowCount = branch?.services?.count else { + return 0 + } + return rowCount + } + + + override func tableView(_ tableView: UITableView, cellForRowAt indexPath: IndexPath) -> UITableViewCell { + let cell = tableView.dequeueReusableCell(withIdentifier: "ServiceCell", for: indexPath) + + // Configure the cell... + guard let service = branch?.services?[indexPath.row] else { + return cell + } + + cell.textLabel?.text = service.name + + return cell + } + + + /* + // Override to support conditional editing of the table view. + override func tableView(_ tableView: UITableView, canEditRowAt indexPath: IndexPath) -> Bool { + // Return false if you do not want the specified item to be editable. + return true + } + */ + + /* + // Override to support editing the table view. + override func tableView(_ tableView: UITableView, commit editingStyle: UITableViewCellEditingStyle, forRowAt indexPath: IndexPath) { + if editingStyle == .delete { + // Delete the row from the data source + tableView.deleteRows(at: [indexPath], with: .fade) + } else if editingStyle == .insert { + // Create a new instance of the appropriate class, insert it into the array, and add a new row to the table view + } + } + */ + + /* + // Override to support rearranging the table view. + override func tableView(_ tableView: UITableView, moveRowAt fromIndexPath: IndexPath, to: IndexPath) { + + } + */ + + /* + // Override to support conditional rearranging of the table view. + override func tableView(_ tableView: UITableView, canMoveRowAt indexPath: IndexPath) -> Bool { + // Return false if you do not want the item to be re-orderable. + return true + } + */ + + + // MARK: - Navigation + + // In a storyboard-based application, you will often want to do a little preparation before navigation + override func prepare(for segue: UIStoryboardSegue, sender: Any?) { + // Get the new view controller using segue.destinationViewController. + // Pass the selected object to the new view controller. + if segue.identifier == "MeetingRoomSegue" { + guard let destination = segue.destination as? MeetingRoomListViewController, let selectedIndex = self.tableView.indexPathForSelectedRow?.row, let service = branch?.services?[selectedIndex] else { + return + } + destination.service = service + } + } + + +} diff --git "a/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/meetingRooms_tap&tool/meetingRooms/ViewController.swift" "b/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/meetingRooms_tap&tool/meetingRooms/ViewController.swift" new file mode 100644 index 0000000..24bd9b0 --- /dev/null +++ "b/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/meetingRooms_tap&tool/meetingRooms/ViewController.swift" @@ -0,0 +1,25 @@ +// +// ViewController.swift +// meetingRooms +// +// Created by 황도증 on 2017. 10. 30.. +// Copyright © 2017년 황도증. All rights reserved. +// + +import UIKit + +class ViewController: UIViewController { + + override func viewDidLoad() { + super.viewDidLoad() + // Do any additional setup after loading the view, typically from a nib. + } + + override func didReceiveMemoryWarning() { + super.didReceiveMemoryWarning() + // Dispose of any resources that can be recreated. + } + + +} + diff --git "a/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/meetingRooms_tap&tool/meetingRoomsTests/Info.plist" "b/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/meetingRooms_tap&tool/meetingRoomsTests/Info.plist" new file mode 100644 index 0000000..6c40a6c --- /dev/null +++ "b/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/meetingRooms_tap&tool/meetingRoomsTests/Info.plist" @@ -0,0 +1,22 @@ + + + + + CFBundleDevelopmentRegion + $(DEVELOPMENT_LANGUAGE) + CFBundleExecutable + $(EXECUTABLE_NAME) + CFBundleIdentifier + $(PRODUCT_BUNDLE_IDENTIFIER) + CFBundleInfoDictionaryVersion + 6.0 + CFBundleName + $(PRODUCT_NAME) + CFBundlePackageType + BNDL + CFBundleShortVersionString + 1.0 + CFBundleVersion + 1 + + diff --git "a/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/meetingRooms_tap&tool/meetingRoomsTests/meetingRoomsTests.swift" "b/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/meetingRooms_tap&tool/meetingRoomsTests/meetingRoomsTests.swift" new file mode 100644 index 0000000..bfbd8d6 --- /dev/null +++ "b/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/meetingRooms_tap&tool/meetingRoomsTests/meetingRoomsTests.swift" @@ -0,0 +1,36 @@ +// +// meetingRoomsTests.swift +// meetingRoomsTests +// +// Created by 황도증 on 2017. 10. 30.. +// Copyright © 2017년 황도증. All rights reserved. +// + +import XCTest +@testable import meetingRooms + +class meetingRoomsTests: XCTestCase { + + override func setUp() { + super.setUp() + // Put setup code here. This method is called before the invocation of each test method in the class. + } + + override func tearDown() { + // Put teardown code here. This method is called after the invocation of each test method in the class. + super.tearDown() + } + + func testExample() { + // This is an example of a functional test case. + // Use XCTAssert and related functions to verify your tests produce the correct results. + } + + func testPerformanceExample() { + // This is an example of a performance test case. + self.measure { + // Put the code you want to measure the time of here. + } + } + +} diff --git "a/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/meetingRooms_tap&tool/meetingRoomsUITests/Info.plist" "b/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/meetingRooms_tap&tool/meetingRoomsUITests/Info.plist" new file mode 100644 index 0000000..6c40a6c --- /dev/null +++ "b/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/meetingRooms_tap&tool/meetingRoomsUITests/Info.plist" @@ -0,0 +1,22 @@ + + + + + CFBundleDevelopmentRegion + $(DEVELOPMENT_LANGUAGE) + CFBundleExecutable + $(EXECUTABLE_NAME) + CFBundleIdentifier + $(PRODUCT_BUNDLE_IDENTIFIER) + CFBundleInfoDictionaryVersion + 6.0 + CFBundleName + $(PRODUCT_NAME) + CFBundlePackageType + BNDL + CFBundleShortVersionString + 1.0 + CFBundleVersion + 1 + + diff --git "a/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/meetingRooms_tap&tool/meetingRoomsUITests/meetingRoomsUITests.swift" "b/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/meetingRooms_tap&tool/meetingRoomsUITests/meetingRoomsUITests.swift" new file mode 100644 index 0000000..4873bfa --- /dev/null +++ "b/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/meetingRooms_tap&tool/meetingRoomsUITests/meetingRoomsUITests.swift" @@ -0,0 +1,36 @@ +// +// meetingRoomsUITests.swift +// meetingRoomsUITests +// +// Created by 황도증 on 2017. 10. 30.. +// Copyright © 2017년 황도증. All rights reserved. +// + +import XCTest + +class meetingRoomsUITests: XCTestCase { + + override func setUp() { + super.setUp() + + // Put setup code here. This method is called before the invocation of each test method in the class. + + // In UI tests it is usually best to stop immediately when a failure occurs. + continueAfterFailure = false + // UI tests must launch the application that they test. Doing this in setup will make sure it happens for each test method. + XCUIApplication().launch() + + // In UI tests it’s important to set the initial state - such as interface orientation - required for your tests before they run. The setUp method is a good place to do this. + } + + override func tearDown() { + // Put teardown code here. This method is called after the invocation of each test method in the class. + super.tearDown() + } + + func testExample() { + // Use recording to get started writing UI tests. + // Use XCTAssert and related functions to verify your tests produce the correct results. + } + +} diff --git "a/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/meetingRooms_unwind/meetingRooms.xcodeproj/project.pbxproj" "b/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/meetingRooms_unwind/meetingRooms.xcodeproj/project.pbxproj" new file mode 100644 index 0000000..fd9c07f --- /dev/null +++ "b/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/meetingRooms_unwind/meetingRooms.xcodeproj/project.pbxproj" @@ -0,0 +1,585 @@ +// !$*UTF8*$! +{ + archiveVersion = 1; + classes = { + }; + objectVersion = 48; + objects = { + +/* Begin PBXBuildFile section */ + AE99575B1FA704AF00397D38 /* AppDelegate.swift in Sources */ = {isa = PBXBuildFile; fileRef = AE99575A1FA704AF00397D38 /* AppDelegate.swift */; }; + AE99575D1FA704AF00397D38 /* ViewController.swift in Sources */ = {isa = PBXBuildFile; fileRef = AE99575C1FA704AF00397D38 /* ViewController.swift */; }; + AE9957601FA704AF00397D38 /* Main.storyboard in Resources */ = {isa = PBXBuildFile; fileRef = AE99575E1FA704AF00397D38 /* Main.storyboard */; }; + AE9957621FA704AF00397D38 /* Assets.xcassets in Resources */ = {isa = PBXBuildFile; fileRef = AE9957611FA704AF00397D38 /* Assets.xcassets */; }; + AE9957651FA704AF00397D38 /* LaunchScreen.storyboard in Resources */ = {isa = PBXBuildFile; fileRef = AE9957631FA704AF00397D38 /* LaunchScreen.storyboard */; }; + AE9957701FA704AF00397D38 /* meetingRoomsTests.swift in Sources */ = {isa = PBXBuildFile; fileRef = AE99576F1FA704AF00397D38 /* meetingRoomsTests.swift */; }; + AE99577B1FA704B000397D38 /* meetingRoomsUITests.swift in Sources */ = {isa = PBXBuildFile; fileRef = AE99577A1FA704B000397D38 /* meetingRoomsUITests.swift */; }; + AE9957891FA7054800397D38 /* MeetingRoomListViewController.swift in Sources */ = {isa = PBXBuildFile; fileRef = AE9957881FA7054800397D38 /* MeetingRoomListViewController.swift */; }; + AEB3189D1FB4641000AEB094 /* DataCenter.swift in Sources */ = {isa = PBXBuildFile; fileRef = AEB3189C1FB4641000AEB094 /* DataCenter.swift */; }; + AEB3189F1FB4684600AEB094 /* BranchListViewController.swift in Sources */ = {isa = PBXBuildFile; fileRef = AEB3189E1FB4684600AEB094 /* BranchListViewController.swift */; }; + AEB318A11FB4685800AEB094 /* ServiceListViewController.swift in Sources */ = {isa = PBXBuildFile; fileRef = AEB318A01FB4685800AEB094 /* ServiceListViewController.swift */; }; + AEB318A31FB4807F00AEB094 /* RoomInfoViewController.swift in Sources */ = {isa = PBXBuildFile; fileRef = AEB318A21FB4807F00AEB094 /* RoomInfoViewController.swift */; }; + AEB318A51FB485D300AEB094 /* ReservationListViewController.swift in Sources */ = {isa = PBXBuildFile; fileRef = AEB318A41FB485D300AEB094 /* ReservationListViewController.swift */; }; + AEB318A71FB4861600AEB094 /* ReserveRoomViewController.swift in Sources */ = {isa = PBXBuildFile; fileRef = AEB318A61FB4861600AEB094 /* ReserveRoomViewController.swift */; }; +/* End PBXBuildFile section */ + +/* Begin PBXContainerItemProxy section */ + AE99576C1FA704AF00397D38 /* PBXContainerItemProxy */ = { + isa = PBXContainerItemProxy; + containerPortal = AE99574F1FA704AF00397D38 /* Project object */; + proxyType = 1; + remoteGlobalIDString = AE9957561FA704AF00397D38; + remoteInfo = meetingRooms; + }; + AE9957771FA704B000397D38 /* PBXContainerItemProxy */ = { + isa = PBXContainerItemProxy; + containerPortal = AE99574F1FA704AF00397D38 /* Project object */; + proxyType = 1; + remoteGlobalIDString = AE9957561FA704AF00397D38; + remoteInfo = meetingRooms; + }; +/* End PBXContainerItemProxy section */ + +/* Begin PBXFileReference section */ + AE9957571FA704AF00397D38 /* meetingRooms.app */ = {isa = PBXFileReference; explicitFileType = wrapper.application; includeInIndex = 0; path = meetingRooms.app; sourceTree = BUILT_PRODUCTS_DIR; }; + AE99575A1FA704AF00397D38 /* AppDelegate.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = AppDelegate.swift; sourceTree = ""; }; + AE99575C1FA704AF00397D38 /* ViewController.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = ViewController.swift; sourceTree = ""; }; + AE99575F1FA704AF00397D38 /* Base */ = {isa = PBXFileReference; lastKnownFileType = file.storyboard; name = Base; path = Base.lproj/Main.storyboard; sourceTree = ""; }; + AE9957611FA704AF00397D38 /* Assets.xcassets */ = {isa = PBXFileReference; lastKnownFileType = folder.assetcatalog; path = Assets.xcassets; sourceTree = ""; }; + AE9957641FA704AF00397D38 /* Base */ = {isa = PBXFileReference; lastKnownFileType = file.storyboard; name = Base; path = Base.lproj/LaunchScreen.storyboard; sourceTree = ""; }; + AE9957661FA704AF00397D38 /* Info.plist */ = {isa = PBXFileReference; lastKnownFileType = text.plist.xml; path = Info.plist; sourceTree = ""; }; + AE99576B1FA704AF00397D38 /* meetingRoomsTests.xctest */ = {isa = PBXFileReference; explicitFileType = wrapper.cfbundle; includeInIndex = 0; path = meetingRoomsTests.xctest; sourceTree = BUILT_PRODUCTS_DIR; }; + AE99576F1FA704AF00397D38 /* meetingRoomsTests.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = meetingRoomsTests.swift; sourceTree = ""; }; + AE9957711FA704AF00397D38 /* Info.plist */ = {isa = PBXFileReference; lastKnownFileType = text.plist.xml; path = Info.plist; sourceTree = ""; }; + AE9957761FA704B000397D38 /* meetingRoomsUITests.xctest */ = {isa = PBXFileReference; explicitFileType = wrapper.cfbundle; includeInIndex = 0; path = meetingRoomsUITests.xctest; sourceTree = BUILT_PRODUCTS_DIR; }; + AE99577A1FA704B000397D38 /* meetingRoomsUITests.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = meetingRoomsUITests.swift; sourceTree = ""; }; + AE99577C1FA704B000397D38 /* Info.plist */ = {isa = PBXFileReference; lastKnownFileType = text.plist.xml; path = Info.plist; sourceTree = ""; }; + AE9957881FA7054800397D38 /* MeetingRoomListViewController.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = MeetingRoomListViewController.swift; sourceTree = ""; }; + AEB3189C1FB4641000AEB094 /* DataCenter.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = DataCenter.swift; sourceTree = ""; }; + AEB3189E1FB4684600AEB094 /* BranchListViewController.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = BranchListViewController.swift; sourceTree = ""; }; + AEB318A01FB4685800AEB094 /* ServiceListViewController.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = ServiceListViewController.swift; sourceTree = ""; }; + AEB318A21FB4807F00AEB094 /* RoomInfoViewController.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = RoomInfoViewController.swift; sourceTree = ""; }; + AEB318A41FB485D300AEB094 /* ReservationListViewController.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = ReservationListViewController.swift; sourceTree = ""; }; + AEB318A61FB4861600AEB094 /* ReserveRoomViewController.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = ReserveRoomViewController.swift; sourceTree = ""; }; +/* End PBXFileReference section */ + +/* Begin PBXFrameworksBuildPhase section */ + AE9957541FA704AF00397D38 /* Frameworks */ = { + isa = PBXFrameworksBuildPhase; + buildActionMask = 2147483647; + files = ( + ); + runOnlyForDeploymentPostprocessing = 0; + }; + AE9957681FA704AF00397D38 /* Frameworks */ = { + isa = PBXFrameworksBuildPhase; + buildActionMask = 2147483647; + files = ( + ); + runOnlyForDeploymentPostprocessing = 0; + }; + AE9957731FA704B000397D38 /* Frameworks */ = { + isa = PBXFrameworksBuildPhase; + buildActionMask = 2147483647; + files = ( + ); + runOnlyForDeploymentPostprocessing = 0; + }; +/* End PBXFrameworksBuildPhase section */ + +/* Begin PBXGroup section */ + AE99574E1FA704AF00397D38 = { + isa = PBXGroup; + children = ( + AE9957591FA704AF00397D38 /* meetingRooms */, + AE99576E1FA704AF00397D38 /* meetingRoomsTests */, + AE9957791FA704B000397D38 /* meetingRoomsUITests */, + AE9957581FA704AF00397D38 /* Products */, + ); + sourceTree = ""; + }; + AE9957581FA704AF00397D38 /* Products */ = { + isa = PBXGroup; + children = ( + AE9957571FA704AF00397D38 /* meetingRooms.app */, + AE99576B1FA704AF00397D38 /* meetingRoomsTests.xctest */, + AE9957761FA704B000397D38 /* meetingRoomsUITests.xctest */, + ); + name = Products; + sourceTree = ""; + }; + AE9957591FA704AF00397D38 /* meetingRooms */ = { + isa = PBXGroup; + children = ( + AE99575A1FA704AF00397D38 /* AppDelegate.swift */, + AE99575C1FA704AF00397D38 /* ViewController.swift */, + AE99575E1FA704AF00397D38 /* Main.storyboard */, + AEB318A61FB4861600AEB094 /* ReserveRoomViewController.swift */, + AEB318A41FB485D300AEB094 /* ReservationListViewController.swift */, + AEB318A21FB4807F00AEB094 /* RoomInfoViewController.swift */, + AEB3189C1FB4641000AEB094 /* DataCenter.swift */, + AEB3189E1FB4684600AEB094 /* BranchListViewController.swift */, + AEB318A01FB4685800AEB094 /* ServiceListViewController.swift */, + AE9957881FA7054800397D38 /* MeetingRoomListViewController.swift */, + AE9957611FA704AF00397D38 /* Assets.xcassets */, + AE9957631FA704AF00397D38 /* LaunchScreen.storyboard */, + AE9957661FA704AF00397D38 /* Info.plist */, + ); + path = meetingRooms; + sourceTree = ""; + }; + AE99576E1FA704AF00397D38 /* meetingRoomsTests */ = { + isa = PBXGroup; + children = ( + AE99576F1FA704AF00397D38 /* meetingRoomsTests.swift */, + AE9957711FA704AF00397D38 /* Info.plist */, + ); + path = meetingRoomsTests; + sourceTree = ""; + }; + AE9957791FA704B000397D38 /* meetingRoomsUITests */ = { + isa = PBXGroup; + children = ( + AE99577A1FA704B000397D38 /* meetingRoomsUITests.swift */, + AE99577C1FA704B000397D38 /* Info.plist */, + ); + path = meetingRoomsUITests; + sourceTree = ""; + }; +/* End PBXGroup section */ + +/* Begin PBXNativeTarget section */ + AE9957561FA704AF00397D38 /* meetingRooms */ = { + isa = PBXNativeTarget; + buildConfigurationList = AE99577F1FA704B000397D38 /* Build configuration list for PBXNativeTarget "meetingRooms" */; + buildPhases = ( + AE9957531FA704AF00397D38 /* Sources */, + AE9957541FA704AF00397D38 /* Frameworks */, + AE9957551FA704AF00397D38 /* Resources */, + ); + buildRules = ( + ); + dependencies = ( + ); + name = meetingRooms; + productName = meetingRooms; + productReference = AE9957571FA704AF00397D38 /* meetingRooms.app */; + productType = "com.apple.product-type.application"; + }; + AE99576A1FA704AF00397D38 /* meetingRoomsTests */ = { + isa = PBXNativeTarget; + buildConfigurationList = AE9957821FA704B000397D38 /* Build configuration list for PBXNativeTarget "meetingRoomsTests" */; + buildPhases = ( + AE9957671FA704AF00397D38 /* Sources */, + AE9957681FA704AF00397D38 /* Frameworks */, + AE9957691FA704AF00397D38 /* Resources */, + ); + buildRules = ( + ); + dependencies = ( + AE99576D1FA704AF00397D38 /* PBXTargetDependency */, + ); + name = meetingRoomsTests; + productName = meetingRoomsTests; + productReference = AE99576B1FA704AF00397D38 /* meetingRoomsTests.xctest */; + productType = "com.apple.product-type.bundle.unit-test"; + }; + AE9957751FA704B000397D38 /* meetingRoomsUITests */ = { + isa = PBXNativeTarget; + buildConfigurationList = AE9957851FA704B000397D38 /* Build configuration list for PBXNativeTarget "meetingRoomsUITests" */; + buildPhases = ( + AE9957721FA704B000397D38 /* Sources */, + AE9957731FA704B000397D38 /* Frameworks */, + AE9957741FA704B000397D38 /* Resources */, + ); + buildRules = ( + ); + dependencies = ( + AE9957781FA704B000397D38 /* PBXTargetDependency */, + ); + name = meetingRoomsUITests; + productName = meetingRoomsUITests; + productReference = AE9957761FA704B000397D38 /* meetingRoomsUITests.xctest */; + productType = "com.apple.product-type.bundle.ui-testing"; + }; +/* End PBXNativeTarget section */ + +/* Begin PBXProject section */ + AE99574F1FA704AF00397D38 /* Project object */ = { + isa = PBXProject; + attributes = { + LastSwiftUpdateCheck = 0900; + LastUpgradeCheck = 0900; + ORGANIZATIONNAME = "황도증"; + TargetAttributes = { + AE9957561FA704AF00397D38 = { + CreatedOnToolsVersion = 9.0.1; + ProvisioningStyle = Automatic; + }; + AE99576A1FA704AF00397D38 = { + CreatedOnToolsVersion = 9.0.1; + ProvisioningStyle = Automatic; + TestTargetID = AE9957561FA704AF00397D38; + }; + AE9957751FA704B000397D38 = { + CreatedOnToolsVersion = 9.0.1; + ProvisioningStyle = Automatic; + TestTargetID = AE9957561FA704AF00397D38; + }; + }; + }; + buildConfigurationList = AE9957521FA704AF00397D38 /* Build configuration list for PBXProject "meetingRooms" */; + compatibilityVersion = "Xcode 8.0"; + developmentRegion = en; + hasScannedForEncodings = 0; + knownRegions = ( + en, + Base, + ); + mainGroup = AE99574E1FA704AF00397D38; + productRefGroup = AE9957581FA704AF00397D38 /* Products */; + projectDirPath = ""; + projectRoot = ""; + targets = ( + AE9957561FA704AF00397D38 /* meetingRooms */, + AE99576A1FA704AF00397D38 /* meetingRoomsTests */, + AE9957751FA704B000397D38 /* meetingRoomsUITests */, + ); + }; +/* End PBXProject section */ + +/* Begin PBXResourcesBuildPhase section */ + AE9957551FA704AF00397D38 /* Resources */ = { + isa = PBXResourcesBuildPhase; + buildActionMask = 2147483647; + files = ( + AE9957651FA704AF00397D38 /* LaunchScreen.storyboard in Resources */, + AE9957621FA704AF00397D38 /* Assets.xcassets in Resources */, + AE9957601FA704AF00397D38 /* Main.storyboard in Resources */, + ); + runOnlyForDeploymentPostprocessing = 0; + }; + AE9957691FA704AF00397D38 /* Resources */ = { + isa = PBXResourcesBuildPhase; + buildActionMask = 2147483647; + files = ( + ); + runOnlyForDeploymentPostprocessing = 0; + }; + AE9957741FA704B000397D38 /* Resources */ = { + isa = PBXResourcesBuildPhase; + buildActionMask = 2147483647; + files = ( + ); + runOnlyForDeploymentPostprocessing = 0; + }; +/* End PBXResourcesBuildPhase section */ + +/* Begin PBXSourcesBuildPhase section */ + AE9957531FA704AF00397D38 /* Sources */ = { + isa = PBXSourcesBuildPhase; + buildActionMask = 2147483647; + files = ( + AEB318A31FB4807F00AEB094 /* RoomInfoViewController.swift in Sources */, + AE99575D1FA704AF00397D38 /* ViewController.swift in Sources */, + AE99575B1FA704AF00397D38 /* AppDelegate.swift in Sources */, + AEB318A51FB485D300AEB094 /* ReservationListViewController.swift in Sources */, + AEB3189D1FB4641000AEB094 /* DataCenter.swift in Sources */, + AEB3189F1FB4684600AEB094 /* BranchListViewController.swift in Sources */, + AEB318A11FB4685800AEB094 /* ServiceListViewController.swift in Sources */, + AE9957891FA7054800397D38 /* MeetingRoomListViewController.swift in Sources */, + AEB318A71FB4861600AEB094 /* ReserveRoomViewController.swift in Sources */, + ); + runOnlyForDeploymentPostprocessing = 0; + }; + AE9957671FA704AF00397D38 /* Sources */ = { + isa = PBXSourcesBuildPhase; + buildActionMask = 2147483647; + files = ( + AE9957701FA704AF00397D38 /* meetingRoomsTests.swift in Sources */, + ); + runOnlyForDeploymentPostprocessing = 0; + }; + AE9957721FA704B000397D38 /* Sources */ = { + isa = PBXSourcesBuildPhase; + buildActionMask = 2147483647; + files = ( + AE99577B1FA704B000397D38 /* meetingRoomsUITests.swift in Sources */, + ); + runOnlyForDeploymentPostprocessing = 0; + }; +/* End PBXSourcesBuildPhase section */ + +/* Begin PBXTargetDependency section */ + AE99576D1FA704AF00397D38 /* PBXTargetDependency */ = { + isa = PBXTargetDependency; + target = AE9957561FA704AF00397D38 /* meetingRooms */; + targetProxy = AE99576C1FA704AF00397D38 /* PBXContainerItemProxy */; + }; + AE9957781FA704B000397D38 /* PBXTargetDependency */ = { + isa = PBXTargetDependency; + target = AE9957561FA704AF00397D38 /* meetingRooms */; + targetProxy = AE9957771FA704B000397D38 /* PBXContainerItemProxy */; + }; +/* End PBXTargetDependency section */ + +/* Begin PBXVariantGroup section */ + AE99575E1FA704AF00397D38 /* Main.storyboard */ = { + isa = PBXVariantGroup; + children = ( + AE99575F1FA704AF00397D38 /* Base */, + ); + name = Main.storyboard; + sourceTree = ""; + }; + AE9957631FA704AF00397D38 /* LaunchScreen.storyboard */ = { + isa = PBXVariantGroup; + children = ( + AE9957641FA704AF00397D38 /* Base */, + ); + name = LaunchScreen.storyboard; + sourceTree = ""; + }; +/* End PBXVariantGroup section */ + +/* Begin XCBuildConfiguration section */ + AE99577D1FA704B000397D38 /* Debug */ = { + isa = XCBuildConfiguration; + buildSettings = { + ALWAYS_SEARCH_USER_PATHS = NO; + CLANG_ANALYZER_NONNULL = YES; + CLANG_ANALYZER_NUMBER_OBJECT_CONVERSION = YES_AGGRESSIVE; + CLANG_CXX_LANGUAGE_STANDARD = "gnu++14"; + CLANG_CXX_LIBRARY = "libc++"; + CLANG_ENABLE_MODULES = YES; + CLANG_ENABLE_OBJC_ARC = YES; + CLANG_WARN_BLOCK_CAPTURE_AUTORELEASING = YES; + CLANG_WARN_BOOL_CONVERSION = YES; + CLANG_WARN_COMMA = YES; + CLANG_WARN_CONSTANT_CONVERSION = YES; + CLANG_WARN_DIRECT_OBJC_ISA_USAGE = YES_ERROR; + CLANG_WARN_DOCUMENTATION_COMMENTS = YES; + CLANG_WARN_EMPTY_BODY = YES; + CLANG_WARN_ENUM_CONVERSION = YES; + CLANG_WARN_INFINITE_RECURSION = YES; + CLANG_WARN_INT_CONVERSION = YES; + CLANG_WARN_NON_LITERAL_NULL_CONVERSION = YES; + CLANG_WARN_OBJC_LITERAL_CONVERSION = YES; + CLANG_WARN_OBJC_ROOT_CLASS = YES_ERROR; + CLANG_WARN_RANGE_LOOP_ANALYSIS = YES; + CLANG_WARN_STRICT_PROTOTYPES = YES; + CLANG_WARN_SUSPICIOUS_MOVE = YES; + CLANG_WARN_UNGUARDED_AVAILABILITY = YES_AGGRESSIVE; + CLANG_WARN_UNREACHABLE_CODE = YES; + CLANG_WARN__DUPLICATE_METHOD_MATCH = YES; + CODE_SIGN_IDENTITY = "iPhone Developer"; + COPY_PHASE_STRIP = NO; + DEBUG_INFORMATION_FORMAT = dwarf; + ENABLE_STRICT_OBJC_MSGSEND = YES; + ENABLE_TESTABILITY = YES; + GCC_C_LANGUAGE_STANDARD = gnu11; + GCC_DYNAMIC_NO_PIC = NO; + GCC_NO_COMMON_BLOCKS = YES; + GCC_OPTIMIZATION_LEVEL = 0; + GCC_PREPROCESSOR_DEFINITIONS = ( + "DEBUG=1", + "$(inherited)", + ); + GCC_WARN_64_TO_32_BIT_CONVERSION = YES; + GCC_WARN_ABOUT_RETURN_TYPE = YES_ERROR; + GCC_WARN_UNDECLARED_SELECTOR = YES; + GCC_WARN_UNINITIALIZED_AUTOS = YES_AGGRESSIVE; + GCC_WARN_UNUSED_FUNCTION = YES; + GCC_WARN_UNUSED_VARIABLE = YES; + IPHONEOS_DEPLOYMENT_TARGET = 11.0; + MTL_ENABLE_DEBUG_INFO = YES; + ONLY_ACTIVE_ARCH = YES; + SDKROOT = iphoneos; + SWIFT_ACTIVE_COMPILATION_CONDITIONS = DEBUG; + SWIFT_OPTIMIZATION_LEVEL = "-Onone"; + }; + name = Debug; + }; + AE99577E1FA704B000397D38 /* Release */ = { + isa = XCBuildConfiguration; + buildSettings = { + ALWAYS_SEARCH_USER_PATHS = NO; + CLANG_ANALYZER_NONNULL = YES; + CLANG_ANALYZER_NUMBER_OBJECT_CONVERSION = YES_AGGRESSIVE; + CLANG_CXX_LANGUAGE_STANDARD = "gnu++14"; + CLANG_CXX_LIBRARY = "libc++"; + CLANG_ENABLE_MODULES = YES; + CLANG_ENABLE_OBJC_ARC = YES; + CLANG_WARN_BLOCK_CAPTURE_AUTORELEASING = YES; + CLANG_WARN_BOOL_CONVERSION = YES; + CLANG_WARN_COMMA = YES; + CLANG_WARN_CONSTANT_CONVERSION = YES; + CLANG_WARN_DIRECT_OBJC_ISA_USAGE = YES_ERROR; + CLANG_WARN_DOCUMENTATION_COMMENTS = YES; + CLANG_WARN_EMPTY_BODY = YES; + CLANG_WARN_ENUM_CONVERSION = YES; + CLANG_WARN_INFINITE_RECURSION = YES; + CLANG_WARN_INT_CONVERSION = YES; + CLANG_WARN_NON_LITERAL_NULL_CONVERSION = YES; + CLANG_WARN_OBJC_LITERAL_CONVERSION = YES; + CLANG_WARN_OBJC_ROOT_CLASS = YES_ERROR; + CLANG_WARN_RANGE_LOOP_ANALYSIS = YES; + CLANG_WARN_STRICT_PROTOTYPES = YES; + CLANG_WARN_SUSPICIOUS_MOVE = YES; + CLANG_WARN_UNGUARDED_AVAILABILITY = YES_AGGRESSIVE; + CLANG_WARN_UNREACHABLE_CODE = YES; + CLANG_WARN__DUPLICATE_METHOD_MATCH = YES; + CODE_SIGN_IDENTITY = "iPhone Developer"; + COPY_PHASE_STRIP = NO; + DEBUG_INFORMATION_FORMAT = "dwarf-with-dsym"; + ENABLE_NS_ASSERTIONS = NO; + ENABLE_STRICT_OBJC_MSGSEND = YES; + GCC_C_LANGUAGE_STANDARD = gnu11; + GCC_NO_COMMON_BLOCKS = YES; + GCC_WARN_64_TO_32_BIT_CONVERSION = YES; + GCC_WARN_ABOUT_RETURN_TYPE = YES_ERROR; + GCC_WARN_UNDECLARED_SELECTOR = YES; + GCC_WARN_UNINITIALIZED_AUTOS = YES_AGGRESSIVE; + GCC_WARN_UNUSED_FUNCTION = YES; + GCC_WARN_UNUSED_VARIABLE = YES; + IPHONEOS_DEPLOYMENT_TARGET = 11.0; + MTL_ENABLE_DEBUG_INFO = NO; + SDKROOT = iphoneos; + SWIFT_OPTIMIZATION_LEVEL = "-Owholemodule"; + VALIDATE_PRODUCT = YES; + }; + name = Release; + }; + AE9957801FA704B000397D38 /* Debug */ = { + isa = XCBuildConfiguration; + buildSettings = { + ASSETCATALOG_COMPILER_APPICON_NAME = AppIcon; + CODE_SIGN_STYLE = Automatic; + INFOPLIST_FILE = meetingRooms/Info.plist; + LD_RUNPATH_SEARCH_PATHS = "$(inherited) @executable_path/Frameworks"; + PRODUCT_BUNDLE_IDENTIFIER = "--------.meetingRooms"; + PRODUCT_NAME = "$(TARGET_NAME)"; + SWIFT_VERSION = 4.0; + TARGETED_DEVICE_FAMILY = "1,2"; + }; + name = Debug; + }; + AE9957811FA704B000397D38 /* Release */ = { + isa = XCBuildConfiguration; + buildSettings = { + ASSETCATALOG_COMPILER_APPICON_NAME = AppIcon; + CODE_SIGN_STYLE = Automatic; + INFOPLIST_FILE = meetingRooms/Info.plist; + LD_RUNPATH_SEARCH_PATHS = "$(inherited) @executable_path/Frameworks"; + PRODUCT_BUNDLE_IDENTIFIER = "--------.meetingRooms"; + PRODUCT_NAME = "$(TARGET_NAME)"; + SWIFT_VERSION = 4.0; + TARGETED_DEVICE_FAMILY = "1,2"; + }; + name = Release; + }; + AE9957831FA704B000397D38 /* Debug */ = { + isa = XCBuildConfiguration; + buildSettings = { + ALWAYS_EMBED_SWIFT_STANDARD_LIBRARIES = YES; + BUNDLE_LOADER = "$(TEST_HOST)"; + CODE_SIGN_STYLE = Automatic; + INFOPLIST_FILE = meetingRoomsTests/Info.plist; + LD_RUNPATH_SEARCH_PATHS = "$(inherited) @executable_path/Frameworks @loader_path/Frameworks"; + PRODUCT_BUNDLE_IDENTIFIER = "--------.meetingRoomsTests"; + PRODUCT_NAME = "$(TARGET_NAME)"; + SWIFT_VERSION = 4.0; + TARGETED_DEVICE_FAMILY = "1,2"; + TEST_HOST = "$(BUILT_PRODUCTS_DIR)/meetingRooms.app/meetingRooms"; + }; + name = Debug; + }; + AE9957841FA704B000397D38 /* Release */ = { + isa = XCBuildConfiguration; + buildSettings = { + ALWAYS_EMBED_SWIFT_STANDARD_LIBRARIES = YES; + BUNDLE_LOADER = "$(TEST_HOST)"; + CODE_SIGN_STYLE = Automatic; + INFOPLIST_FILE = meetingRoomsTests/Info.plist; + LD_RUNPATH_SEARCH_PATHS = "$(inherited) @executable_path/Frameworks @loader_path/Frameworks"; + PRODUCT_BUNDLE_IDENTIFIER = "--------.meetingRoomsTests"; + PRODUCT_NAME = "$(TARGET_NAME)"; + SWIFT_VERSION = 4.0; + TARGETED_DEVICE_FAMILY = "1,2"; + TEST_HOST = "$(BUILT_PRODUCTS_DIR)/meetingRooms.app/meetingRooms"; + }; + name = Release; + }; + AE9957861FA704B000397D38 /* Debug */ = { + isa = XCBuildConfiguration; + buildSettings = { + ALWAYS_EMBED_SWIFT_STANDARD_LIBRARIES = YES; + CODE_SIGN_STYLE = Automatic; + INFOPLIST_FILE = meetingRoomsUITests/Info.plist; + LD_RUNPATH_SEARCH_PATHS = "$(inherited) @executable_path/Frameworks @loader_path/Frameworks"; + PRODUCT_BUNDLE_IDENTIFIER = "--------.meetingRoomsUITests"; + PRODUCT_NAME = "$(TARGET_NAME)"; + SWIFT_VERSION = 4.0; + TARGETED_DEVICE_FAMILY = "1,2"; + TEST_TARGET_NAME = meetingRooms; + }; + name = Debug; + }; + AE9957871FA704B000397D38 /* Release */ = { + isa = XCBuildConfiguration; + buildSettings = { + ALWAYS_EMBED_SWIFT_STANDARD_LIBRARIES = YES; + CODE_SIGN_STYLE = Automatic; + INFOPLIST_FILE = meetingRoomsUITests/Info.plist; + LD_RUNPATH_SEARCH_PATHS = "$(inherited) @executable_path/Frameworks @loader_path/Frameworks"; + PRODUCT_BUNDLE_IDENTIFIER = "--------.meetingRoomsUITests"; + PRODUCT_NAME = "$(TARGET_NAME)"; + SWIFT_VERSION = 4.0; + TARGETED_DEVICE_FAMILY = "1,2"; + TEST_TARGET_NAME = meetingRooms; + }; + name = Release; + }; +/* End XCBuildConfiguration section */ + +/* Begin XCConfigurationList section */ + AE9957521FA704AF00397D38 /* Build configuration list for PBXProject "meetingRooms" */ = { + isa = XCConfigurationList; + buildConfigurations = ( + AE99577D1FA704B000397D38 /* Debug */, + AE99577E1FA704B000397D38 /* Release */, + ); + defaultConfigurationIsVisible = 0; + defaultConfigurationName = Release; + }; + AE99577F1FA704B000397D38 /* Build configuration list for PBXNativeTarget "meetingRooms" */ = { + isa = XCConfigurationList; + buildConfigurations = ( + AE9957801FA704B000397D38 /* Debug */, + AE9957811FA704B000397D38 /* Release */, + ); + defaultConfigurationIsVisible = 0; + defaultConfigurationName = Release; + }; + AE9957821FA704B000397D38 /* Build configuration list for PBXNativeTarget "meetingRoomsTests" */ = { + isa = XCConfigurationList; + buildConfigurations = ( + AE9957831FA704B000397D38 /* Debug */, + AE9957841FA704B000397D38 /* Release */, + ); + defaultConfigurationIsVisible = 0; + defaultConfigurationName = Release; + }; + AE9957851FA704B000397D38 /* Build configuration list for PBXNativeTarget "meetingRoomsUITests" */ = { + isa = XCConfigurationList; + buildConfigurations = ( + AE9957861FA704B000397D38 /* Debug */, + AE9957871FA704B000397D38 /* Release */, + ); + defaultConfigurationIsVisible = 0; + defaultConfigurationName = Release; + }; +/* End XCConfigurationList section */ + }; + rootObject = AE99574F1FA704AF00397D38 /* Project object */; +} diff --git "a/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/meetingRooms_unwind/meetingRooms.xcodeproj/project.xcworkspace/contents.xcworkspacedata" "b/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/meetingRooms_unwind/meetingRooms.xcodeproj/project.xcworkspace/contents.xcworkspacedata" new file mode 100644 index 0000000..8491799 --- /dev/null +++ "b/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/meetingRooms_unwind/meetingRooms.xcodeproj/project.xcworkspace/contents.xcworkspacedata" @@ -0,0 +1,7 @@ + + + + + diff --git "a/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/meetingRooms_unwind/meetingRooms/AppDelegate.swift" "b/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/meetingRooms_unwind/meetingRooms/AppDelegate.swift" new file mode 100644 index 0000000..fc60321 --- /dev/null +++ "b/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/meetingRooms_unwind/meetingRooms/AppDelegate.swift" @@ -0,0 +1,46 @@ +// +// AppDelegate.swift +// meetingRooms +// +// Created by 황도증 on 2017. 10. 30.. +// Copyright © 2017년 황도증. All rights reserved. +// + +import UIKit + +@UIApplicationMain +class AppDelegate: UIResponder, UIApplicationDelegate { + + var window: UIWindow? + + + func application(_ application: UIApplication, didFinishLaunchingWithOptions launchOptions: [UIApplicationLaunchOptionsKey: Any]?) -> Bool { + // Override point for customization after application launch. + return true + } + + func applicationWillResignActive(_ application: UIApplication) { + // Sent when the application is about to move from active to inactive state. This can occur for certain types of temporary interruptions (such as an incoming phone call or SMS message) or when the user quits the application and it begins the transition to the background state. + // Use this method to pause ongoing tasks, disable timers, and invalidate graphics rendering callbacks. Games should use this method to pause the game. + } + + func applicationDidEnterBackground(_ application: UIApplication) { + // Use this method to release shared resources, save user data, invalidate timers, and store enough application state information to restore your application to its current state in case it is terminated later. + // If your application supports background execution, this method is called instead of applicationWillTerminate: when the user quits. + } + + func applicationWillEnterForeground(_ application: UIApplication) { + // Called as part of the transition from the background to the active state; here you can undo many of the changes made on entering the background. + } + + func applicationDidBecomeActive(_ application: UIApplication) { + // Restart any tasks that were paused (or not yet started) while the application was inactive. If the application was previously in the background, optionally refresh the user interface. + } + + func applicationWillTerminate(_ application: UIApplication) { + // Called when the application is about to terminate. Save data if appropriate. See also applicationDidEnterBackground:. + } + + +} + diff --git "a/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/meetingRooms_unwind/meetingRooms/Assets.xcassets/AppIcon.appiconset/Contents.json" "b/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/meetingRooms_unwind/meetingRooms/Assets.xcassets/AppIcon.appiconset/Contents.json" new file mode 100644 index 0000000..d8db8d6 --- /dev/null +++ "b/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/meetingRooms_unwind/meetingRooms/Assets.xcassets/AppIcon.appiconset/Contents.json" @@ -0,0 +1,98 @@ +{ + "images" : [ + { + "idiom" : "iphone", + "size" : "20x20", + "scale" : "2x" + }, + { + "idiom" : "iphone", + "size" : "20x20", + "scale" : "3x" + }, + { + "idiom" : "iphone", + "size" : "29x29", + "scale" : "2x" + }, + { + "idiom" : "iphone", + "size" : "29x29", + "scale" : "3x" + }, + { + "idiom" : "iphone", + "size" : "40x40", + "scale" : "2x" + }, + { + "idiom" : "iphone", + "size" : "40x40", + "scale" : "3x" + }, + { + "idiom" : "iphone", + "size" : "60x60", + "scale" : "2x" + }, + { + "idiom" : "iphone", + "size" : "60x60", + "scale" : "3x" + }, + { + "idiom" : "ipad", + "size" : "20x20", + "scale" : "1x" + }, + { + "idiom" : "ipad", + "size" : "20x20", + "scale" : "2x" + }, + { + "idiom" : "ipad", + "size" : "29x29", + "scale" : "1x" + }, + { + "idiom" : "ipad", + "size" : "29x29", + "scale" : "2x" + }, + { + "idiom" : "ipad", + "size" : "40x40", + "scale" : "1x" + }, + { + "idiom" : "ipad", + "size" : "40x40", + "scale" : "2x" + }, + { + "idiom" : "ipad", + "size" : "76x76", + "scale" : "1x" + }, + { + "idiom" : "ipad", + "size" : "76x76", + "scale" : "2x" + }, + { + "idiom" : "ipad", + "size" : "83.5x83.5", + "scale" : "2x" + }, + { + "idiom" : "ios-marketing", + "size" : "1024x1024", + "scale" : "1x" + } + ], + "info" : { + "version" : 1, + "author" : "xcode" + } +} \ No newline at end of file diff --git "a/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/meetingRooms_unwind/meetingRooms/Base.lproj/LaunchScreen.storyboard" "b/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/meetingRooms_unwind/meetingRooms/Base.lproj/LaunchScreen.storyboard" new file mode 100644 index 0000000..f83f6fd --- /dev/null +++ "b/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/meetingRooms_unwind/meetingRooms/Base.lproj/LaunchScreen.storyboard" @@ -0,0 +1,25 @@ + + + + + + + + + + + + + + + + + + + + + + + + + diff --git "a/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/meetingRooms_unwind/meetingRooms/Base.lproj/Main.storyboard" "b/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/meetingRooms_unwind/meetingRooms/Base.lproj/Main.storyboard" new file mode 100644 index 0000000..8ebb8bc --- /dev/null +++ "b/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/meetingRooms_unwind/meetingRooms/Base.lproj/Main.storyboard" @@ -0,0 +1,619 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + diff --git "a/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/meetingRooms_unwind/meetingRooms/BranchListViewController.swift" "b/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/meetingRooms_unwind/meetingRooms/BranchListViewController.swift" new file mode 100644 index 0000000..fa28525 --- /dev/null +++ "b/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/meetingRooms_unwind/meetingRooms/BranchListViewController.swift" @@ -0,0 +1,119 @@ +// +// BranchListViewController.swift +// meetingRooms +// +// Created by 황도증 on 2017. 11. 9.. +// Copyright © 2017년 황도증. All rights reserved. +// + +import UIKit + +class BranchListViewController: UITableViewController { + + override func viewDidLoad() { + super.viewDidLoad() + + // Uncomment the following line to preserve selection between presentations + // self.clearsSelectionOnViewWillAppear = false + + // Uncomment the following line to display an Edit button in the navigation bar for this view controller. + // self.navigationItem.rightBarButtonItem = self.editButtonItem + + self.navigationController?.isToolbarHidden = true + } + + override func didReceiveMemoryWarning() { + super.didReceiveMemoryWarning() + // Dispose of any resources that can be recreated. + } + + // MARK: - Table view data source + + override func numberOfSections(in tableView: UITableView) -> Int { + // #warning Incomplete implementation, return the number of sections + return 1 + } + + @IBAction func locationTurnOn(_ sender: Any) { + let locationAlert = UIAlertController(title:"위치정보요청", message: "위치정보를 기반으로 가까운 지점을 자동으로 선택할 수 있습니다.", preferredStyle: .actionSheet) + + let locationAction = UIAlertAction(title: "위치정보켜기", style: .default, handler: {(action:UIAlertAction) -> Void in print("위치정보켜기 선택")}) + + let openMapAction = UIAlertAction(title: "지도에서 열기", style: .default, handler: {(action:UIAlertAction) -> Void in print("지도앱에서 열기 선택")}) + + locationAlert.addAction(locationAction) + locationAlert.addAction(openMapAction) + + self.present(locationAlert, animated: true, completion: nil) + } + override func tableView(_ tableView: UITableView, numberOfRowsInSection section: Int) -> Int { + // #warning Incomplete implementation, return the number of rows + let rowCount = dataCenter.branches.count + return rowCount + } + + + override func tableView(_ tableView: UITableView, cellForRowAt indexPath: IndexPath) -> UITableViewCell { + let cell = tableView.dequeueReusableCell(withIdentifier: "BranchCell", for: indexPath) + + // Configure the cell... + let branch = dataCenter.branches[indexPath.row] + cell.textLabel?.text = branch.name + + return cell + } + + + /* + // Override to support conditional editing of the table view. + override func tableView(_ tableView: UITableView, canEditRowAt indexPath: IndexPath) -> Bool { + // Return false if you do not want the specified item to be editable. + return true + } + */ + + /* + // Override to support editing the table view. + override func tableView(_ tableView: UITableView, commit editingStyle: UITableViewCellEditingStyle, forRowAt indexPath: IndexPath) { + if editingStyle == .delete { + // Delete the row from the data source + tableView.deleteRows(at: [indexPath], with: .fade) + } else if editingStyle == .insert { + // Create a new instance of the appropriate class, insert it into the array, and add a new row to the table view + } + } + */ + + /* + // Override to support rearranging the table view. + override func tableView(_ tableView: UITableView, moveRowAt fromIndexPath: IndexPath, to: IndexPath) { + + } + */ + + /* + // Override to support conditional rearranging of the table view. + override func tableView(_ tableView: UITableView, canMoveRowAt indexPath: IndexPath) -> Bool { + // Return false if you do not want the item to be re-orderable. + return true + } + */ + + + // MARK: - Navigation + + // In a storyboard-based application, you will often want to do a little preparation before navigation + override func prepare(for segue: UIStoryboardSegue, sender: Any?) { + // Get the new view controller using segue.destinationViewController. + // Pass the selected object to the new view controller. + + if segue.identifier == "ServiceSegue" { + if let destination = segue.destination as? ServiceListViewController { + if let selectedIndex = self.tableView.indexPathForSelectedRow?.row { + destination.branch = dataCenter.branches[selectedIndex] as Branch + } + } + } + + } +} diff --git "a/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/meetingRooms_unwind/meetingRooms/DataCenter.swift" "b/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/meetingRooms_unwind/meetingRooms/DataCenter.swift" new file mode 100644 index 0000000..7476872 --- /dev/null +++ "b/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/meetingRooms_unwind/meetingRooms/DataCenter.swift" @@ -0,0 +1,84 @@ +// +// DataCenter.swift +// meetingRooms +// +// Created by 황도증 on 2017. 11. 9.. +// Copyright © 2017년 황도증. All rights reserved. +// + +import Foundation + +let dataCenter:DataCenter = DataCenter() + +class DataCenter { + var branches:[Branch] = [] + + init (){ + let banksyRoom = MeetingRoom(name:"Banksy", capacity: 4) + let kahloRoom = MeetingRoom(name:"Kahlo", capacity: 8) + let riveraRoom = MeetingRoom(name:"Rivera", capacity: 8) + let picasoRoom = MeetingRoom(name:"Picaso", capacity: 10) + + let vehicleService = Service(name: "차량예약") + let meetingRoomService = Service(name: "회의실예약") + let visitorService = Service(name: "방문자예약") + let deskService = Service(name: "데스크예약") + meetingRoomService.items = [banksyRoom, kahloRoom, riveraRoom, picasoRoom] + + let pangyoBranch = Branch(name: "판교점") + let samsungBranch = Branch(name: "삼성점") + let yeoksamBranch = Branch(name: "역삼점") + let sinrimBranch = Branch(name: "신림점") + let songdooBranch = Branch(name: "송도점") + let anamBranch = Branch(name: "안암점") + pangyoBranch.services = [vehicleService, meetingRoomService, visitorService, deskService] + + branches += [pangyoBranch, samsungBranch, yeoksamBranch, sinrimBranch, songdooBranch, anamBranch] + } +} + +class Branch { + let name:String + var services:[Service]? + + init(name:String) { + self.name = name + } +} + +class Service { + let name:String + var items:[MeetingRoom]? + + init(name:String) { + self.name = name + } +} + +class MeetingRoom { + let name:String + let capacity:Int + var reservations:[Reservation]? + + init(name:String, capacity:Int) { + self.name = name + self.capacity = capacity + } +} + +class Reservation { + var hostName:String + var date:NSDate + var attendees:Int + var equipments:[String] + var catering:Bool + + init() { + self.hostName = "host of meeting" + self.date = NSDate() + self.attendees = 1 + self.equipments = [] + self.catering = false + } + +} diff --git "a/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/meetingRooms_unwind/meetingRooms/Info.plist" "b/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/meetingRooms_unwind/meetingRooms/Info.plist" new file mode 100644 index 0000000..16be3b6 --- /dev/null +++ "b/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/meetingRooms_unwind/meetingRooms/Info.plist" @@ -0,0 +1,45 @@ + + + + + CFBundleDevelopmentRegion + $(DEVELOPMENT_LANGUAGE) + CFBundleExecutable + $(EXECUTABLE_NAME) + CFBundleIdentifier + $(PRODUCT_BUNDLE_IDENTIFIER) + CFBundleInfoDictionaryVersion + 6.0 + CFBundleName + $(PRODUCT_NAME) + CFBundlePackageType + APPL + CFBundleShortVersionString + 1.0 + CFBundleVersion + 1 + LSRequiresIPhoneOS + + UILaunchStoryboardName + LaunchScreen + UIMainStoryboardFile + Main + UIRequiredDeviceCapabilities + + armv7 + + UISupportedInterfaceOrientations + + UIInterfaceOrientationPortrait + UIInterfaceOrientationLandscapeLeft + UIInterfaceOrientationLandscapeRight + + UISupportedInterfaceOrientations~ipad + + UIInterfaceOrientationPortrait + UIInterfaceOrientationPortraitUpsideDown + UIInterfaceOrientationLandscapeLeft + UIInterfaceOrientationLandscapeRight + + + diff --git "a/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/meetingRooms_unwind/meetingRooms/MeetingRoomListViewController.swift" "b/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/meetingRooms_unwind/meetingRooms/MeetingRoomListViewController.swift" new file mode 100644 index 0000000..b56d5ae --- /dev/null +++ "b/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/meetingRooms_unwind/meetingRooms/MeetingRoomListViewController.swift" @@ -0,0 +1,117 @@ +// +// MeetingRoomListViewController.swift +// meetingRooms +// +// Created by 황도증 on 2017. 10. 30.. +// Copyright © 2017년 황도증. All rights reserved. +// + +import UIKit + +class MeetingRoomListViewController: UITableViewController { + + var service:Service? + + override func viewDidLoad() { + super.viewDidLoad() + + // Uncomment the following line to preserve selection between presentations + // self.clearsSelectionOnViewWillAppear = false + + // Uncomment the following line to display an Edit button in the navigation bar for this view controller. + // self.navigationItem.rightBarButtonItem = self.editButtonItem + + self.title = service?.name + } + + override func didReceiveMemoryWarning() { + super.didReceiveMemoryWarning() + // Dispose of any resources that can be recreated. + } + + // MARK: - Table view data source + + override func numberOfSections(in tableView: UITableView) -> Int { + // #warning Incomplete implementation, return the number of sections + return 1 + } + + override func tableView(_ tableView: UITableView, numberOfRowsInSection section: Int) -> Int { + // #warning Incomplete implementation, return the number of rows + //let categoryValues = Array(meetingRooms.values)[section] + //let orderMeetingRoooms = meetingRooms.sorted(by: {$0.1.first!.1 < $1.1.first!.1}) + guard let rowCount = service?.items?.count else { + return 0 + } + return rowCount + } + + + override func tableView(_ tableView: UITableView, cellForRowAt indexPath: IndexPath) -> UITableViewCell { + let cell = tableView.dequeueReusableCell(withIdentifier: "ItemCell", for: indexPath) + + //let orderMeetingRoooms = meetingRooms.sorted(by: {$0.1.first!.1 < $1.1.first!.1}) + // Configure the cell... + //let categoryValue = Array(meetingRooms.values)[indexPath.section] + + guard let meetingRoom = service?.items?[indexPath.row] else { + return cell + } + + cell.textLabel!.text = meetingRoom.name + cell.detailTextLabel!.text = String(meetingRoom.capacity) + return cell + } + + /* + // Override to support conditional editing of the table view. + override func tableView(_ tableView: UITableView, canEditRowAt indexPath: IndexPath) -> Bool { + // Return false if you do not want the specified item to be editable. + return true + } + */ + + /* + // Override to support editing the table view. + override func tableView(_ tableView: UITableView, commit editingStyle: UITableViewCellEditingStyle, forRowAt indexPath: IndexPath) { + if editingStyle == .delete { + // Delete the row from the data source + tableView.deleteRows(at: [indexPath], with: .fade) + } else if editingStyle == .insert { + // Create a new instance of the appropriate class, insert it into the array, and add a new row to the table view + } + } + */ + + /* + // Override to support rearranging the table view. + override func tableView(_ tableView: UITableView, moveRowAt fromIndexPath: IndexPath, to: IndexPath) { + + } + */ + + /* + // Override to support conditional rearranging of the table view. + override func tableView(_ tableView: UITableView, canMoveRowAt indexPath: IndexPath) -> Bool { + // Return false if you do not want the item to be re-orderable. + return true + } + */ + + + // MARK: - Navigation + + // In a storyboard-based application, you will often want to do a little preparation before navigation + override func prepare(for segue: UIStoryboardSegue, sender: Any?) { + // Get the new view controller using segue.destinationViewController. + // Pass the selected object to the new view controller. + if segue.identifier == "ReservationSegue" { + guard let destination = segue.destination as? ReservationListViewController, let selectedIndex = self.tableView.indexPathForSelectedRow?.row, let meetingRoom = service?.items?[selectedIndex] else { + return + } + destination.meetingRoom = meetingRoom + } + + } + +} diff --git "a/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/meetingRooms_unwind/meetingRooms/ReservationListViewController.swift" "b/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/meetingRooms_unwind/meetingRooms/ReservationListViewController.swift" new file mode 100644 index 0000000..7da14de --- /dev/null +++ "b/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/meetingRooms_unwind/meetingRooms/ReservationListViewController.swift" @@ -0,0 +1,119 @@ +// +// ReservationListViewController.swift +// meetingRooms +// +// Created by 황도증 on 2017. 11. 9.. +// Copyright © 2017년 황도증. All rights reserved. +// + +import UIKit + +class ReservationListViewController: UITableViewController { + + var meetingRoom:MeetingRoom? + var newReservation:Reservation? + + override func viewDidLoad() { + super.viewDidLoad() + + // Uncomment the following line to preserve selection between presentations + // self.clearsSelectionOnViewWillAppear = false + + // Uncomment the following line to display an Edit button in the navigation bar for this view controller. + // self.navigationItem.rightBarButtonItem = self.editButtonItem + } + + override func didReceiveMemoryWarning() { + super.didReceiveMemoryWarning() + // Dispose of any resources that can be recreated. + } + + func addNewItem(reservation:Reservation) { + if (self.meetingRoom?.reservations?.append(reservation)) == nil { + self.meetingRoom?.reservations = [reservation] + } + self.tableView.reloadData() + } + + @IBAction func unwindToReservationList(segue:UIStoryboardSegue) { + + } + + + // MARK: - Table view data source + + override func numberOfSections(in tableView: UITableView) -> Int { + // #warning Incomplete implementation, return the number of sections + return 1 + } + + override func tableView(_ tableView: UITableView, numberOfRowsInSection section: Int) -> Int { + // #warning Incomplete implementation, return the number of rows + guard let rowCount = meetingRoom?.reservations?.count else { + return 0 + } + return rowCount + } + + + override func tableView(_ tableView: UITableView, cellForRowAt indexPath: IndexPath) -> UITableViewCell { + let cell = tableView.dequeueReusableCell(withIdentifier: "ReservationCell", for: indexPath) + + // Configure the cell... + guard let reservation = meetingRoom?.reservations?[indexPath.row] else { + return cell + } + + cell.textLabel?.text = reservation.date.description + cell.detailTextLabel?.text = reservation.hostName + + return cell + } + + + /* + // Override to support conditional editing of the table view. + override func tableView(_ tableView: UITableView, canEditRowAt indexPath: IndexPath) -> Bool { + // Return false if you do not want the specified item to be editable. + return true + } + */ + + /* + // Override to support editing the table view. + override func tableView(_ tableView: UITableView, commit editingStyle: UITableViewCellEditingStyle, forRowAt indexPath: IndexPath) { + if editingStyle == .delete { + // Delete the row from the data source + tableView.deleteRows(at: [indexPath], with: .fade) + } else if editingStyle == .insert { + // Create a new instance of the appropriate class, insert it into the array, and add a new row to the table view + } + } + */ + + /* + // Override to support rearranging the table view. + override func tableView(_ tableView: UITableView, moveRowAt fromIndexPath: IndexPath, to: IndexPath) { + + } + */ + + /* + // Override to support conditional rearranging of the table view. + override func tableView(_ tableView: UITableView, canMoveRowAt indexPath: IndexPath) -> Bool { + // Return false if you do not want the item to be re-orderable. + return true + } + */ + + /* + // MARK: - Navigation + + // In a storyboard-based application, you will often want to do a little preparation before navigation + override func prepare(for segue: UIStoryboardSegue, sender: Any?) { + // Get the new view controller using segue.destinationViewController. + // Pass the selected object to the new view controller. + } + */ + +} diff --git "a/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/meetingRooms_unwind/meetingRooms/ReserveRoomViewController.swift" "b/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/meetingRooms_unwind/meetingRooms/ReserveRoomViewController.swift" new file mode 100644 index 0000000..b976043 --- /dev/null +++ "b/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/meetingRooms_unwind/meetingRooms/ReserveRoomViewController.swift" @@ -0,0 +1,154 @@ +// +// ReserveRoomViewController.swift +// meetingRooms +// +// Created by 황도증 on 2017. 11. 9.. +// Copyright © 2017년 황도증. All rights reserved. +// + +import UIKit + +class ReserveRoomViewController: UITableViewController { + + @IBOutlet weak var hostNameField: UITextField! + @IBOutlet weak var datePicker: UIDatePicker! + @IBOutlet weak var attendeesField: UITextField! + @IBOutlet weak var equipmentField: UITextField! + @IBOutlet weak var cateringSwitch: UISwitch! + + + override func viewDidLoad() { + super.viewDidLoad() + + // Uncomment the following line to preserve selection between presentations + // self.clearsSelectionOnViewWillAppear = false + + // Uncomment the following line to display an Edit button in the navigation bar for this view controller. + // self.navigationItem.rightBarButtonItem = self.editButtonItem + } + + override func didReceiveMemoryWarning() { + super.didReceiveMemoryWarning() + // Dispose of any resources that can be recreated. + } + + func newReservation() -> Reservation? { + let reservation = Reservation() + let host = hostNameField.text + + if (host?.isEmpty)! { + return nil + } + reservation.hostName = host! + reservation.date = datePicker.date as NSDate + + if let equipmentArray = equipmentField.text?.split(separator: ",").map(String.init) { + reservation.equipments = equipmentArray + } + reservation.catering = cateringSwitch.isOn + return reservation + } + + @IBAction func cancelReservation(_ sender: Any) { + self.dismiss(animated: true, completion: nil) + } + + @IBAction func makeReservation(_ sender: Any) { + guard let reservation = newReservation() else { + self.dismiss(animated: true, completion: nil) + return + } + + switch self.presentingViewController { + case let tapbarC as UITabBarController: + if let navigationC = tapbarC.selectedViewController as? UINavigationController, let reservationListVC = navigationC.topViewController as? ReservationListViewController { + reservationListVC.addNewItem(reservation: reservation) + } + case let navigationC as UINavigationController: + if let reservationListVC = navigationC.topViewController as? ReservationListViewController { + reservationListVC.addNewItem(reservation: reservation) + } + case let reservationListVC as ReservationListViewController: + reservationListVC.addNewItem(reservation: reservation) + default: + break + } + + self.dismiss(animated: true, completion: nil) + } + + + // MARK: - Table view data source +/* + override func numberOfSections(in tableView: UITableView) -> Int { + // #warning Incomplete implementation, return the number of sections + return 0 + } + + override func tableView(_ tableView: UITableView, numberOfRowsInSection section: Int) -> Int { + // #warning Incomplete implementation, return the number of rows + return 0 + } +*/ + /* + override func tableView(_ tableView: UITableView, cellForRowAt indexPath: IndexPath) -> UITableViewCell { + let cell = tableView.dequeueReusableCell(withIdentifier: "reuseIdentifier", for: indexPath) + + // Configure the cell... + + return cell + } + */ + + /* + // Override to support conditional editing of the table view. + override func tableView(_ tableView: UITableView, canEditRowAt indexPath: IndexPath) -> Bool { + // Return false if you do not want the specified item to be editable. + return true + } + */ + + /* + // Override to support editing the table view. + override func tableView(_ tableView: UITableView, commit editingStyle: UITableViewCellEditingStyle, forRowAt indexPath: IndexPath) { + if editingStyle == .delete { + // Delete the row from the data source + tableView.deleteRows(at: [indexPath], with: .fade) + } else if editingStyle == .insert { + // Create a new instance of the appropriate class, insert it into the array, and add a new row to the table view + } + } + */ + + /* + // Override to support rearranging the table view. + override func tableView(_ tableView: UITableView, moveRowAt fromIndexPath: IndexPath, to: IndexPath) { + + } + */ + + /* + // Override to support conditional rearranging of the table view. + override func tableView(_ tableView: UITableView, canMoveRowAt indexPath: IndexPath) -> Bool { + // Return false if you do not want the item to be re-orderable. + return true + } + */ + + + // MARK: - Navigation + + // In a storyboard-based application, you will often want to do a little preparation before navigation + override func prepare(for segue: UIStoryboardSegue, sender: Any?) { + // Get the new view controller using segue.destinationViewController. + // Pass the selected object to the new view controller. + if segue.identifier == "ReserveDone" { + guard let reservation = newReservation(), let reservationListVC = segue.destination as? ReservationListViewController else { + return + } + reservationListVC.addNewItem(reservation: reservation) + } + } + + +} diff --git "a/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/meetingRooms_unwind/meetingRooms/RoomInfoViewController.swift" "b/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/meetingRooms_unwind/meetingRooms/RoomInfoViewController.swift" new file mode 100644 index 0000000..61bf80d --- /dev/null +++ "b/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/meetingRooms_unwind/meetingRooms/RoomInfoViewController.swift" @@ -0,0 +1,98 @@ +// +// RoomInfoViewController.swift +// meetingRooms +// +// Created by 황도증 on 2017. 11. 9.. +// Copyright © 2017년 황도증. All rights reserved. +// + +import UIKit + +class RoomInfoViewController: UITableViewController { + + override func viewDidLoad() { + super.viewDidLoad() + + // Uncomment the following line to preserve selection between presentations + // self.clearsSelectionOnViewWillAppear = false + + // Uncomment the following line to display an Edit button in the navigation bar for this view controller. + // self.navigationItem.rightBarButtonItem = self.editButtonItem + } + + override func didReceiveMemoryWarning() { + super.didReceiveMemoryWarning() + // Dispose of any resources that can be recreated. + } + @IBAction func modalDismiss(_ sender: Any) { + self.dismiss(animated: true, completion: nil) + } + /* + // MARK: - Table view data source + + override func numberOfSections(in tableView: UITableView) -> Int { + // #warning Incomplete implementation, return the number of sections + return 0 + } + + override func tableView(_ tableView: UITableView, numberOfRowsInSection section: Int) -> Int { + // #warning Incomplete implementation, return the number of rows + return 0 + } +*/ + /* + override func tableView(_ tableView: UITableView, cellForRowAt indexPath: IndexPath) -> UITableViewCell { + let cell = tableView.dequeueReusableCell(withIdentifier: "reuseIdentifier", for: indexPath) + + // Configure the cell... + + return cell + } + */ + + /* + // Override to support conditional editing of the table view. + override func tableView(_ tableView: UITableView, canEditRowAt indexPath: IndexPath) -> Bool { + // Return false if you do not want the specified item to be editable. + return true + } + */ + + /* + // Override to support editing the table view. + override func tableView(_ tableView: UITableView, commit editingStyle: UITableViewCellEditingStyle, forRowAt indexPath: IndexPath) { + if editingStyle == .delete { + // Delete the row from the data source + tableView.deleteRows(at: [indexPath], with: .fade) + } else if editingStyle == .insert { + // Create a new instance of the appropriate class, insert it into the array, and add a new row to the table view + } + } + */ + + /* + // Override to support rearranging the table view. + override func tableView(_ tableView: UITableView, moveRowAt fromIndexPath: IndexPath, to: IndexPath) { + + } + */ + + /* + // Override to support conditional rearranging of the table view. + override func tableView(_ tableView: UITableView, canMoveRowAt indexPath: IndexPath) -> Bool { + // Return false if you do not want the item to be re-orderable. + return true + } + */ + + /* + // MARK: - Navigation + + // In a storyboard-based application, you will often want to do a little preparation before navigation + override func prepare(for segue: UIStoryboardSegue, sender: Any?) { + // Get the new view controller using segue.destinationViewController. + // Pass the selected object to the new view controller. + } + */ + +} diff --git "a/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/meetingRooms_unwind/meetingRooms/ServiceListViewController.swift" "b/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/meetingRooms_unwind/meetingRooms/ServiceListViewController.swift" new file mode 100644 index 0000000..091d906 --- /dev/null +++ "b/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/meetingRooms_unwind/meetingRooms/ServiceListViewController.swift" @@ -0,0 +1,113 @@ +// +// ServiceListViewController.swift +// meetingRooms +// +// Created by 황도증 on 2017. 11. 9.. +// Copyright © 2017년 황도증. All rights reserved. +// + +import UIKit + +class ServiceListViewController: UITableViewController { + + var branch:Branch? + + override func viewDidLoad() { + super.viewDidLoad() + + // Uncomment the following line to preserve selection between presentations + // self.clearsSelectionOnViewWillAppear = false + + // Uncomment the following line to display an Edit button in the navigation bar for this view controller. + // self.navigationItem.rightBarButtonItem = self.editButtonItem + self.title = branch?.name + self.navigationController?.isToolbarHidden = false + } + + override func didReceiveMemoryWarning() { + super.didReceiveMemoryWarning() + // Dispose of any resources that can be recreated. + } + + // MARK: - Table view data source + + override func numberOfSections(in tableView: UITableView) -> Int { + // #warning Incomplete implementation, return the number of sections + return 1 + } + + override func tableView(_ tableView: UITableView, numberOfRowsInSection section: Int) -> Int { + // #warning Incomplete implementation, return the number of rows + guard let rowCount = branch?.services?.count else { + return 0 + } + return rowCount + } + + + override func tableView(_ tableView: UITableView, cellForRowAt indexPath: IndexPath) -> UITableViewCell { + let cell = tableView.dequeueReusableCell(withIdentifier: "ServiceCell", for: indexPath) + + // Configure the cell... + guard let service = branch?.services?[indexPath.row] else { + return cell + } + + cell.textLabel?.text = service.name + + return cell + } + + + /* + // Override to support conditional editing of the table view. + override func tableView(_ tableView: UITableView, canEditRowAt indexPath: IndexPath) -> Bool { + // Return false if you do not want the specified item to be editable. + return true + } + */ + + /* + // Override to support editing the table view. + override func tableView(_ tableView: UITableView, commit editingStyle: UITableViewCellEditingStyle, forRowAt indexPath: IndexPath) { + if editingStyle == .delete { + // Delete the row from the data source + tableView.deleteRows(at: [indexPath], with: .fade) + } else if editingStyle == .insert { + // Create a new instance of the appropriate class, insert it into the array, and add a new row to the table view + } + } + */ + + /* + // Override to support rearranging the table view. + override func tableView(_ tableView: UITableView, moveRowAt fromIndexPath: IndexPath, to: IndexPath) { + + } + */ + + /* + // Override to support conditional rearranging of the table view. + override func tableView(_ tableView: UITableView, canMoveRowAt indexPath: IndexPath) -> Bool { + // Return false if you do not want the item to be re-orderable. + return true + } + */ + + + // MARK: - Navigation + + // In a storyboard-based application, you will often want to do a little preparation before navigation + override func prepare(for segue: UIStoryboardSegue, sender: Any?) { + // Get the new view controller using segue.destinationViewController. + // Pass the selected object to the new view controller. + if segue.identifier == "MeetingRoomSegue" { + guard let destination = segue.destination as? MeetingRoomListViewController, let selectedIndex = self.tableView.indexPathForSelectedRow?.row, let service = branch?.services?[selectedIndex] else { + return + } + destination.service = service + } + } + + +} diff --git "a/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/meetingRooms_unwind/meetingRooms/ViewController.swift" "b/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/meetingRooms_unwind/meetingRooms/ViewController.swift" new file mode 100644 index 0000000..24bd9b0 --- /dev/null +++ "b/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/meetingRooms_unwind/meetingRooms/ViewController.swift" @@ -0,0 +1,25 @@ +// +// ViewController.swift +// meetingRooms +// +// Created by 황도증 on 2017. 10. 30.. +// Copyright © 2017년 황도증. All rights reserved. +// + +import UIKit + +class ViewController: UIViewController { + + override func viewDidLoad() { + super.viewDidLoad() + // Do any additional setup after loading the view, typically from a nib. + } + + override func didReceiveMemoryWarning() { + super.didReceiveMemoryWarning() + // Dispose of any resources that can be recreated. + } + + +} + diff --git "a/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/meetingRooms_unwind/meetingRoomsTests/Info.plist" "b/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/meetingRooms_unwind/meetingRoomsTests/Info.plist" new file mode 100644 index 0000000..6c40a6c --- /dev/null +++ "b/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/meetingRooms_unwind/meetingRoomsTests/Info.plist" @@ -0,0 +1,22 @@ + + + + + CFBundleDevelopmentRegion + $(DEVELOPMENT_LANGUAGE) + CFBundleExecutable + $(EXECUTABLE_NAME) + CFBundleIdentifier + $(PRODUCT_BUNDLE_IDENTIFIER) + CFBundleInfoDictionaryVersion + 6.0 + CFBundleName + $(PRODUCT_NAME) + CFBundlePackageType + BNDL + CFBundleShortVersionString + 1.0 + CFBundleVersion + 1 + + diff --git "a/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/meetingRooms_unwind/meetingRoomsTests/meetingRoomsTests.swift" "b/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/meetingRooms_unwind/meetingRoomsTests/meetingRoomsTests.swift" new file mode 100644 index 0000000..bfbd8d6 --- /dev/null +++ "b/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/meetingRooms_unwind/meetingRoomsTests/meetingRoomsTests.swift" @@ -0,0 +1,36 @@ +// +// meetingRoomsTests.swift +// meetingRoomsTests +// +// Created by 황도증 on 2017. 10. 30.. +// Copyright © 2017년 황도증. All rights reserved. +// + +import XCTest +@testable import meetingRooms + +class meetingRoomsTests: XCTestCase { + + override func setUp() { + super.setUp() + // Put setup code here. This method is called before the invocation of each test method in the class. + } + + override func tearDown() { + // Put teardown code here. This method is called after the invocation of each test method in the class. + super.tearDown() + } + + func testExample() { + // This is an example of a functional test case. + // Use XCTAssert and related functions to verify your tests produce the correct results. + } + + func testPerformanceExample() { + // This is an example of a performance test case. + self.measure { + // Put the code you want to measure the time of here. + } + } + +} diff --git "a/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/meetingRooms_unwind/meetingRoomsUITests/Info.plist" "b/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/meetingRooms_unwind/meetingRoomsUITests/Info.plist" new file mode 100644 index 0000000..6c40a6c --- /dev/null +++ "b/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/meetingRooms_unwind/meetingRoomsUITests/Info.plist" @@ -0,0 +1,22 @@ + + + + + CFBundleDevelopmentRegion + $(DEVELOPMENT_LANGUAGE) + CFBundleExecutable + $(EXECUTABLE_NAME) + CFBundleIdentifier + $(PRODUCT_BUNDLE_IDENTIFIER) + CFBundleInfoDictionaryVersion + 6.0 + CFBundleName + $(PRODUCT_NAME) + CFBundlePackageType + BNDL + CFBundleShortVersionString + 1.0 + CFBundleVersion + 1 + + diff --git "a/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/meetingRooms_unwind/meetingRoomsUITests/meetingRoomsUITests.swift" "b/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/meetingRooms_unwind/meetingRoomsUITests/meetingRoomsUITests.swift" new file mode 100644 index 0000000..4873bfa --- /dev/null +++ "b/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/meetingRooms_unwind/meetingRoomsUITests/meetingRoomsUITests.swift" @@ -0,0 +1,36 @@ +// +// meetingRoomsUITests.swift +// meetingRoomsUITests +// +// Created by 황도증 on 2017. 10. 30.. +// Copyright © 2017년 황도증. All rights reserved. +// + +import XCTest + +class meetingRoomsUITests: XCTestCase { + + override func setUp() { + super.setUp() + + // Put setup code here. This method is called before the invocation of each test method in the class. + + // In UI tests it is usually best to stop immediately when a failure occurs. + continueAfterFailure = false + // UI tests must launch the application that they test. Doing this in setup will make sure it happens for each test method. + XCUIApplication().launch() + + // In UI tests it’s important to set the initial state - such as interface orientation - required for your tests before they run. The setUp method is a good place to do this. + } + + override func tearDown() { + // Put teardown code here. This method is called after the invocation of each test method in the class. + super.tearDown() + } + + func testExample() { + // Use recording to get started writing UI tests. + // Use XCTAssert and related functions to verify your tests produce the correct results. + } + +} diff --git "a/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/meetingRooms_userdfault/meetingRooms.xcodeproj/project.pbxproj" "b/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/meetingRooms_userdfault/meetingRooms.xcodeproj/project.pbxproj" new file mode 100644 index 0000000..87b3966 --- /dev/null +++ "b/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/meetingRooms_userdfault/meetingRooms.xcodeproj/project.pbxproj" @@ -0,0 +1,589 @@ +// !$*UTF8*$! +{ + archiveVersion = 1; + classes = { + }; + objectVersion = 48; + objects = { + +/* Begin PBXBuildFile section */ + AE99575B1FA704AF00397D38 /* AppDelegate.swift in Sources */ = {isa = PBXBuildFile; fileRef = AE99575A1FA704AF00397D38 /* AppDelegate.swift */; }; + AE99575D1FA704AF00397D38 /* ViewController.swift in Sources */ = {isa = PBXBuildFile; fileRef = AE99575C1FA704AF00397D38 /* ViewController.swift */; }; + AE9957601FA704AF00397D38 /* Main.storyboard in Resources */ = {isa = PBXBuildFile; fileRef = AE99575E1FA704AF00397D38 /* Main.storyboard */; }; + AE9957621FA704AF00397D38 /* Assets.xcassets in Resources */ = {isa = PBXBuildFile; fileRef = AE9957611FA704AF00397D38 /* Assets.xcassets */; }; + AE9957651FA704AF00397D38 /* LaunchScreen.storyboard in Resources */ = {isa = PBXBuildFile; fileRef = AE9957631FA704AF00397D38 /* LaunchScreen.storyboard */; }; + AE9957701FA704AF00397D38 /* meetingRoomsTests.swift in Sources */ = {isa = PBXBuildFile; fileRef = AE99576F1FA704AF00397D38 /* meetingRoomsTests.swift */; }; + AE99577B1FA704B000397D38 /* meetingRoomsUITests.swift in Sources */ = {isa = PBXBuildFile; fileRef = AE99577A1FA704B000397D38 /* meetingRoomsUITests.swift */; }; + AE9957891FA7054800397D38 /* MeetingRoomListViewController.swift in Sources */ = {isa = PBXBuildFile; fileRef = AE9957881FA7054800397D38 /* MeetingRoomListViewController.swift */; }; + AEB3189D1FB4641000AEB094 /* DataCenter.swift in Sources */ = {isa = PBXBuildFile; fileRef = AEB3189C1FB4641000AEB094 /* DataCenter.swift */; }; + AEB3189F1FB4684600AEB094 /* BranchListViewController.swift in Sources */ = {isa = PBXBuildFile; fileRef = AEB3189E1FB4684600AEB094 /* BranchListViewController.swift */; }; + AEB318A11FB4685800AEB094 /* ServiceListViewController.swift in Sources */ = {isa = PBXBuildFile; fileRef = AEB318A01FB4685800AEB094 /* ServiceListViewController.swift */; }; + AEB318A31FB4807F00AEB094 /* RoomInfoViewController.swift in Sources */ = {isa = PBXBuildFile; fileRef = AEB318A21FB4807F00AEB094 /* RoomInfoViewController.swift */; }; + AEB318A51FB485D300AEB094 /* ReservationListViewController.swift in Sources */ = {isa = PBXBuildFile; fileRef = AEB318A41FB485D300AEB094 /* ReservationListViewController.swift */; }; + AEB318A71FB4861600AEB094 /* ReserveRoomViewController.swift in Sources */ = {isa = PBXBuildFile; fileRef = AEB318A61FB4861600AEB094 /* ReserveRoomViewController.swift */; }; + AEB318A91FB4975F00AEB094 /* TintColorViewController.swift in Sources */ = {isa = PBXBuildFile; fileRef = AEB318A81FB4975F00AEB094 /* TintColorViewController.swift */; }; +/* End PBXBuildFile section */ + +/* Begin PBXContainerItemProxy section */ + AE99576C1FA704AF00397D38 /* PBXContainerItemProxy */ = { + isa = PBXContainerItemProxy; + containerPortal = AE99574F1FA704AF00397D38 /* Project object */; + proxyType = 1; + remoteGlobalIDString = AE9957561FA704AF00397D38; + remoteInfo = meetingRooms; + }; + AE9957771FA704B000397D38 /* PBXContainerItemProxy */ = { + isa = PBXContainerItemProxy; + containerPortal = AE99574F1FA704AF00397D38 /* Project object */; + proxyType = 1; + remoteGlobalIDString = AE9957561FA704AF00397D38; + remoteInfo = meetingRooms; + }; +/* End PBXContainerItemProxy section */ + +/* Begin PBXFileReference section */ + AE9957571FA704AF00397D38 /* meetingRooms.app */ = {isa = PBXFileReference; explicitFileType = wrapper.application; includeInIndex = 0; path = meetingRooms.app; sourceTree = BUILT_PRODUCTS_DIR; }; + AE99575A1FA704AF00397D38 /* AppDelegate.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = AppDelegate.swift; sourceTree = ""; }; + AE99575C1FA704AF00397D38 /* ViewController.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = ViewController.swift; sourceTree = ""; }; + AE99575F1FA704AF00397D38 /* Base */ = {isa = PBXFileReference; lastKnownFileType = file.storyboard; name = Base; path = Base.lproj/Main.storyboard; sourceTree = ""; }; + AE9957611FA704AF00397D38 /* Assets.xcassets */ = {isa = PBXFileReference; lastKnownFileType = folder.assetcatalog; path = Assets.xcassets; sourceTree = ""; }; + AE9957641FA704AF00397D38 /* Base */ = {isa = PBXFileReference; lastKnownFileType = file.storyboard; name = Base; path = Base.lproj/LaunchScreen.storyboard; sourceTree = ""; }; + AE9957661FA704AF00397D38 /* Info.plist */ = {isa = PBXFileReference; lastKnownFileType = text.plist.xml; path = Info.plist; sourceTree = ""; }; + AE99576B1FA704AF00397D38 /* meetingRoomsTests.xctest */ = {isa = PBXFileReference; explicitFileType = wrapper.cfbundle; includeInIndex = 0; path = meetingRoomsTests.xctest; sourceTree = BUILT_PRODUCTS_DIR; }; + AE99576F1FA704AF00397D38 /* meetingRoomsTests.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = meetingRoomsTests.swift; sourceTree = ""; }; + AE9957711FA704AF00397D38 /* Info.plist */ = {isa = PBXFileReference; lastKnownFileType = text.plist.xml; path = Info.plist; sourceTree = ""; }; + AE9957761FA704B000397D38 /* meetingRoomsUITests.xctest */ = {isa = PBXFileReference; explicitFileType = wrapper.cfbundle; includeInIndex = 0; path = meetingRoomsUITests.xctest; sourceTree = BUILT_PRODUCTS_DIR; }; + AE99577A1FA704B000397D38 /* meetingRoomsUITests.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = meetingRoomsUITests.swift; sourceTree = ""; }; + AE99577C1FA704B000397D38 /* Info.plist */ = {isa = PBXFileReference; lastKnownFileType = text.plist.xml; path = Info.plist; sourceTree = ""; }; + AE9957881FA7054800397D38 /* MeetingRoomListViewController.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = MeetingRoomListViewController.swift; sourceTree = ""; }; + AEB3189C1FB4641000AEB094 /* DataCenter.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = DataCenter.swift; sourceTree = ""; }; + AEB3189E1FB4684600AEB094 /* BranchListViewController.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = BranchListViewController.swift; sourceTree = ""; }; + AEB318A01FB4685800AEB094 /* ServiceListViewController.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = ServiceListViewController.swift; sourceTree = ""; }; + AEB318A21FB4807F00AEB094 /* RoomInfoViewController.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = RoomInfoViewController.swift; sourceTree = ""; }; + AEB318A41FB485D300AEB094 /* ReservationListViewController.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = ReservationListViewController.swift; sourceTree = ""; }; + AEB318A61FB4861600AEB094 /* ReserveRoomViewController.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = ReserveRoomViewController.swift; sourceTree = ""; }; + AEB318A81FB4975F00AEB094 /* TintColorViewController.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = TintColorViewController.swift; sourceTree = ""; }; +/* End PBXFileReference section */ + +/* Begin PBXFrameworksBuildPhase section */ + AE9957541FA704AF00397D38 /* Frameworks */ = { + isa = PBXFrameworksBuildPhase; + buildActionMask = 2147483647; + files = ( + ); + runOnlyForDeploymentPostprocessing = 0; + }; + AE9957681FA704AF00397D38 /* Frameworks */ = { + isa = PBXFrameworksBuildPhase; + buildActionMask = 2147483647; + files = ( + ); + runOnlyForDeploymentPostprocessing = 0; + }; + AE9957731FA704B000397D38 /* Frameworks */ = { + isa = PBXFrameworksBuildPhase; + buildActionMask = 2147483647; + files = ( + ); + runOnlyForDeploymentPostprocessing = 0; + }; +/* End PBXFrameworksBuildPhase section */ + +/* Begin PBXGroup section */ + AE99574E1FA704AF00397D38 = { + isa = PBXGroup; + children = ( + AE9957591FA704AF00397D38 /* meetingRooms */, + AE99576E1FA704AF00397D38 /* meetingRoomsTests */, + AE9957791FA704B000397D38 /* meetingRoomsUITests */, + AE9957581FA704AF00397D38 /* Products */, + ); + sourceTree = ""; + }; + AE9957581FA704AF00397D38 /* Products */ = { + isa = PBXGroup; + children = ( + AE9957571FA704AF00397D38 /* meetingRooms.app */, + AE99576B1FA704AF00397D38 /* meetingRoomsTests.xctest */, + AE9957761FA704B000397D38 /* meetingRoomsUITests.xctest */, + ); + name = Products; + sourceTree = ""; + }; + AE9957591FA704AF00397D38 /* meetingRooms */ = { + isa = PBXGroup; + children = ( + AE99575A1FA704AF00397D38 /* AppDelegate.swift */, + AE99575C1FA704AF00397D38 /* ViewController.swift */, + AE99575E1FA704AF00397D38 /* Main.storyboard */, + AEB318A81FB4975F00AEB094 /* TintColorViewController.swift */, + AEB318A61FB4861600AEB094 /* ReserveRoomViewController.swift */, + AEB318A41FB485D300AEB094 /* ReservationListViewController.swift */, + AEB318A21FB4807F00AEB094 /* RoomInfoViewController.swift */, + AEB3189C1FB4641000AEB094 /* DataCenter.swift */, + AEB3189E1FB4684600AEB094 /* BranchListViewController.swift */, + AEB318A01FB4685800AEB094 /* ServiceListViewController.swift */, + AE9957881FA7054800397D38 /* MeetingRoomListViewController.swift */, + AE9957611FA704AF00397D38 /* Assets.xcassets */, + AE9957631FA704AF00397D38 /* LaunchScreen.storyboard */, + AE9957661FA704AF00397D38 /* Info.plist */, + ); + path = meetingRooms; + sourceTree = ""; + }; + AE99576E1FA704AF00397D38 /* meetingRoomsTests */ = { + isa = PBXGroup; + children = ( + AE99576F1FA704AF00397D38 /* meetingRoomsTests.swift */, + AE9957711FA704AF00397D38 /* Info.plist */, + ); + path = meetingRoomsTests; + sourceTree = ""; + }; + AE9957791FA704B000397D38 /* meetingRoomsUITests */ = { + isa = PBXGroup; + children = ( + AE99577A1FA704B000397D38 /* meetingRoomsUITests.swift */, + AE99577C1FA704B000397D38 /* Info.plist */, + ); + path = meetingRoomsUITests; + sourceTree = ""; + }; +/* End PBXGroup section */ + +/* Begin PBXNativeTarget section */ + AE9957561FA704AF00397D38 /* meetingRooms */ = { + isa = PBXNativeTarget; + buildConfigurationList = AE99577F1FA704B000397D38 /* Build configuration list for PBXNativeTarget "meetingRooms" */; + buildPhases = ( + AE9957531FA704AF00397D38 /* Sources */, + AE9957541FA704AF00397D38 /* Frameworks */, + AE9957551FA704AF00397D38 /* Resources */, + ); + buildRules = ( + ); + dependencies = ( + ); + name = meetingRooms; + productName = meetingRooms; + productReference = AE9957571FA704AF00397D38 /* meetingRooms.app */; + productType = "com.apple.product-type.application"; + }; + AE99576A1FA704AF00397D38 /* meetingRoomsTests */ = { + isa = PBXNativeTarget; + buildConfigurationList = AE9957821FA704B000397D38 /* Build configuration list for PBXNativeTarget "meetingRoomsTests" */; + buildPhases = ( + AE9957671FA704AF00397D38 /* Sources */, + AE9957681FA704AF00397D38 /* Frameworks */, + AE9957691FA704AF00397D38 /* Resources */, + ); + buildRules = ( + ); + dependencies = ( + AE99576D1FA704AF00397D38 /* PBXTargetDependency */, + ); + name = meetingRoomsTests; + productName = meetingRoomsTests; + productReference = AE99576B1FA704AF00397D38 /* meetingRoomsTests.xctest */; + productType = "com.apple.product-type.bundle.unit-test"; + }; + AE9957751FA704B000397D38 /* meetingRoomsUITests */ = { + isa = PBXNativeTarget; + buildConfigurationList = AE9957851FA704B000397D38 /* Build configuration list for PBXNativeTarget "meetingRoomsUITests" */; + buildPhases = ( + AE9957721FA704B000397D38 /* Sources */, + AE9957731FA704B000397D38 /* Frameworks */, + AE9957741FA704B000397D38 /* Resources */, + ); + buildRules = ( + ); + dependencies = ( + AE9957781FA704B000397D38 /* PBXTargetDependency */, + ); + name = meetingRoomsUITests; + productName = meetingRoomsUITests; + productReference = AE9957761FA704B000397D38 /* meetingRoomsUITests.xctest */; + productType = "com.apple.product-type.bundle.ui-testing"; + }; +/* End PBXNativeTarget section */ + +/* Begin PBXProject section */ + AE99574F1FA704AF00397D38 /* Project object */ = { + isa = PBXProject; + attributes = { + LastSwiftUpdateCheck = 0900; + LastUpgradeCheck = 0900; + ORGANIZATIONNAME = "황도증"; + TargetAttributes = { + AE9957561FA704AF00397D38 = { + CreatedOnToolsVersion = 9.0.1; + ProvisioningStyle = Automatic; + }; + AE99576A1FA704AF00397D38 = { + CreatedOnToolsVersion = 9.0.1; + ProvisioningStyle = Automatic; + TestTargetID = AE9957561FA704AF00397D38; + }; + AE9957751FA704B000397D38 = { + CreatedOnToolsVersion = 9.0.1; + ProvisioningStyle = Automatic; + TestTargetID = AE9957561FA704AF00397D38; + }; + }; + }; + buildConfigurationList = AE9957521FA704AF00397D38 /* Build configuration list for PBXProject "meetingRooms" */; + compatibilityVersion = "Xcode 8.0"; + developmentRegion = en; + hasScannedForEncodings = 0; + knownRegions = ( + en, + Base, + ); + mainGroup = AE99574E1FA704AF00397D38; + productRefGroup = AE9957581FA704AF00397D38 /* Products */; + projectDirPath = ""; + projectRoot = ""; + targets = ( + AE9957561FA704AF00397D38 /* meetingRooms */, + AE99576A1FA704AF00397D38 /* meetingRoomsTests */, + AE9957751FA704B000397D38 /* meetingRoomsUITests */, + ); + }; +/* End PBXProject section */ + +/* Begin PBXResourcesBuildPhase section */ + AE9957551FA704AF00397D38 /* Resources */ = { + isa = PBXResourcesBuildPhase; + buildActionMask = 2147483647; + files = ( + AE9957651FA704AF00397D38 /* LaunchScreen.storyboard in Resources */, + AE9957621FA704AF00397D38 /* Assets.xcassets in Resources */, + AE9957601FA704AF00397D38 /* Main.storyboard in Resources */, + ); + runOnlyForDeploymentPostprocessing = 0; + }; + AE9957691FA704AF00397D38 /* Resources */ = { + isa = PBXResourcesBuildPhase; + buildActionMask = 2147483647; + files = ( + ); + runOnlyForDeploymentPostprocessing = 0; + }; + AE9957741FA704B000397D38 /* Resources */ = { + isa = PBXResourcesBuildPhase; + buildActionMask = 2147483647; + files = ( + ); + runOnlyForDeploymentPostprocessing = 0; + }; +/* End PBXResourcesBuildPhase section */ + +/* Begin PBXSourcesBuildPhase section */ + AE9957531FA704AF00397D38 /* Sources */ = { + isa = PBXSourcesBuildPhase; + buildActionMask = 2147483647; + files = ( + AEB318A31FB4807F00AEB094 /* RoomInfoViewController.swift in Sources */, + AE99575D1FA704AF00397D38 /* ViewController.swift in Sources */, + AE99575B1FA704AF00397D38 /* AppDelegate.swift in Sources */, + AEB318A51FB485D300AEB094 /* ReservationListViewController.swift in Sources */, + AEB3189D1FB4641000AEB094 /* DataCenter.swift in Sources */, + AEB3189F1FB4684600AEB094 /* BranchListViewController.swift in Sources */, + AEB318A11FB4685800AEB094 /* ServiceListViewController.swift in Sources */, + AE9957891FA7054800397D38 /* MeetingRoomListViewController.swift in Sources */, + AEB318A71FB4861600AEB094 /* ReserveRoomViewController.swift in Sources */, + AEB318A91FB4975F00AEB094 /* TintColorViewController.swift in Sources */, + ); + runOnlyForDeploymentPostprocessing = 0; + }; + AE9957671FA704AF00397D38 /* Sources */ = { + isa = PBXSourcesBuildPhase; + buildActionMask = 2147483647; + files = ( + AE9957701FA704AF00397D38 /* meetingRoomsTests.swift in Sources */, + ); + runOnlyForDeploymentPostprocessing = 0; + }; + AE9957721FA704B000397D38 /* Sources */ = { + isa = PBXSourcesBuildPhase; + buildActionMask = 2147483647; + files = ( + AE99577B1FA704B000397D38 /* meetingRoomsUITests.swift in Sources */, + ); + runOnlyForDeploymentPostprocessing = 0; + }; +/* End PBXSourcesBuildPhase section */ + +/* Begin PBXTargetDependency section */ + AE99576D1FA704AF00397D38 /* PBXTargetDependency */ = { + isa = PBXTargetDependency; + target = AE9957561FA704AF00397D38 /* meetingRooms */; + targetProxy = AE99576C1FA704AF00397D38 /* PBXContainerItemProxy */; + }; + AE9957781FA704B000397D38 /* PBXTargetDependency */ = { + isa = PBXTargetDependency; + target = AE9957561FA704AF00397D38 /* meetingRooms */; + targetProxy = AE9957771FA704B000397D38 /* PBXContainerItemProxy */; + }; +/* End PBXTargetDependency section */ + +/* Begin PBXVariantGroup section */ + AE99575E1FA704AF00397D38 /* Main.storyboard */ = { + isa = PBXVariantGroup; + children = ( + AE99575F1FA704AF00397D38 /* Base */, + ); + name = Main.storyboard; + sourceTree = ""; + }; + AE9957631FA704AF00397D38 /* LaunchScreen.storyboard */ = { + isa = PBXVariantGroup; + children = ( + AE9957641FA704AF00397D38 /* Base */, + ); + name = LaunchScreen.storyboard; + sourceTree = ""; + }; +/* End PBXVariantGroup section */ + +/* Begin XCBuildConfiguration section */ + AE99577D1FA704B000397D38 /* Debug */ = { + isa = XCBuildConfiguration; + buildSettings = { + ALWAYS_SEARCH_USER_PATHS = NO; + CLANG_ANALYZER_NONNULL = YES; + CLANG_ANALYZER_NUMBER_OBJECT_CONVERSION = YES_AGGRESSIVE; + CLANG_CXX_LANGUAGE_STANDARD = "gnu++14"; + CLANG_CXX_LIBRARY = "libc++"; + CLANG_ENABLE_MODULES = YES; + CLANG_ENABLE_OBJC_ARC = YES; + CLANG_WARN_BLOCK_CAPTURE_AUTORELEASING = YES; + CLANG_WARN_BOOL_CONVERSION = YES; + CLANG_WARN_COMMA = YES; + CLANG_WARN_CONSTANT_CONVERSION = YES; + CLANG_WARN_DIRECT_OBJC_ISA_USAGE = YES_ERROR; + CLANG_WARN_DOCUMENTATION_COMMENTS = YES; + CLANG_WARN_EMPTY_BODY = YES; + CLANG_WARN_ENUM_CONVERSION = YES; + CLANG_WARN_INFINITE_RECURSION = YES; + CLANG_WARN_INT_CONVERSION = YES; + CLANG_WARN_NON_LITERAL_NULL_CONVERSION = YES; + CLANG_WARN_OBJC_LITERAL_CONVERSION = YES; + CLANG_WARN_OBJC_ROOT_CLASS = YES_ERROR; + CLANG_WARN_RANGE_LOOP_ANALYSIS = YES; + CLANG_WARN_STRICT_PROTOTYPES = YES; + CLANG_WARN_SUSPICIOUS_MOVE = YES; + CLANG_WARN_UNGUARDED_AVAILABILITY = YES_AGGRESSIVE; + CLANG_WARN_UNREACHABLE_CODE = YES; + CLANG_WARN__DUPLICATE_METHOD_MATCH = YES; + CODE_SIGN_IDENTITY = "iPhone Developer"; + COPY_PHASE_STRIP = NO; + DEBUG_INFORMATION_FORMAT = dwarf; + ENABLE_STRICT_OBJC_MSGSEND = YES; + ENABLE_TESTABILITY = YES; + GCC_C_LANGUAGE_STANDARD = gnu11; + GCC_DYNAMIC_NO_PIC = NO; + GCC_NO_COMMON_BLOCKS = YES; + GCC_OPTIMIZATION_LEVEL = 0; + GCC_PREPROCESSOR_DEFINITIONS = ( + "DEBUG=1", + "$(inherited)", + ); + GCC_WARN_64_TO_32_BIT_CONVERSION = YES; + GCC_WARN_ABOUT_RETURN_TYPE = YES_ERROR; + GCC_WARN_UNDECLARED_SELECTOR = YES; + GCC_WARN_UNINITIALIZED_AUTOS = YES_AGGRESSIVE; + GCC_WARN_UNUSED_FUNCTION = YES; + GCC_WARN_UNUSED_VARIABLE = YES; + IPHONEOS_DEPLOYMENT_TARGET = 11.0; + MTL_ENABLE_DEBUG_INFO = YES; + ONLY_ACTIVE_ARCH = YES; + SDKROOT = iphoneos; + SWIFT_ACTIVE_COMPILATION_CONDITIONS = DEBUG; + SWIFT_OPTIMIZATION_LEVEL = "-Onone"; + }; + name = Debug; + }; + AE99577E1FA704B000397D38 /* Release */ = { + isa = XCBuildConfiguration; + buildSettings = { + ALWAYS_SEARCH_USER_PATHS = NO; + CLANG_ANALYZER_NONNULL = YES; + CLANG_ANALYZER_NUMBER_OBJECT_CONVERSION = YES_AGGRESSIVE; + CLANG_CXX_LANGUAGE_STANDARD = "gnu++14"; + CLANG_CXX_LIBRARY = "libc++"; + CLANG_ENABLE_MODULES = YES; + CLANG_ENABLE_OBJC_ARC = YES; + CLANG_WARN_BLOCK_CAPTURE_AUTORELEASING = YES; + CLANG_WARN_BOOL_CONVERSION = YES; + CLANG_WARN_COMMA = YES; + CLANG_WARN_CONSTANT_CONVERSION = YES; + CLANG_WARN_DIRECT_OBJC_ISA_USAGE = YES_ERROR; + CLANG_WARN_DOCUMENTATION_COMMENTS = YES; + CLANG_WARN_EMPTY_BODY = YES; + CLANG_WARN_ENUM_CONVERSION = YES; + CLANG_WARN_INFINITE_RECURSION = YES; + CLANG_WARN_INT_CONVERSION = YES; + CLANG_WARN_NON_LITERAL_NULL_CONVERSION = YES; + CLANG_WARN_OBJC_LITERAL_CONVERSION = YES; + CLANG_WARN_OBJC_ROOT_CLASS = YES_ERROR; + CLANG_WARN_RANGE_LOOP_ANALYSIS = YES; + CLANG_WARN_STRICT_PROTOTYPES = YES; + CLANG_WARN_SUSPICIOUS_MOVE = YES; + CLANG_WARN_UNGUARDED_AVAILABILITY = YES_AGGRESSIVE; + CLANG_WARN_UNREACHABLE_CODE = YES; + CLANG_WARN__DUPLICATE_METHOD_MATCH = YES; + CODE_SIGN_IDENTITY = "iPhone Developer"; + COPY_PHASE_STRIP = NO; + DEBUG_INFORMATION_FORMAT = "dwarf-with-dsym"; + ENABLE_NS_ASSERTIONS = NO; + ENABLE_STRICT_OBJC_MSGSEND = YES; + GCC_C_LANGUAGE_STANDARD = gnu11; + GCC_NO_COMMON_BLOCKS = YES; + GCC_WARN_64_TO_32_BIT_CONVERSION = YES; + GCC_WARN_ABOUT_RETURN_TYPE = YES_ERROR; + GCC_WARN_UNDECLARED_SELECTOR = YES; + GCC_WARN_UNINITIALIZED_AUTOS = YES_AGGRESSIVE; + GCC_WARN_UNUSED_FUNCTION = YES; + GCC_WARN_UNUSED_VARIABLE = YES; + IPHONEOS_DEPLOYMENT_TARGET = 11.0; + MTL_ENABLE_DEBUG_INFO = NO; + SDKROOT = iphoneos; + SWIFT_OPTIMIZATION_LEVEL = "-Owholemodule"; + VALIDATE_PRODUCT = YES; + }; + name = Release; + }; + AE9957801FA704B000397D38 /* Debug */ = { + isa = XCBuildConfiguration; + buildSettings = { + ASSETCATALOG_COMPILER_APPICON_NAME = AppIcon; + CODE_SIGN_STYLE = Automatic; + INFOPLIST_FILE = meetingRooms/Info.plist; + LD_RUNPATH_SEARCH_PATHS = "$(inherited) @executable_path/Frameworks"; + PRODUCT_BUNDLE_IDENTIFIER = "--------.meetingRooms"; + PRODUCT_NAME = "$(TARGET_NAME)"; + SWIFT_VERSION = 4.0; + TARGETED_DEVICE_FAMILY = "1,2"; + }; + name = Debug; + }; + AE9957811FA704B000397D38 /* Release */ = { + isa = XCBuildConfiguration; + buildSettings = { + ASSETCATALOG_COMPILER_APPICON_NAME = AppIcon; + CODE_SIGN_STYLE = Automatic; + INFOPLIST_FILE = meetingRooms/Info.plist; + LD_RUNPATH_SEARCH_PATHS = "$(inherited) @executable_path/Frameworks"; + PRODUCT_BUNDLE_IDENTIFIER = "--------.meetingRooms"; + PRODUCT_NAME = "$(TARGET_NAME)"; + SWIFT_VERSION = 4.0; + TARGETED_DEVICE_FAMILY = "1,2"; + }; + name = Release; + }; + AE9957831FA704B000397D38 /* Debug */ = { + isa = XCBuildConfiguration; + buildSettings = { + ALWAYS_EMBED_SWIFT_STANDARD_LIBRARIES = YES; + BUNDLE_LOADER = "$(TEST_HOST)"; + CODE_SIGN_STYLE = Automatic; + INFOPLIST_FILE = meetingRoomsTests/Info.plist; + LD_RUNPATH_SEARCH_PATHS = "$(inherited) @executable_path/Frameworks @loader_path/Frameworks"; + PRODUCT_BUNDLE_IDENTIFIER = "--------.meetingRoomsTests"; + PRODUCT_NAME = "$(TARGET_NAME)"; + SWIFT_VERSION = 4.0; + TARGETED_DEVICE_FAMILY = "1,2"; + TEST_HOST = "$(BUILT_PRODUCTS_DIR)/meetingRooms.app/meetingRooms"; + }; + name = Debug; + }; + AE9957841FA704B000397D38 /* Release */ = { + isa = XCBuildConfiguration; + buildSettings = { + ALWAYS_EMBED_SWIFT_STANDARD_LIBRARIES = YES; + BUNDLE_LOADER = "$(TEST_HOST)"; + CODE_SIGN_STYLE = Automatic; + INFOPLIST_FILE = meetingRoomsTests/Info.plist; + LD_RUNPATH_SEARCH_PATHS = "$(inherited) @executable_path/Frameworks @loader_path/Frameworks"; + PRODUCT_BUNDLE_IDENTIFIER = "--------.meetingRoomsTests"; + PRODUCT_NAME = "$(TARGET_NAME)"; + SWIFT_VERSION = 4.0; + TARGETED_DEVICE_FAMILY = "1,2"; + TEST_HOST = "$(BUILT_PRODUCTS_DIR)/meetingRooms.app/meetingRooms"; + }; + name = Release; + }; + AE9957861FA704B000397D38 /* Debug */ = { + isa = XCBuildConfiguration; + buildSettings = { + ALWAYS_EMBED_SWIFT_STANDARD_LIBRARIES = YES; + CODE_SIGN_STYLE = Automatic; + INFOPLIST_FILE = meetingRoomsUITests/Info.plist; + LD_RUNPATH_SEARCH_PATHS = "$(inherited) @executable_path/Frameworks @loader_path/Frameworks"; + PRODUCT_BUNDLE_IDENTIFIER = "--------.meetingRoomsUITests"; + PRODUCT_NAME = "$(TARGET_NAME)"; + SWIFT_VERSION = 4.0; + TARGETED_DEVICE_FAMILY = "1,2"; + TEST_TARGET_NAME = meetingRooms; + }; + name = Debug; + }; + AE9957871FA704B000397D38 /* Release */ = { + isa = XCBuildConfiguration; + buildSettings = { + ALWAYS_EMBED_SWIFT_STANDARD_LIBRARIES = YES; + CODE_SIGN_STYLE = Automatic; + INFOPLIST_FILE = meetingRoomsUITests/Info.plist; + LD_RUNPATH_SEARCH_PATHS = "$(inherited) @executable_path/Frameworks @loader_path/Frameworks"; + PRODUCT_BUNDLE_IDENTIFIER = "--------.meetingRoomsUITests"; + PRODUCT_NAME = "$(TARGET_NAME)"; + SWIFT_VERSION = 4.0; + TARGETED_DEVICE_FAMILY = "1,2"; + TEST_TARGET_NAME = meetingRooms; + }; + name = Release; + }; +/* End XCBuildConfiguration section */ + +/* Begin XCConfigurationList section */ + AE9957521FA704AF00397D38 /* Build configuration list for PBXProject "meetingRooms" */ = { + isa = XCConfigurationList; + buildConfigurations = ( + AE99577D1FA704B000397D38 /* Debug */, + AE99577E1FA704B000397D38 /* Release */, + ); + defaultConfigurationIsVisible = 0; + defaultConfigurationName = Release; + }; + AE99577F1FA704B000397D38 /* Build configuration list for PBXNativeTarget "meetingRooms" */ = { + isa = XCConfigurationList; + buildConfigurations = ( + AE9957801FA704B000397D38 /* Debug */, + AE9957811FA704B000397D38 /* Release */, + ); + defaultConfigurationIsVisible = 0; + defaultConfigurationName = Release; + }; + AE9957821FA704B000397D38 /* Build configuration list for PBXNativeTarget "meetingRoomsTests" */ = { + isa = XCConfigurationList; + buildConfigurations = ( + AE9957831FA704B000397D38 /* Debug */, + AE9957841FA704B000397D38 /* Release */, + ); + defaultConfigurationIsVisible = 0; + defaultConfigurationName = Release; + }; + AE9957851FA704B000397D38 /* Build configuration list for PBXNativeTarget "meetingRoomsUITests" */ = { + isa = XCConfigurationList; + buildConfigurations = ( + AE9957861FA704B000397D38 /* Debug */, + AE9957871FA704B000397D38 /* Release */, + ); + defaultConfigurationIsVisible = 0; + defaultConfigurationName = Release; + }; +/* End XCConfigurationList section */ + }; + rootObject = AE99574F1FA704AF00397D38 /* Project object */; +} diff --git "a/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/meetingRooms_userdfault/meetingRooms.xcodeproj/project.xcworkspace/contents.xcworkspacedata" "b/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/meetingRooms_userdfault/meetingRooms.xcodeproj/project.xcworkspace/contents.xcworkspacedata" new file mode 100644 index 0000000..8491799 --- /dev/null +++ "b/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/meetingRooms_userdfault/meetingRooms.xcodeproj/project.xcworkspace/contents.xcworkspacedata" @@ -0,0 +1,7 @@ + + + + + diff --git "a/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/meetingRooms_userdfault/meetingRooms/AppDelegate.swift" "b/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/meetingRooms_userdfault/meetingRooms/AppDelegate.swift" new file mode 100644 index 0000000..b1cfed9 --- /dev/null +++ "b/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/meetingRooms_userdfault/meetingRooms/AppDelegate.swift" @@ -0,0 +1,51 @@ +// +// AppDelegate.swift +// meetingRooms +// +// Created by 황도증 on 2017. 10. 30.. +// Copyright © 2017년 황도증. All rights reserved. +// + +import UIKit + +@UIApplicationMain +class AppDelegate: UIResponder, UIApplicationDelegate { + + var window: UIWindow? + + + func application(_ application: UIApplication, didFinishLaunchingWithOptions launchOptions: [UIApplicationLaunchOptionsKey: Any]?) -> Bool { + // Override point for customization after application launch. + return true + } + + func applicationWillResignActive(_ application: UIApplication) { + // Sent when the application is about to move from active to inactive state. This can occur for certain types of temporary interruptions (such as an incoming phone call or SMS message) or when the user quits the application and it begins the transition to the background state. + // Use this method to pause ongoing tasks, disable timers, and invalidate graphics rendering callbacks. Games should use this method to pause the game. + } + + func applicationDidEnterBackground(_ application: UIApplication) { + // Use this method to release shared resources, save user data, invalidate timers, and store enough application state information to restore your application to its current state in case it is terminated later. + // If your application supports background execution, this method is called instead of applicationWillTerminate: when the user quits. + } + + func applicationWillEnterForeground(_ application: UIApplication) { + // Called as part of the transition from the background to the active state; here you can undo many of the changes made on entering the background. + } + + func applicationDidBecomeActive(_ application: UIApplication) { + // Restart any tasks that were paused (or not yet started) while the application was inactive. If the application was previously in the background, optionally refresh the user interface. + let userDefaultColor = UserDefaults.standard.integer(forKey: TintColorKey) + guard let defaultColor = TintColor(rawValue: userDefaultColor)?.color else { + return + } + applyTintColor(color: defaultColor) + } + + func applicationWillTerminate(_ application: UIApplication) { + // Called when the application is about to terminate. Save data if appropriate. See also applicationDidEnterBackground:. + } + + +} + diff --git "a/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/meetingRooms_userdfault/meetingRooms/Assets.xcassets/AppIcon.appiconset/Contents.json" "b/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/meetingRooms_userdfault/meetingRooms/Assets.xcassets/AppIcon.appiconset/Contents.json" new file mode 100644 index 0000000..d8db8d6 --- /dev/null +++ "b/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/meetingRooms_userdfault/meetingRooms/Assets.xcassets/AppIcon.appiconset/Contents.json" @@ -0,0 +1,98 @@ +{ + "images" : [ + { + "idiom" : "iphone", + "size" : "20x20", + "scale" : "2x" + }, + { + "idiom" : "iphone", + "size" : "20x20", + "scale" : "3x" + }, + { + "idiom" : "iphone", + "size" : "29x29", + "scale" : "2x" + }, + { + "idiom" : "iphone", + "size" : "29x29", + "scale" : "3x" + }, + { + "idiom" : "iphone", + "size" : "40x40", + "scale" : "2x" + }, + { + "idiom" : "iphone", + "size" : "40x40", + "scale" : "3x" + }, + { + "idiom" : "iphone", + "size" : "60x60", + "scale" : "2x" + }, + { + "idiom" : "iphone", + "size" : "60x60", + "scale" : "3x" + }, + { + "idiom" : "ipad", + "size" : "20x20", + "scale" : "1x" + }, + { + "idiom" : "ipad", + "size" : "20x20", + "scale" : "2x" + }, + { + "idiom" : "ipad", + "size" : "29x29", + "scale" : "1x" + }, + { + "idiom" : "ipad", + "size" : "29x29", + "scale" : "2x" + }, + { + "idiom" : "ipad", + "size" : "40x40", + "scale" : "1x" + }, + { + "idiom" : "ipad", + "size" : "40x40", + "scale" : "2x" + }, + { + "idiom" : "ipad", + "size" : "76x76", + "scale" : "1x" + }, + { + "idiom" : "ipad", + "size" : "76x76", + "scale" : "2x" + }, + { + "idiom" : "ipad", + "size" : "83.5x83.5", + "scale" : "2x" + }, + { + "idiom" : "ios-marketing", + "size" : "1024x1024", + "scale" : "1x" + } + ], + "info" : { + "version" : 1, + "author" : "xcode" + } +} \ No newline at end of file diff --git "a/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/meetingRooms_userdfault/meetingRooms/Base.lproj/LaunchScreen.storyboard" "b/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/meetingRooms_userdfault/meetingRooms/Base.lproj/LaunchScreen.storyboard" new file mode 100644 index 0000000..f83f6fd --- /dev/null +++ "b/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/meetingRooms_userdfault/meetingRooms/Base.lproj/LaunchScreen.storyboard" @@ -0,0 +1,25 @@ + + + + + + + + + + + + + + + + + + + + + + + + + diff --git "a/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/meetingRooms_userdfault/meetingRooms/Base.lproj/Main.storyboard" "b/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/meetingRooms_userdfault/meetingRooms/Base.lproj/Main.storyboard" new file mode 100644 index 0000000..53a8b0c --- /dev/null +++ "b/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/meetingRooms_userdfault/meetingRooms/Base.lproj/Main.storyboard" @@ -0,0 +1,662 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + diff --git "a/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/meetingRooms_userdfault/meetingRooms/BranchListViewController.swift" "b/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/meetingRooms_userdfault/meetingRooms/BranchListViewController.swift" new file mode 100644 index 0000000..fa28525 --- /dev/null +++ "b/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/meetingRooms_userdfault/meetingRooms/BranchListViewController.swift" @@ -0,0 +1,119 @@ +// +// BranchListViewController.swift +// meetingRooms +// +// Created by 황도증 on 2017. 11. 9.. +// Copyright © 2017년 황도증. All rights reserved. +// + +import UIKit + +class BranchListViewController: UITableViewController { + + override func viewDidLoad() { + super.viewDidLoad() + + // Uncomment the following line to preserve selection between presentations + // self.clearsSelectionOnViewWillAppear = false + + // Uncomment the following line to display an Edit button in the navigation bar for this view controller. + // self.navigationItem.rightBarButtonItem = self.editButtonItem + + self.navigationController?.isToolbarHidden = true + } + + override func didReceiveMemoryWarning() { + super.didReceiveMemoryWarning() + // Dispose of any resources that can be recreated. + } + + // MARK: - Table view data source + + override func numberOfSections(in tableView: UITableView) -> Int { + // #warning Incomplete implementation, return the number of sections + return 1 + } + + @IBAction func locationTurnOn(_ sender: Any) { + let locationAlert = UIAlertController(title:"위치정보요청", message: "위치정보를 기반으로 가까운 지점을 자동으로 선택할 수 있습니다.", preferredStyle: .actionSheet) + + let locationAction = UIAlertAction(title: "위치정보켜기", style: .default, handler: {(action:UIAlertAction) -> Void in print("위치정보켜기 선택")}) + + let openMapAction = UIAlertAction(title: "지도에서 열기", style: .default, handler: {(action:UIAlertAction) -> Void in print("지도앱에서 열기 선택")}) + + locationAlert.addAction(locationAction) + locationAlert.addAction(openMapAction) + + self.present(locationAlert, animated: true, completion: nil) + } + override func tableView(_ tableView: UITableView, numberOfRowsInSection section: Int) -> Int { + // #warning Incomplete implementation, return the number of rows + let rowCount = dataCenter.branches.count + return rowCount + } + + + override func tableView(_ tableView: UITableView, cellForRowAt indexPath: IndexPath) -> UITableViewCell { + let cell = tableView.dequeueReusableCell(withIdentifier: "BranchCell", for: indexPath) + + // Configure the cell... + let branch = dataCenter.branches[indexPath.row] + cell.textLabel?.text = branch.name + + return cell + } + + + /* + // Override to support conditional editing of the table view. + override func tableView(_ tableView: UITableView, canEditRowAt indexPath: IndexPath) -> Bool { + // Return false if you do not want the specified item to be editable. + return true + } + */ + + /* + // Override to support editing the table view. + override func tableView(_ tableView: UITableView, commit editingStyle: UITableViewCellEditingStyle, forRowAt indexPath: IndexPath) { + if editingStyle == .delete { + // Delete the row from the data source + tableView.deleteRows(at: [indexPath], with: .fade) + } else if editingStyle == .insert { + // Create a new instance of the appropriate class, insert it into the array, and add a new row to the table view + } + } + */ + + /* + // Override to support rearranging the table view. + override func tableView(_ tableView: UITableView, moveRowAt fromIndexPath: IndexPath, to: IndexPath) { + + } + */ + + /* + // Override to support conditional rearranging of the table view. + override func tableView(_ tableView: UITableView, canMoveRowAt indexPath: IndexPath) -> Bool { + // Return false if you do not want the item to be re-orderable. + return true + } + */ + + + // MARK: - Navigation + + // In a storyboard-based application, you will often want to do a little preparation before navigation + override func prepare(for segue: UIStoryboardSegue, sender: Any?) { + // Get the new view controller using segue.destinationViewController. + // Pass the selected object to the new view controller. + + if segue.identifier == "ServiceSegue" { + if let destination = segue.destination as? ServiceListViewController { + if let selectedIndex = self.tableView.indexPathForSelectedRow?.row { + destination.branch = dataCenter.branches[selectedIndex] as Branch + } + } + } + + } +} diff --git "a/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/meetingRooms_userdfault/meetingRooms/DataCenter.swift" "b/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/meetingRooms_userdfault/meetingRooms/DataCenter.swift" new file mode 100644 index 0000000..7476872 --- /dev/null +++ "b/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/meetingRooms_userdfault/meetingRooms/DataCenter.swift" @@ -0,0 +1,84 @@ +// +// DataCenter.swift +// meetingRooms +// +// Created by 황도증 on 2017. 11. 9.. +// Copyright © 2017년 황도증. All rights reserved. +// + +import Foundation + +let dataCenter:DataCenter = DataCenter() + +class DataCenter { + var branches:[Branch] = [] + + init (){ + let banksyRoom = MeetingRoom(name:"Banksy", capacity: 4) + let kahloRoom = MeetingRoom(name:"Kahlo", capacity: 8) + let riveraRoom = MeetingRoom(name:"Rivera", capacity: 8) + let picasoRoom = MeetingRoom(name:"Picaso", capacity: 10) + + let vehicleService = Service(name: "차량예약") + let meetingRoomService = Service(name: "회의실예약") + let visitorService = Service(name: "방문자예약") + let deskService = Service(name: "데스크예약") + meetingRoomService.items = [banksyRoom, kahloRoom, riveraRoom, picasoRoom] + + let pangyoBranch = Branch(name: "판교점") + let samsungBranch = Branch(name: "삼성점") + let yeoksamBranch = Branch(name: "역삼점") + let sinrimBranch = Branch(name: "신림점") + let songdooBranch = Branch(name: "송도점") + let anamBranch = Branch(name: "안암점") + pangyoBranch.services = [vehicleService, meetingRoomService, visitorService, deskService] + + branches += [pangyoBranch, samsungBranch, yeoksamBranch, sinrimBranch, songdooBranch, anamBranch] + } +} + +class Branch { + let name:String + var services:[Service]? + + init(name:String) { + self.name = name + } +} + +class Service { + let name:String + var items:[MeetingRoom]? + + init(name:String) { + self.name = name + } +} + +class MeetingRoom { + let name:String + let capacity:Int + var reservations:[Reservation]? + + init(name:String, capacity:Int) { + self.name = name + self.capacity = capacity + } +} + +class Reservation { + var hostName:String + var date:NSDate + var attendees:Int + var equipments:[String] + var catering:Bool + + init() { + self.hostName = "host of meeting" + self.date = NSDate() + self.attendees = 1 + self.equipments = [] + self.catering = false + } + +} diff --git "a/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/meetingRooms_userdfault/meetingRooms/Info.plist" "b/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/meetingRooms_userdfault/meetingRooms/Info.plist" new file mode 100644 index 0000000..16be3b6 --- /dev/null +++ "b/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/meetingRooms_userdfault/meetingRooms/Info.plist" @@ -0,0 +1,45 @@ + + + + + CFBundleDevelopmentRegion + $(DEVELOPMENT_LANGUAGE) + CFBundleExecutable + $(EXECUTABLE_NAME) + CFBundleIdentifier + $(PRODUCT_BUNDLE_IDENTIFIER) + CFBundleInfoDictionaryVersion + 6.0 + CFBundleName + $(PRODUCT_NAME) + CFBundlePackageType + APPL + CFBundleShortVersionString + 1.0 + CFBundleVersion + 1 + LSRequiresIPhoneOS + + UILaunchStoryboardName + LaunchScreen + UIMainStoryboardFile + Main + UIRequiredDeviceCapabilities + + armv7 + + UISupportedInterfaceOrientations + + UIInterfaceOrientationPortrait + UIInterfaceOrientationLandscapeLeft + UIInterfaceOrientationLandscapeRight + + UISupportedInterfaceOrientations~ipad + + UIInterfaceOrientationPortrait + UIInterfaceOrientationPortraitUpsideDown + UIInterfaceOrientationLandscapeLeft + UIInterfaceOrientationLandscapeRight + + + diff --git "a/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/meetingRooms_userdfault/meetingRooms/MeetingRoomListViewController.swift" "b/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/meetingRooms_userdfault/meetingRooms/MeetingRoomListViewController.swift" new file mode 100644 index 0000000..b56d5ae --- /dev/null +++ "b/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/meetingRooms_userdfault/meetingRooms/MeetingRoomListViewController.swift" @@ -0,0 +1,117 @@ +// +// MeetingRoomListViewController.swift +// meetingRooms +// +// Created by 황도증 on 2017. 10. 30.. +// Copyright © 2017년 황도증. All rights reserved. +// + +import UIKit + +class MeetingRoomListViewController: UITableViewController { + + var service:Service? + + override func viewDidLoad() { + super.viewDidLoad() + + // Uncomment the following line to preserve selection between presentations + // self.clearsSelectionOnViewWillAppear = false + + // Uncomment the following line to display an Edit button in the navigation bar for this view controller. + // self.navigationItem.rightBarButtonItem = self.editButtonItem + + self.title = service?.name + } + + override func didReceiveMemoryWarning() { + super.didReceiveMemoryWarning() + // Dispose of any resources that can be recreated. + } + + // MARK: - Table view data source + + override func numberOfSections(in tableView: UITableView) -> Int { + // #warning Incomplete implementation, return the number of sections + return 1 + } + + override func tableView(_ tableView: UITableView, numberOfRowsInSection section: Int) -> Int { + // #warning Incomplete implementation, return the number of rows + //let categoryValues = Array(meetingRooms.values)[section] + //let orderMeetingRoooms = meetingRooms.sorted(by: {$0.1.first!.1 < $1.1.first!.1}) + guard let rowCount = service?.items?.count else { + return 0 + } + return rowCount + } + + + override func tableView(_ tableView: UITableView, cellForRowAt indexPath: IndexPath) -> UITableViewCell { + let cell = tableView.dequeueReusableCell(withIdentifier: "ItemCell", for: indexPath) + + //let orderMeetingRoooms = meetingRooms.sorted(by: {$0.1.first!.1 < $1.1.first!.1}) + // Configure the cell... + //let categoryValue = Array(meetingRooms.values)[indexPath.section] + + guard let meetingRoom = service?.items?[indexPath.row] else { + return cell + } + + cell.textLabel!.text = meetingRoom.name + cell.detailTextLabel!.text = String(meetingRoom.capacity) + return cell + } + + /* + // Override to support conditional editing of the table view. + override func tableView(_ tableView: UITableView, canEditRowAt indexPath: IndexPath) -> Bool { + // Return false if you do not want the specified item to be editable. + return true + } + */ + + /* + // Override to support editing the table view. + override func tableView(_ tableView: UITableView, commit editingStyle: UITableViewCellEditingStyle, forRowAt indexPath: IndexPath) { + if editingStyle == .delete { + // Delete the row from the data source + tableView.deleteRows(at: [indexPath], with: .fade) + } else if editingStyle == .insert { + // Create a new instance of the appropriate class, insert it into the array, and add a new row to the table view + } + } + */ + + /* + // Override to support rearranging the table view. + override func tableView(_ tableView: UITableView, moveRowAt fromIndexPath: IndexPath, to: IndexPath) { + + } + */ + + /* + // Override to support conditional rearranging of the table view. + override func tableView(_ tableView: UITableView, canMoveRowAt indexPath: IndexPath) -> Bool { + // Return false if you do not want the item to be re-orderable. + return true + } + */ + + + // MARK: - Navigation + + // In a storyboard-based application, you will often want to do a little preparation before navigation + override func prepare(for segue: UIStoryboardSegue, sender: Any?) { + // Get the new view controller using segue.destinationViewController. + // Pass the selected object to the new view controller. + if segue.identifier == "ReservationSegue" { + guard let destination = segue.destination as? ReservationListViewController, let selectedIndex = self.tableView.indexPathForSelectedRow?.row, let meetingRoom = service?.items?[selectedIndex] else { + return + } + destination.meetingRoom = meetingRoom + } + + } + +} diff --git "a/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/meetingRooms_userdfault/meetingRooms/ReservationListViewController.swift" "b/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/meetingRooms_userdfault/meetingRooms/ReservationListViewController.swift" new file mode 100644 index 0000000..7da14de --- /dev/null +++ "b/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/meetingRooms_userdfault/meetingRooms/ReservationListViewController.swift" @@ -0,0 +1,119 @@ +// +// ReservationListViewController.swift +// meetingRooms +// +// Created by 황도증 on 2017. 11. 9.. +// Copyright © 2017년 황도증. All rights reserved. +// + +import UIKit + +class ReservationListViewController: UITableViewController { + + var meetingRoom:MeetingRoom? + var newReservation:Reservation? + + override func viewDidLoad() { + super.viewDidLoad() + + // Uncomment the following line to preserve selection between presentations + // self.clearsSelectionOnViewWillAppear = false + + // Uncomment the following line to display an Edit button in the navigation bar for this view controller. + // self.navigationItem.rightBarButtonItem = self.editButtonItem + } + + override func didReceiveMemoryWarning() { + super.didReceiveMemoryWarning() + // Dispose of any resources that can be recreated. + } + + func addNewItem(reservation:Reservation) { + if (self.meetingRoom?.reservations?.append(reservation)) == nil { + self.meetingRoom?.reservations = [reservation] + } + self.tableView.reloadData() + } + + @IBAction func unwindToReservationList(segue:UIStoryboardSegue) { + + } + + + // MARK: - Table view data source + + override func numberOfSections(in tableView: UITableView) -> Int { + // #warning Incomplete implementation, return the number of sections + return 1 + } + + override func tableView(_ tableView: UITableView, numberOfRowsInSection section: Int) -> Int { + // #warning Incomplete implementation, return the number of rows + guard let rowCount = meetingRoom?.reservations?.count else { + return 0 + } + return rowCount + } + + + override func tableView(_ tableView: UITableView, cellForRowAt indexPath: IndexPath) -> UITableViewCell { + let cell = tableView.dequeueReusableCell(withIdentifier: "ReservationCell", for: indexPath) + + // Configure the cell... + guard let reservation = meetingRoom?.reservations?[indexPath.row] else { + return cell + } + + cell.textLabel?.text = reservation.date.description + cell.detailTextLabel?.text = reservation.hostName + + return cell + } + + + /* + // Override to support conditional editing of the table view. + override func tableView(_ tableView: UITableView, canEditRowAt indexPath: IndexPath) -> Bool { + // Return false if you do not want the specified item to be editable. + return true + } + */ + + /* + // Override to support editing the table view. + override func tableView(_ tableView: UITableView, commit editingStyle: UITableViewCellEditingStyle, forRowAt indexPath: IndexPath) { + if editingStyle == .delete { + // Delete the row from the data source + tableView.deleteRows(at: [indexPath], with: .fade) + } else if editingStyle == .insert { + // Create a new instance of the appropriate class, insert it into the array, and add a new row to the table view + } + } + */ + + /* + // Override to support rearranging the table view. + override func tableView(_ tableView: UITableView, moveRowAt fromIndexPath: IndexPath, to: IndexPath) { + + } + */ + + /* + // Override to support conditional rearranging of the table view. + override func tableView(_ tableView: UITableView, canMoveRowAt indexPath: IndexPath) -> Bool { + // Return false if you do not want the item to be re-orderable. + return true + } + */ + + /* + // MARK: - Navigation + + // In a storyboard-based application, you will often want to do a little preparation before navigation + override func prepare(for segue: UIStoryboardSegue, sender: Any?) { + // Get the new view controller using segue.destinationViewController. + // Pass the selected object to the new view controller. + } + */ + +} diff --git "a/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/meetingRooms_userdfault/meetingRooms/ReserveRoomViewController.swift" "b/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/meetingRooms_userdfault/meetingRooms/ReserveRoomViewController.swift" new file mode 100644 index 0000000..b976043 --- /dev/null +++ "b/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/meetingRooms_userdfault/meetingRooms/ReserveRoomViewController.swift" @@ -0,0 +1,154 @@ +// +// ReserveRoomViewController.swift +// meetingRooms +// +// Created by 황도증 on 2017. 11. 9.. +// Copyright © 2017년 황도증. All rights reserved. +// + +import UIKit + +class ReserveRoomViewController: UITableViewController { + + @IBOutlet weak var hostNameField: UITextField! + @IBOutlet weak var datePicker: UIDatePicker! + @IBOutlet weak var attendeesField: UITextField! + @IBOutlet weak var equipmentField: UITextField! + @IBOutlet weak var cateringSwitch: UISwitch! + + + override func viewDidLoad() { + super.viewDidLoad() + + // Uncomment the following line to preserve selection between presentations + // self.clearsSelectionOnViewWillAppear = false + + // Uncomment the following line to display an Edit button in the navigation bar for this view controller. + // self.navigationItem.rightBarButtonItem = self.editButtonItem + } + + override func didReceiveMemoryWarning() { + super.didReceiveMemoryWarning() + // Dispose of any resources that can be recreated. + } + + func newReservation() -> Reservation? { + let reservation = Reservation() + let host = hostNameField.text + + if (host?.isEmpty)! { + return nil + } + reservation.hostName = host! + reservation.date = datePicker.date as NSDate + + if let equipmentArray = equipmentField.text?.split(separator: ",").map(String.init) { + reservation.equipments = equipmentArray + } + reservation.catering = cateringSwitch.isOn + return reservation + } + + @IBAction func cancelReservation(_ sender: Any) { + self.dismiss(animated: true, completion: nil) + } + + @IBAction func makeReservation(_ sender: Any) { + guard let reservation = newReservation() else { + self.dismiss(animated: true, completion: nil) + return + } + + switch self.presentingViewController { + case let tapbarC as UITabBarController: + if let navigationC = tapbarC.selectedViewController as? UINavigationController, let reservationListVC = navigationC.topViewController as? ReservationListViewController { + reservationListVC.addNewItem(reservation: reservation) + } + case let navigationC as UINavigationController: + if let reservationListVC = navigationC.topViewController as? ReservationListViewController { + reservationListVC.addNewItem(reservation: reservation) + } + case let reservationListVC as ReservationListViewController: + reservationListVC.addNewItem(reservation: reservation) + default: + break + } + + self.dismiss(animated: true, completion: nil) + } + + + // MARK: - Table view data source +/* + override func numberOfSections(in tableView: UITableView) -> Int { + // #warning Incomplete implementation, return the number of sections + return 0 + } + + override func tableView(_ tableView: UITableView, numberOfRowsInSection section: Int) -> Int { + // #warning Incomplete implementation, return the number of rows + return 0 + } +*/ + /* + override func tableView(_ tableView: UITableView, cellForRowAt indexPath: IndexPath) -> UITableViewCell { + let cell = tableView.dequeueReusableCell(withIdentifier: "reuseIdentifier", for: indexPath) + + // Configure the cell... + + return cell + } + */ + + /* + // Override to support conditional editing of the table view. + override func tableView(_ tableView: UITableView, canEditRowAt indexPath: IndexPath) -> Bool { + // Return false if you do not want the specified item to be editable. + return true + } + */ + + /* + // Override to support editing the table view. + override func tableView(_ tableView: UITableView, commit editingStyle: UITableViewCellEditingStyle, forRowAt indexPath: IndexPath) { + if editingStyle == .delete { + // Delete the row from the data source + tableView.deleteRows(at: [indexPath], with: .fade) + } else if editingStyle == .insert { + // Create a new instance of the appropriate class, insert it into the array, and add a new row to the table view + } + } + */ + + /* + // Override to support rearranging the table view. + override func tableView(_ tableView: UITableView, moveRowAt fromIndexPath: IndexPath, to: IndexPath) { + + } + */ + + /* + // Override to support conditional rearranging of the table view. + override func tableView(_ tableView: UITableView, canMoveRowAt indexPath: IndexPath) -> Bool { + // Return false if you do not want the item to be re-orderable. + return true + } + */ + + + // MARK: - Navigation + + // In a storyboard-based application, you will often want to do a little preparation before navigation + override func prepare(for segue: UIStoryboardSegue, sender: Any?) { + // Get the new view controller using segue.destinationViewController. + // Pass the selected object to the new view controller. + if segue.identifier == "ReserveDone" { + guard let reservation = newReservation(), let reservationListVC = segue.destination as? ReservationListViewController else { + return + } + reservationListVC.addNewItem(reservation: reservation) + } + } + + +} diff --git "a/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/meetingRooms_userdfault/meetingRooms/RoomInfoViewController.swift" "b/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/meetingRooms_userdfault/meetingRooms/RoomInfoViewController.swift" new file mode 100644 index 0000000..61bf80d --- /dev/null +++ "b/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/meetingRooms_userdfault/meetingRooms/RoomInfoViewController.swift" @@ -0,0 +1,98 @@ +// +// RoomInfoViewController.swift +// meetingRooms +// +// Created by 황도증 on 2017. 11. 9.. +// Copyright © 2017년 황도증. All rights reserved. +// + +import UIKit + +class RoomInfoViewController: UITableViewController { + + override func viewDidLoad() { + super.viewDidLoad() + + // Uncomment the following line to preserve selection between presentations + // self.clearsSelectionOnViewWillAppear = false + + // Uncomment the following line to display an Edit button in the navigation bar for this view controller. + // self.navigationItem.rightBarButtonItem = self.editButtonItem + } + + override func didReceiveMemoryWarning() { + super.didReceiveMemoryWarning() + // Dispose of any resources that can be recreated. + } + @IBAction func modalDismiss(_ sender: Any) { + self.dismiss(animated: true, completion: nil) + } + /* + // MARK: - Table view data source + + override func numberOfSections(in tableView: UITableView) -> Int { + // #warning Incomplete implementation, return the number of sections + return 0 + } + + override func tableView(_ tableView: UITableView, numberOfRowsInSection section: Int) -> Int { + // #warning Incomplete implementation, return the number of rows + return 0 + } +*/ + /* + override func tableView(_ tableView: UITableView, cellForRowAt indexPath: IndexPath) -> UITableViewCell { + let cell = tableView.dequeueReusableCell(withIdentifier: "reuseIdentifier", for: indexPath) + + // Configure the cell... + + return cell + } + */ + + /* + // Override to support conditional editing of the table view. + override func tableView(_ tableView: UITableView, canEditRowAt indexPath: IndexPath) -> Bool { + // Return false if you do not want the specified item to be editable. + return true + } + */ + + /* + // Override to support editing the table view. + override func tableView(_ tableView: UITableView, commit editingStyle: UITableViewCellEditingStyle, forRowAt indexPath: IndexPath) { + if editingStyle == .delete { + // Delete the row from the data source + tableView.deleteRows(at: [indexPath], with: .fade) + } else if editingStyle == .insert { + // Create a new instance of the appropriate class, insert it into the array, and add a new row to the table view + } + } + */ + + /* + // Override to support rearranging the table view. + override func tableView(_ tableView: UITableView, moveRowAt fromIndexPath: IndexPath, to: IndexPath) { + + } + */ + + /* + // Override to support conditional rearranging of the table view. + override func tableView(_ tableView: UITableView, canMoveRowAt indexPath: IndexPath) -> Bool { + // Return false if you do not want the item to be re-orderable. + return true + } + */ + + /* + // MARK: - Navigation + + // In a storyboard-based application, you will often want to do a little preparation before navigation + override func prepare(for segue: UIStoryboardSegue, sender: Any?) { + // Get the new view controller using segue.destinationViewController. + // Pass the selected object to the new view controller. + } + */ + +} diff --git "a/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/meetingRooms_userdfault/meetingRooms/ServiceListViewController.swift" "b/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/meetingRooms_userdfault/meetingRooms/ServiceListViewController.swift" new file mode 100644 index 0000000..091d906 --- /dev/null +++ "b/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/meetingRooms_userdfault/meetingRooms/ServiceListViewController.swift" @@ -0,0 +1,113 @@ +// +// ServiceListViewController.swift +// meetingRooms +// +// Created by 황도증 on 2017. 11. 9.. +// Copyright © 2017년 황도증. All rights reserved. +// + +import UIKit + +class ServiceListViewController: UITableViewController { + + var branch:Branch? + + override func viewDidLoad() { + super.viewDidLoad() + + // Uncomment the following line to preserve selection between presentations + // self.clearsSelectionOnViewWillAppear = false + + // Uncomment the following line to display an Edit button in the navigation bar for this view controller. + // self.navigationItem.rightBarButtonItem = self.editButtonItem + self.title = branch?.name + self.navigationController?.isToolbarHidden = false + } + + override func didReceiveMemoryWarning() { + super.didReceiveMemoryWarning() + // Dispose of any resources that can be recreated. + } + + // MARK: - Table view data source + + override func numberOfSections(in tableView: UITableView) -> Int { + // #warning Incomplete implementation, return the number of sections + return 1 + } + + override func tableView(_ tableView: UITableView, numberOfRowsInSection section: Int) -> Int { + // #warning Incomplete implementation, return the number of rows + guard let rowCount = branch?.services?.count else { + return 0 + } + return rowCount + } + + + override func tableView(_ tableView: UITableView, cellForRowAt indexPath: IndexPath) -> UITableViewCell { + let cell = tableView.dequeueReusableCell(withIdentifier: "ServiceCell", for: indexPath) + + // Configure the cell... + guard let service = branch?.services?[indexPath.row] else { + return cell + } + + cell.textLabel?.text = service.name + + return cell + } + + + /* + // Override to support conditional editing of the table view. + override func tableView(_ tableView: UITableView, canEditRowAt indexPath: IndexPath) -> Bool { + // Return false if you do not want the specified item to be editable. + return true + } + */ + + /* + // Override to support editing the table view. + override func tableView(_ tableView: UITableView, commit editingStyle: UITableViewCellEditingStyle, forRowAt indexPath: IndexPath) { + if editingStyle == .delete { + // Delete the row from the data source + tableView.deleteRows(at: [indexPath], with: .fade) + } else if editingStyle == .insert { + // Create a new instance of the appropriate class, insert it into the array, and add a new row to the table view + } + } + */ + + /* + // Override to support rearranging the table view. + override func tableView(_ tableView: UITableView, moveRowAt fromIndexPath: IndexPath, to: IndexPath) { + + } + */ + + /* + // Override to support conditional rearranging of the table view. + override func tableView(_ tableView: UITableView, canMoveRowAt indexPath: IndexPath) -> Bool { + // Return false if you do not want the item to be re-orderable. + return true + } + */ + + + // MARK: - Navigation + + // In a storyboard-based application, you will often want to do a little preparation before navigation + override func prepare(for segue: UIStoryboardSegue, sender: Any?) { + // Get the new view controller using segue.destinationViewController. + // Pass the selected object to the new view controller. + if segue.identifier == "MeetingRoomSegue" { + guard let destination = segue.destination as? MeetingRoomListViewController, let selectedIndex = self.tableView.indexPathForSelectedRow?.row, let service = branch?.services?[selectedIndex] else { + return + } + destination.service = service + } + } + + +} diff --git "a/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/meetingRooms_userdfault/meetingRooms/TintColorViewController.swift" "b/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/meetingRooms_userdfault/meetingRooms/TintColorViewController.swift" new file mode 100644 index 0000000..9ba2c19 --- /dev/null +++ "b/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/meetingRooms_userdfault/meetingRooms/TintColorViewController.swift" @@ -0,0 +1,76 @@ +// +// TintColorViewController.swift +// meetingRooms +// +// Created by 황도증 on 2017. 11. 9.. +// Copyright © 2017년 황도증. All rights reserved. +// + +import UIKit + +enum TintColor:Int { + case Blue = 0, Red, Green, Purple + + var color:UIColor { get { + switch self { + case .Blue: + return UIColor.blue + case .Red: + return UIColor.red + case .Green: + return UIColor.green + case .Purple: + return UIColor.purple + } + } + + } +} + +let TintColorKey = "TintColor" + +func applyTintColor(color:UIColor) { + guard let window = UIApplication.shared.keyWindow else { + return + } + window.tintColor = color +} + +class TintColorViewController: UIViewController { + + @IBOutlet weak var tintColorSeg: UISegmentedControl! + + override func viewDidLoad() { + super.viewDidLoad() + + // Do any additional setup after loading the view. + let userDefaultColor = UserDefaults.standard.integer(forKey: TintColorKey) + self.tintColorSeg.selectedSegmentIndex = userDefaultColor + } + + override func didReceiveMemoryWarning() { + super.didReceiveMemoryWarning() + // Dispose of any resources that can be recreated. + } + + @IBAction func tintColorChanged(_ sender: Any) { + let selectedIndex = self.tintColorSeg.selectedSegmentIndex + UserDefaults.standard.set(selectedIndex, forKey: TintColorKey) + + guard let changedColor = TintColor(rawValue: selectedIndex)?.color else { + return + } + applyTintColor(color: changedColor) + } + + /* + // MARK: - Navigation + + // In a storyboard-based application, you will often want to do a little preparation before navigation + override func prepare(for segue: UIStoryboardSegue, sender: Any?) { + // Get the new view controller using segue.destinationViewController. + // Pass the selected object to the new view controller. + } + */ + +} diff --git "a/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/meetingRooms_userdfault/meetingRooms/ViewController.swift" "b/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/meetingRooms_userdfault/meetingRooms/ViewController.swift" new file mode 100644 index 0000000..24bd9b0 --- /dev/null +++ "b/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/meetingRooms_userdfault/meetingRooms/ViewController.swift" @@ -0,0 +1,25 @@ +// +// ViewController.swift +// meetingRooms +// +// Created by 황도증 on 2017. 10. 30.. +// Copyright © 2017년 황도증. All rights reserved. +// + +import UIKit + +class ViewController: UIViewController { + + override func viewDidLoad() { + super.viewDidLoad() + // Do any additional setup after loading the view, typically from a nib. + } + + override func didReceiveMemoryWarning() { + super.didReceiveMemoryWarning() + // Dispose of any resources that can be recreated. + } + + +} + diff --git "a/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/meetingRooms_userdfault/meetingRoomsTests/Info.plist" "b/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/meetingRooms_userdfault/meetingRoomsTests/Info.plist" new file mode 100644 index 0000000..6c40a6c --- /dev/null +++ "b/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/meetingRooms_userdfault/meetingRoomsTests/Info.plist" @@ -0,0 +1,22 @@ + + + + + CFBundleDevelopmentRegion + $(DEVELOPMENT_LANGUAGE) + CFBundleExecutable + $(EXECUTABLE_NAME) + CFBundleIdentifier + $(PRODUCT_BUNDLE_IDENTIFIER) + CFBundleInfoDictionaryVersion + 6.0 + CFBundleName + $(PRODUCT_NAME) + CFBundlePackageType + BNDL + CFBundleShortVersionString + 1.0 + CFBundleVersion + 1 + + diff --git "a/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/meetingRooms_userdfault/meetingRoomsTests/meetingRoomsTests.swift" "b/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/meetingRooms_userdfault/meetingRoomsTests/meetingRoomsTests.swift" new file mode 100644 index 0000000..bfbd8d6 --- /dev/null +++ "b/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/meetingRooms_userdfault/meetingRoomsTests/meetingRoomsTests.swift" @@ -0,0 +1,36 @@ +// +// meetingRoomsTests.swift +// meetingRoomsTests +// +// Created by 황도증 on 2017. 10. 30.. +// Copyright © 2017년 황도증. All rights reserved. +// + +import XCTest +@testable import meetingRooms + +class meetingRoomsTests: XCTestCase { + + override func setUp() { + super.setUp() + // Put setup code here. This method is called before the invocation of each test method in the class. + } + + override func tearDown() { + // Put teardown code here. This method is called after the invocation of each test method in the class. + super.tearDown() + } + + func testExample() { + // This is an example of a functional test case. + // Use XCTAssert and related functions to verify your tests produce the correct results. + } + + func testPerformanceExample() { + // This is an example of a performance test case. + self.measure { + // Put the code you want to measure the time of here. + } + } + +} diff --git "a/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/meetingRooms_userdfault/meetingRoomsUITests/Info.plist" "b/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/meetingRooms_userdfault/meetingRoomsUITests/Info.plist" new file mode 100644 index 0000000..6c40a6c --- /dev/null +++ "b/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/meetingRooms_userdfault/meetingRoomsUITests/Info.plist" @@ -0,0 +1,22 @@ + + + + + CFBundleDevelopmentRegion + $(DEVELOPMENT_LANGUAGE) + CFBundleExecutable + $(EXECUTABLE_NAME) + CFBundleIdentifier + $(PRODUCT_BUNDLE_IDENTIFIER) + CFBundleInfoDictionaryVersion + 6.0 + CFBundleName + $(PRODUCT_NAME) + CFBundlePackageType + BNDL + CFBundleShortVersionString + 1.0 + CFBundleVersion + 1 + + diff --git "a/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/meetingRooms_userdfault/meetingRoomsUITests/meetingRoomsUITests.swift" "b/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/meetingRooms_userdfault/meetingRoomsUITests/meetingRoomsUITests.swift" new file mode 100644 index 0000000..4873bfa --- /dev/null +++ "b/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/meetingRooms_userdfault/meetingRoomsUITests/meetingRoomsUITests.swift" @@ -0,0 +1,36 @@ +// +// meetingRoomsUITests.swift +// meetingRoomsUITests +// +// Created by 황도증 on 2017. 10. 30.. +// Copyright © 2017년 황도증. All rights reserved. +// + +import XCTest + +class meetingRoomsUITests: XCTestCase { + + override func setUp() { + super.setUp() + + // Put setup code here. This method is called before the invocation of each test method in the class. + + // In UI tests it is usually best to stop immediately when a failure occurs. + continueAfterFailure = false + // UI tests must launch the application that they test. Doing this in setup will make sure it happens for each test method. + XCUIApplication().launch() + + // In UI tests it’s important to set the initial state - such as interface orientation - required for your tests before they run. The setUp method is a good place to do this. + } + + override func tearDown() { + // Put teardown code here. This method is called after the invocation of each test method in the class. + super.tearDown() + } + + func testExample() { + // Use recording to get started writing UI tests. + // Use XCTAssert and related functions to verify your tests produce the correct results. + } + +} diff --git "a/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/methods.playground/Contents.swift" "b/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/methods.playground/Contents.swift" new file mode 100644 index 0000000..de21388 --- /dev/null +++ "b/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/methods.playground/Contents.swift" @@ -0,0 +1,130 @@ +//: Playground - noun: a place where people can play + +import UIKit + +/*메소드란 인스턴스 안에 종속된 함수 + 인스턴스에서 필요한 기능들 함수로 만들어 넣은 것 + 클래스, 구조체, 이너머레이션 모두 인스턴스 메소드를 가질 수 있다 + self는 그 자신을 가리킨다 + */ + +struct Task { + var title:String + var time:Int? + + var owner:Employee + var participant:Employee? + + var type:TaskType + enum TaskType { + case Call + case Report + case Meet + case Support + + var typeTitle:String { + get { + let titleString:String + switch self { + case .Call: + titleString = "Call" + case .Report: + titleString = "Report" + case .Meet: + titleString = "Meet" + case .Support: + titleString = "Support" + } + return titleString + } + } + } + + init(type:TaskType, owner:Employee) { + self.type = type + self.title = type.typeTitle + self.owner = owner + self.time = nil + self.participant = nil + } +} + +class Employee { + var name:String? + var phoneNumber:String? + var boss:Employee? + + init (name:String) { + self.name = name + } + + init(name:String, phone:String) { + self.name = name + self.phoneNumber = phone + } + + func report() { + if let myBoss = boss { + print("\(name!) reported to \(myBoss).") + } else { + print("\(name!) don't have a boss.") + } + } + + func callTaskToBoss() -> Task? { + if let myBoss = boss { + let callTask = Task(type: .Call, owner:self) + return callTask + } + return nil + } +} +var todayTask:[Task] = [] + +let me:Employee = Employee(name: "Alex", phone:"010-3398-8792") +let toby = Employee(name: "Toby") +toby.phoneNumber = "010-3392-8765" +me.boss = toby + +var reportTask = Task(type:.Report, owner:me) +todayTask += [reportTask] + +if let callTask = me.callTaskToBoss() { + todayTask += [callTask] +} + +todayTask[1].time = 15*60 + +print("Today task = \(todayTask)") + + +/*Driving struct에 car가 운행을 마칠 때 마다 car에 로그를 남기는 기능을 추가하려고 합니다. Driving 인스턴스를 매개변수로 받아 drivingLog 배열에 추가하고, mileage에 운행거리를 더하는 addLog함수를 Car 클래스에 더해보세요. addLog 함수에서 Driving 인스턴스를 매개변수로 받은 후 인스턴스를 drivingLog에 추가하고 mileage에 운행거리를 더하면 됩니다 */ + +class Car { + var drivingLog:[Driving] = [] + var mileage:Int = 0 + + // 매개변수로 Driving 인스턴스를 받으세요 + func addLog(driving:Driving) { + // 인자를 drivingLog 배열에 추가하세요 + drivingLog += [driving] + // mileage에 운행거리를 더하세요 + mileage += driving.distance + } +} + +struct Driving { + let car:Car + let distance:Int //운행 거리 + + func arrived() { + car.addLog(driving: self) + } +} + +let truck = Car() +let deliver = Driving(car: truck, distance:30) +deliver.arrived() + +print(truck.drivingLog) +print(truck.mileage) diff --git "a/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/methods.playground/contents.xcplayground" "b/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/methods.playground/contents.xcplayground" new file mode 100644 index 0000000..5da2641 --- /dev/null +++ "b/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/methods.playground/contents.xcplayground" @@ -0,0 +1,4 @@ + + + + \ No newline at end of file diff --git "a/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/methods.playground/playground.xcworkspace/contents.xcworkspacedata" "b/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/methods.playground/playground.xcworkspace/contents.xcworkspacedata" new file mode 100644 index 0000000..919434a --- /dev/null +++ "b/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/methods.playground/playground.xcworkspace/contents.xcworkspacedata" @@ -0,0 +1,7 @@ + + + + + diff --git "a/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/methods.playground/timeline.xctimeline" "b/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/methods.playground/timeline.xctimeline" new file mode 100644 index 0000000..b8f966b --- /dev/null +++ "b/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/methods.playground/timeline.xctimeline" @@ -0,0 +1,16 @@ + + + + + + + + + diff --git "a/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/reduce.playground/Contents.swift" "b/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/reduce.playground/Contents.swift" new file mode 100644 index 0000000..c88809f --- /dev/null +++ "b/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/reduce.playground/Contents.swift" @@ -0,0 +1,44 @@ +//: Playground - noun: a place where people can play + +import UIKit + +/*하나의 값으로 수렴하도록 할 때 사용하는 함수. 배열과 병합에 사용하는 함수를 매개변수로 받아서 하나의 값을 결과로 리턴한다. 개발 시 사용하는 많은 작업들은 reduce 함수를 이용해 해결할 수 있다 + + transaction의 총합을 구하기 + base는 시작 값이며 adder는 이번에 더할 값 + 축약 시 병합원칙을 간단한 오퍼레이터로 제공할 수 있다. + */ +let transactions = [600.0, 403.3, 408.3, 562.3, 902.2] + +func addVAT (source: Double) -> Double { + return source * 1.1 +} + +var vatPrices:[Double] = [] + +for transaction in transactions { + vatPrices += [addVAT(source: transaction)] +} + +func priceSum (base:Double, adder:Double) -> Double { + return base + adder +} + +var sum:Double = 0.0 +for price in vatPrices { + sum = priceSum(base: sum, adder: price) +} + +//reduce를 활용 +var sum2:Double = 0.0 +let sumReduce1 = vatPrices.reduce(0.0, priceSum) +let sumReduce2 = vatPrices.reduce(sum2, {base, adder in base + adder} ) +let sumReduce3 = vatPrices.reduce(0.0, +) + +// Double 배열로 하나의 문자열 만들기. 배열의 값을 이용해 하나의 문자열을 만들 때 reduce 함수 사용 가능 +let pricesString = vatPrices.reduce("", {$0 + "\($1)\n"}) +print(pricesString) + +//meetingRooms의 키, 값을 이용해 하나의 문자열 만들기. 시작할 문자열을 base 값으로 제공. 더해질 문자열을 adder로 제공 +var meetingRooms:[String:Int] = ["A":10, "B":20, "C":30, "D":40] +let desxriptionString = meetingRooms.reduce("We have meeting rooms : \n", {$0 + "\($1.key) for \($1.value) persons \n"}) diff --git "a/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/reduce.playground/contents.xcplayground" "b/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/reduce.playground/contents.xcplayground" new file mode 100644 index 0000000..5da2641 --- /dev/null +++ "b/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/reduce.playground/contents.xcplayground" @@ -0,0 +1,4 @@ + + + + \ No newline at end of file diff --git "a/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/reduce.playground/playground.xcworkspace/contents.xcworkspacedata" "b/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/reduce.playground/playground.xcworkspace/contents.xcworkspacedata" new file mode 100644 index 0000000..919434a --- /dev/null +++ "b/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/reduce.playground/playground.xcworkspace/contents.xcworkspacedata" @@ -0,0 +1,7 @@ + + + + + diff --git "a/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/reduce.playground/timeline.xctimeline" "b/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/reduce.playground/timeline.xctimeline" new file mode 100644 index 0000000..f0062b6 --- /dev/null +++ "b/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/reduce.playground/timeline.xctimeline" @@ -0,0 +1,16 @@ + + + + + + + + + diff --git "a/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/sort.playground/Contents.swift" "b/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/sort.playground/Contents.swift" new file mode 100644 index 0000000..b557368 --- /dev/null +++ "b/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/sort.playground/Contents.swift" @@ -0,0 +1,39 @@ +//: Playground - noun: a place where people can play + +import UIKit + +/*고차함수 sort 함수는 배열과 정렬 조건이 있는 함수를 매개변수로 받아서, 정렬방식에 적당하게 정렬된 새로운 배열을 만드는 함수이다. + + ascendant는 < 을 사용하며 작은 것부터 큰 순으로 정렬됩니다. 비디오에서처럼 >를 사용하면 descendant 정렬이 됩니다 + + transaction을 크기에 따라 정렬하기 + 두 개의 값을 비교하는 정렬 기준을 함수로 제공 + 적용 시 조건에 따라 정렬된 배열 생성 + meetingRooms를 정원 순으로 정렬하기 + 딕셔너리에 sort를 적용하면 튜플의 배열로 변환 + meetingRooms의 value는 튜플에서 .1로 접근 가능 + */ +let transactions = [600.0, 403.3, 408.3, 562.3, 902.2] + +func addVAT (source: Double) -> Double { + return source * 1.1 +} + +var vatPrices:[Double] = [] + +for transaction in transactions { + vatPrices += [addVAT(source: transaction)] +} + +func ascedantSort (sort1:Double, sort2:Double) -> Bool { + return sort1 > sort2 +} + +let sortedPrice = vatPrices.sorted(by: ascedantSort) + +let sortedPrices2 = vatPrices.sorted(by: { sort1, sort2 in + return sort1 > sort2}) + +let sortedPrices3 = vatPrices.sorted(by: { $0 > $1 }) + +print("\(sortedPrices3)") diff --git "a/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/sort.playground/contents.xcplayground" "b/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/sort.playground/contents.xcplayground" new file mode 100644 index 0000000..5da2641 --- /dev/null +++ "b/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/sort.playground/contents.xcplayground" @@ -0,0 +1,4 @@ + + + + \ No newline at end of file diff --git "a/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/sort.playground/playground.xcworkspace/contents.xcworkspacedata" "b/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/sort.playground/playground.xcworkspace/contents.xcworkspacedata" new file mode 100644 index 0000000..919434a --- /dev/null +++ "b/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/sort.playground/playground.xcworkspace/contents.xcworkspacedata" @@ -0,0 +1,7 @@ + + + + + diff --git "a/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/sort.playground/timeline.xctimeline" "b/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/sort.playground/timeline.xctimeline" new file mode 100644 index 0000000..6b64abc --- /dev/null +++ "b/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/sort.playground/timeline.xctimeline" @@ -0,0 +1,16 @@ + + + + + + + + + diff --git "a/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/\352\263\240\354\260\250\354\233\220\355\225\250\354\210\230 \355\200\264\354\246\210/hanme quiz answer.playground/Contents.swift" "b/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/\352\263\240\354\260\250\354\233\220\355\225\250\354\210\230 \355\200\264\354\246\210/hanme quiz answer.playground/Contents.swift" new file mode 100644 index 0000000..aea7c6f --- /dev/null +++ "b/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/\352\263\240\354\260\250\354\233\220\355\225\250\354\210\230 \355\200\264\354\246\210/hanme quiz answer.playground/Contents.swift" @@ -0,0 +1,110 @@ +//: Playground - noun: a place where people can play + +import UIKit + + +//quiz 1 for loop + + +let startNum = [1.0,2.0,3.0,4.0,5.0] + +func addNum(source:Double) -> Double { + return source + 5 +} +/* +var endNum:[Double] = [] + +for num in startNum { + endNum += [addNum(source:num)] + print("\(num) have 5 more than startNum") +} +*/ + +var endNum:[Double] = [] +let a = startNum.map({let a = $0 + print("\(addNum(source: a)) have 5 more than StartNum") + endNum.append(addNum(source: a)) +}) + + + +//quiz 2 + +var biggerNum:[Double] = [] +/* +for num in endNum { + if num >= 7 { + biggerNum += [num] + } +} +*/ +endNum.map({ + let a = $0 + if a >= 7 { + biggerNum += [a] + } }) +print("\(biggerNum)") + + + +//quiz 3 +func numSum (base:Double, adder:Double) -> Double { + return base + adder +} + +var sum:Double = 0.0 +/* +for num in biggerNum { + sum = numSum(base:sum, adder:num) +} + */ +biggerNum.map({ let a = $0 + sum = numSum(base:sum, adder:a) +}) + +//add 50 at sum of biggerNum +var add50More = 50.0 + +print("\(sum)") + +// Quiz 4 + +let list4: [Double] = [10, 15, 20, 100, 150] +var result4: [Double] = [] +func reproduceSelf (input: Double)->Double{ + return Double(pow(input,2)+input) +} +/*for item in list4 { + result4.append(reproduceSelf(input: item)) +}*/ + +list4.map({ + let a = $0 + result4.append(reproduceSelf(input: a))}) +print("list4 is reproduced as \(result4)") + + +//Quiz 5 +let list5: [Int] = [2, 3, 9, 16, 20] +var sum5: Int = 0 +var result5: [Int] = [] + +/*for item in list5{ + sum5 += item + result5.append(sum5) +} +*/ +list5.map({ + let a = $0 + sum5 += a + result5.append(sum5) +}) +print ("Here are Sums of list5 step by step \(result5)") + + + + + + + + diff --git "a/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/\352\263\240\354\260\250\354\233\220\355\225\250\354\210\230 \355\200\264\354\246\210/hanme quiz answer.playground/contents.xcplayground" "b/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/\352\263\240\354\260\250\354\233\220\355\225\250\354\210\230 \355\200\264\354\246\210/hanme quiz answer.playground/contents.xcplayground" new file mode 100644 index 0000000..5da2641 --- /dev/null +++ "b/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/\352\263\240\354\260\250\354\233\220\355\225\250\354\210\230 \355\200\264\354\246\210/hanme quiz answer.playground/contents.xcplayground" @@ -0,0 +1,4 @@ + + + + \ No newline at end of file diff --git "a/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/\352\263\240\354\260\250\354\233\220\355\225\250\354\210\230 \355\200\264\354\246\210/hanme quiz answer.playground/playground.xcworkspace/contents.xcworkspacedata" "b/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/\352\263\240\354\260\250\354\233\220\355\225\250\354\210\230 \355\200\264\354\246\210/hanme quiz answer.playground/playground.xcworkspace/contents.xcworkspacedata" new file mode 100644 index 0000000..919434a --- /dev/null +++ "b/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/\352\263\240\354\260\250\354\233\220\355\225\250\354\210\230 \355\200\264\354\246\210/hanme quiz answer.playground/playground.xcworkspace/contents.xcworkspacedata" @@ -0,0 +1,7 @@ + + + + + diff --git "a/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/\352\263\240\354\260\250\354\233\220\355\225\250\354\210\230 \355\200\264\354\246\210/hanme quiz.playground/Contents.swift" "b/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/\352\263\240\354\260\250\354\233\220\355\225\250\354\210\230 \355\200\264\354\246\210/hanme quiz.playground/Contents.swift" new file mode 100755 index 0000000..92d0f9b --- /dev/null +++ "b/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/\352\263\240\354\260\250\354\233\220\355\225\250\354\210\230 \355\200\264\354\246\210/hanme quiz.playground/Contents.swift" @@ -0,0 +1,89 @@ +//: Playground - noun: a place where people can play + +import UIKit + + +//quiz 1 for loop + + +let startNum = [1.0,2.0,3.0,4.0,5.0] + +func addNum(source:Double) -> Double { + return source + 5 +} + + +var endNum:[Double] = [] + + +for num in startNum { + + endNum += [addNum(source:num)] + print("\(num) have 5 more than startNum") + +} + + + + +//quiz 2 + + +var biggerNum:[Double] = [] + +for num in endNum { + if num >= 7 { + biggerNum += [num] + } +} + +print("\(biggerNum)") + + + +//quiz 3 + +func numSum (base:Double, adder:Double) -> Double { + return base + adder +} + +var sum:Double = 0.0 +for num in biggerNum { + sum = numSum(base:sum, adder:num) +} + + +//add 50 at sum of biggerNum +var add50More = 50.0 + +print("\(sum)") + +// Quiz 4 + +let list4: [Double] = [10, 15, 20, 100, 150] +var result4: [Double] = [] +func reproduceSelf (input: Double)->Double{ + return Double(pow(input,2)+input) +} +for item in list4 { + result4.append(reproduceSelf(input: item)) +} +print ("list4 is reproduced as \(result4)") + + +//Quiz 5 +let list5: [Int] = [2, 3, 9, 16, 20] +var sum5: Int = 0 +var result5: [Int] = [] +for item in list5{ + sum5 += item + result5.append(sum5) +} +print ("Here are Sums of list5 step by step \(result5)") + + + + + + + diff --git "a/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/\352\263\240\354\260\250\354\233\220\355\225\250\354\210\230 \355\200\264\354\246\210/hanme quiz.playground/contents.xcplayground" "b/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/\352\263\240\354\260\250\354\233\220\355\225\250\354\210\230 \355\200\264\354\246\210/hanme quiz.playground/contents.xcplayground" new file mode 100755 index 0000000..5da2641 --- /dev/null +++ "b/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/\352\263\240\354\260\250\354\233\220\355\225\250\354\210\230 \355\200\264\354\246\210/hanme quiz.playground/contents.xcplayground" @@ -0,0 +1,4 @@ + + + + \ No newline at end of file diff --git "a/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/\352\263\240\354\260\250\354\233\220\355\225\250\354\210\230 \355\200\264\354\246\210/hanme quiz.playground/playground.xcworkspace/contents.xcworkspacedata" "b/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/\352\263\240\354\260\250\354\233\220\355\225\250\354\210\230 \355\200\264\354\246\210/hanme quiz.playground/playground.xcworkspace/contents.xcworkspacedata" new file mode 100644 index 0000000..919434a --- /dev/null +++ "b/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/\352\263\240\354\260\250\354\233\220\355\225\250\354\210\230 \355\200\264\354\246\210/hanme quiz.playground/playground.xcworkspace/contents.xcworkspacedata" @@ -0,0 +1,7 @@ + + + + + diff --git "a/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/\352\263\240\354\260\250\354\233\220\355\225\250\354\210\230 \355\200\264\354\246\210/my quiz answer.playground/Contents.swift" "b/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/\352\263\240\354\260\250\354\233\220\355\225\250\354\210\230 \355\200\264\354\246\210/my quiz answer.playground/Contents.swift" new file mode 100644 index 0000000..54fc5b3 --- /dev/null +++ "b/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/\352\263\240\354\260\250\354\233\220\355\225\250\354\210\230 \355\200\264\354\246\210/my quiz answer.playground/Contents.swift" @@ -0,0 +1,50 @@ +//: Playground - noun: a place where people can play + +import UIKit + +//quiz 1 +let hoody = ["구진선", "황도증", "임새로미", "하한메"] +for receiver in hoody { + print(receiver + " received hoody") +} + +//quiz 2 +let num = [1, 2, 3, 4, 5] +for bigNum in num { + if bigNum > 3 { + print("\(bigNum) is bigger than 3") + } else { + print("\(bigNum) is less than 3") + } +} + +//quiz 3 +var personHeight:[String:Int] = ["황도증":175, "하한메":182, "정윤지":167, "윤성관":170] +let standard = 170 +for height in personHeight { + if height.value > standard { + print("\(height.key) is over 170cm") + } +} + +//quiz 4 +var hoodyname3:[String] = [] + +for receiver in hoody{ + if receiver.count==3 { + hoodyname3.append(receiver) + } + else{} +} + +print(hoodyname3) + + +//Quiz 5 +var transactions:[Int] = [1, 1, 1, 1, 1] +for var i in (1.. + + + \ No newline at end of file diff --git "a/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/\352\263\240\354\260\250\354\233\220\355\225\250\354\210\230 \355\200\264\354\246\210/my quiz answer.playground/playground.xcworkspace/contents.xcworkspacedata" "b/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/\352\263\240\354\260\250\354\233\220\355\225\250\354\210\230 \355\200\264\354\246\210/my quiz answer.playground/playground.xcworkspace/contents.xcworkspacedata" new file mode 100644 index 0000000..919434a --- /dev/null +++ "b/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/\352\263\240\354\260\250\354\233\220\355\225\250\354\210\230 \355\200\264\354\246\210/my quiz answer.playground/playground.xcworkspace/contents.xcworkspacedata" @@ -0,0 +1,7 @@ + + + + + diff --git "a/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/\352\263\240\354\260\250\354\233\220\355\225\250\354\210\230 \355\200\264\354\246\210/my quiz answer.playground/timeline.xctimeline" "b/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/\352\263\240\354\260\250\354\233\220\355\225\250\354\210\230 \355\200\264\354\246\210/my quiz answer.playground/timeline.xctimeline" new file mode 100644 index 0000000..28800e0 --- /dev/null +++ "b/\352\260\225\354\235\230 \355\224\204\353\241\234\354\240\235\355\212\270 \355\214\214\354\235\274/\352\263\240\354\260\250\354\233\220\355\225\250\354\210\230 \355\200\264\354\246\210/my quiz answer.playground/timeline.xctimeline" @@ -0,0 +1,11 @@ + + + + + + +