This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
internal struct InternalConstants { | |
private class EmptyClass {} | |
static let bundle = Bundle(for: InternalConstants.EmptyClass.self) | |
} |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
@IBOutlet weak var imageView: UIImageView! | |
func setImageToImageView() { | |
fetchImage { (imageData) in | |
if let data = imageData { | |
DispatchQueue.main.async { | |
self.imageView.image = UIImage(data: data) | |
} | |
} else { | |
print("Hello"); |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
static func getEpochBeginningOfToday(isTomorrow: Bool) -> Int? { | |
var date = Date() | |
if isTomorrow { | |
guard let tomorrowDate = Calendar.current.date(byAdding: .day, value: 1, to: date) else { | |
return nil | |
} | |
date = tomorrowDate | |
} |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
package PrinFoodPlus.Utils; | |
import PrinFoodPlus.Controller; | |
import javafx.application.Platform; | |
import javafx.scene.control.Alert; | |
import javafx.scene.control.ButtonType; | |
import java.text.ParseException; | |
import java.text.SimpleDateFormat; | |
import java.util.Calendar; |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
let image1 = UIImage(named: "img1.jpg") | |
let data1 = UIImagePNGRepresentation(image1) | |
let file1 = PFFile(name: "img1", data: data1) | |
let image1 = UIImage(named: "img2.jpg") | |
let data2 = UIImagePNGRepresentation(image1) | |
let file2 = PFFile(name: "img2", data: data2) | |
let parseObj = PFObject(className: "testClass") | |
parseObj["text"] = "hello" |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<!doctype html> | |
<html> | |
<head> | |
<meta charset="UTF-8"> | |
<title>Untitled Document</title> | |
<script type="text/javascript" src="http://ajax.googleapis.com/ajax/libs/jquery/1.7.2/jquery.min.js"></script> | |
<script type="text/javascript" src="https://npmcdn.com/parse/dist/parse.min.js"></script> | |
<script> | |
Parse.initialize("518e0dbca14e73748f81e550e12deea515ff959e"); | |
Parse.serverURL = 'http://ec2-35-165-199-91.us-west-2.compute.amazonaws.com:80/parse'; |