feat: init TLEPlainString

This commit is contained in:
angelina-tsuboi
2023-05-05 21:32:59 -07:00
parent 2e2ea259be
commit 74abc4404f
+26 -6
View File
@@ -85,7 +85,6 @@ func TLETextFile() {
output = ConstructTLE("UNSPECIFIED", txtlines[0], txtlines[1])
}
fmt.Println(count, output)
PrintTLE(output)
}
@@ -117,9 +116,31 @@ func ConstructTLE(one string, two string, three string) TLE {
}
func TLEPlainString(){
fmt.Print("\n ENTER TLE > ")
var tleString string
fmt.Scanln(&tleString)
scanner := bufio.NewScanner(os.Stdin)
var lineOne string
var lineTwo string
var lineThree string
fmt.Print("\n ENTER LINE ONE (leave blank for unspecified name) > ")
scanner.Scan()
lineOne = scanner.Text()
fmt.Print("\n ENTER LINE TWO > ")
scanner.Scan()
lineTwo = scanner.Text()
fmt.Print("\n ENTER LINE THREE > ")
scanner.Scan()
lineThree = scanner.Text()
if (lineOne == "") {
lineOne = "UNSPECIFIED"
}
output := TLE{}
output = ConstructTLE(lineOne, lineTwo, lineThree)
PrintTLE(output)
}
// TODO: Right Ascension of Ascending Node (degrees)
@@ -175,5 +196,4 @@ func Option(min int, max int) int {
return Option(min, max)
}
}
}
}