Value object that depends on system time:
<?php
declare(strict_types=1);
namespace Xthiago;
final class BirthDate
<?php | |
class Users extends DataBase { | |
public $id; | |
public $email; | |
public $birthDate; | |
public $fullName; | |
public $city; | |
public $state; |
<?php | |
include '../vendor/autoload.php'; | |
$classLoader = new \Doctrine\Common\ClassLoader('Entities', __DIR__); | |
$classLoader->register(); | |
$classLoader = new \Doctrine\Common\ClassLoader('Proxies', __DIR__); | |
$classLoader->register(); | |
// config | |
$config = new \Doctrine\ORM\Configuration(); |
# (Re)create the index | |
curl -X DELETE "http://localhost:9200/tagcloud" | |
curl -X PUT "http://localhost:9200/tagcloud"-d '{ | |
"settings" : { | |
"index" : { | |
"number_of_shards" : 1, | |
"number_of_replicas" : 0 | |
} | |
} | |
}' |
<?php | |
/** | |
* @PeopleAnnotation(description="Get all information about a people", type="class") | |
*/ | |
class People { | |
/** | |
* @PeopleAnnotation(description="Use to people name", type="attribute") | |
*/ |
Value object that depends on system time:
<?php
declare(strict_types=1);
namespace Xthiago;
final class BirthDate
// the wizare functions | |
var sendString = (function(rfb, force, sendDelay) { | |
sendDelay = sendDelay || 25; | |
var _q = []; | |
var _qStart = function() { | |
var chr = _q.shift(); | |
if (chr) { | |
rfb.sendKey(chr); | |
setTimeout(_qStart, sendDelay); | |
} |
import com.amazonaws.services.s3._, model._ | |
import com.amazonaws.auth.BasicAWSCredentials | |
val request = new ListObjectsRequest() | |
request.setBucketName(bucket) | |
request.setPrefix(prefix) | |
request.setMaxKeys(pageLength) | |
def s3 = new AmazonS3Client(new BasicAWSCredentials(key, secret)) | |
val objs = s3.listObjects(request) // Note that this method returns truncated data if longer than the "pageLength" above. You might need to deal with that. |
import org.apache.spark.sql.functions._ | |
import org.apache.spark.sql.SparkSession | |
object DataFrameWithFileNameApp extends App { | |
val spark: SparkSession = | |
SparkSession | |
.builder() | |
.appName("DataFrameApp") | |
.config("spark.master", "local[*]") |
git config --global alias.cowsay '!git commit -m "`fortune | cowsay -f tux`"' |