code stringlengths 3 10M | language stringclasses 31 values |
|---|---|
module dopus.lister.actions.deleteaction;
import dopus;
import dopus.lister.actions;
import gtkd.x.treeselection;
import std.file;
static this()
{
ListerActions.register!DeleteAction;
}
class DeleteAction : SimpleAction
{
this(Lister lister)
{
super("delete", null);
addOnActivate(delegate(Variant, SimpleAction) {
foreach (file; lister.getSelectedFiles)
{
import std.stdio : writeln;
writeln(file);
import std.file : isDir;
auto h = file.unescape;
if (h.isDir)
{
h.rmdirRecurse;
}
else
{
h.remove;
}
lister.refresh();
}
});
}
}
| D |
module rocl.controls.login;
import std, perfontain, rocl;
final class WinLogin : RCounted
{
void draw()
{
if (_adding || accounts.empty)
drawAddAccount;
else
drawAccountSelection;
}
private:
mixin NuklearBase;
@property ref accounts()
{
return PE.settings.accounts;
}
void drawFields()
{
nk.layout_row_dynamic(nk.editHeight, 2);
nk.label(MSG_USERNAME ~ ':', NK_TEXT_CENTERED);
nk.edit_string(NK_EDIT_FIELD, _user.ptr, &_userLen, cast(uint)_user.length, null);
nk.label(MSG_PASSWORD ~ ':', NK_TEXT_CENTERED);
nk.edit_string(NK_EDIT_FIELD, _pass.ptr, &_passLen, cast(uint)_pass.length, null);
}
auto make(string title, ushort height)
{
auto ws = PE.window.size;
auto sz = Vector2s(300, height);
auto rect = nk_rect((ws.x - sz.x) / 2, ws.y * 2 / 3 - sz.y / 2, sz.x, sz.y);
return Window(title, rect,
Window.DEFAULT_FLAGS & ~NK_WINDOW_MINIMIZABLE | NK_WINDOW_CLOSABLE);
}
void drawAddAccount()
{
if (auto win = make(MSG_ADDING, 150))
{
drawFields;
nk.layout_row_dynamic(0, 2);
nk.spacing(1);
if (nk.button(MSG_ADD) && _userLen)
{
auto user = _user[0 .. _userLen].idup;
auto pass = _pass[0 .. _passLen].idup;
_userLen = 0;
_passLen = 0;
_adding = false;
accounts ~= ElementType!(typeof(accounts))(user, pass);
}
}
if (nk.window_is_hidden(MSG_ADDING.toStringz))
{
if (_adding)
_adding = false;
else
PE.quit;
}
}
void drawAccountSelection()
{
if (auto win = make(MSG_LOGIN, 120))
{
nk.layout_row_dynamic(nk.comboHeight, 2);
nk.label(MSG_USERNAME ~ ':', NK_TEXT_CENTERED);
if (auto combo = Combo(accounts[_selected].user))
{
nk.layout_row_dynamic(combo.height, 1);
if (nk.button(MSG_ADD))
_adding = true;
enum X = `x`;
with (LayoutRowTemplate(combo.height))
{
dynamic;
static_(nk.buttonWidth(X));
}
foreach (i, acc; accounts)
{
if (combo.item(acc.user))
_selected = cast(ubyte)i;
if (nk.button(X))
accounts = accounts.remove(i);
}
}
nk.spacing(1);
if (nk.button(MSG_OK))
{
auto acc = accounts[_selected];
RO.gui.login = null; // TODO: rewrite
ROnet.login(acc.user, acc.pass);
return;
}
}
if (nk.window_is_hidden(MSG_LOGIN.toStringz))
PE.quit;
}
bool _adding;
ubyte _selected;
char[24] _user, _pass;
int _userLen, _passLen;
}
| D |
/*
* The MIT License (MIT)
*
* Copyright (c) 2014 Devisualization (Richard Andrew Cattermole)
*
* Permission is hereby granted, free of charge, to any person obtaining a copy
* of this software and associated documentation files (the "Software"), to deal
* in the Software without restriction, including without limitation the rights
* to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
* copies of the Software, and to permit persons to whom the Software is
* furnished to do so, subject to the following conditions:
*
* The above copyright notice and this permission notice shall be included in all
* copies or substantial portions of the Software.
*
* THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
* IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
* FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
* AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
* LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
* OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
* SOFTWARE.
*/
module devisualization.window.interfaces.eventable;
import std.string : toUpper;
import std.algorithm : filter, moveAll;
/**
* Provides an interface version of an eventing mechanism.
*
* See_Also:
* Eventing
*/
mixin template IEventing(string name, T...) {
mixin("void add" ~ toUpper(name[0] ~ "") ~ name[1 ..$] ~ q{(bool delegate(T));});
mixin("void add" ~ toUpper(name[0] ~ "") ~ name[1 ..$] ~ q{(void delegate(T));});
mixin("void remove" ~ toUpper(name[0] ~ "") ~ name[1 ..$] ~ q{(bool delegate(T));});
mixin("void remove" ~ toUpper(name[0] ~ "") ~ name[1 ..$] ~ q{(void delegate(T));});
mixin("size_t count" ~ toUpper(name[0] ~ "") ~ name[1 ..$] ~ "();");
mixin("void " ~ name ~ q{(T args);});
mixin("void clear" ~ toUpper(name[0] ~ "") ~ name[1 ..$] ~ q{();});
static if (T.length > 0) {
static if (__traits(compiles, typeof(this)) && is(typeof(this) : T[0])) {
mixin("void " ~ name ~ q{(T[1 .. $] args);});
}
}
}
/**
* Implements an eventable interface for something.
* Includes support for bool delegate(T) and void delegate(T).
* Will consume a call to all delegates if it returns true. Default false.
*
* Example usage:
* mixin Eventing!("onNewListing", ListableObject);
*
* If is(T[0] == typeof(this)) then it'll use this as being the first argument.
*/
mixin template Eventing(string name, T...) {
private {
mixin(q{bool delegate(T)[] } ~ name ~ "_;");
mixin(q{bool delegate(T)[void delegate(T)] } ~ name ~ "_assoc;");
}
mixin("void add" ~ toUpper(name[0] ~ "") ~ name[1 ..$] ~ q{(void delegate(T) value) {
mixin(name ~ "_ ~= (T args) => {value(args); return false;}();");
mixin(name ~ "_assoc[value] = " ~ name ~ "_[$-1];");
}});
mixin("void add" ~ toUpper(name[0] ~ "") ~ name[1 ..$] ~ q{(bool delegate(T) value) {
mixin(name ~ "_ ~= value;");
}});
mixin("void remove" ~ toUpper(name[0] ~ "") ~ name[1 ..$] ~ q{(bool delegate(T) value) {
mixin("moveAll(filter!(a => a !is value)(" ~ name ~ "_), " ~ name ~ "_);");
}});
mixin("void remove" ~ toUpper(name[0] ~ "") ~ name[1 ..$] ~ q{(void delegate(T) value) {
mixin("moveAll(filter!(a => (value in " ~ name ~ "_assoc && a !is " ~ name ~ "_assoc[value]) || (value !in " ~ name ~ "_assoc) )(" ~ name ~ "_), " ~ name ~ "_);");
}});
mixin("size_t count" ~ toUpper(name[0] ~ "") ~ name[1 ..$] ~ q{(){
return cast(size_t)(mixin(name ~ "_.length") + mixin(name ~ "_assoc.length"));
}});
mixin("void " ~ name ~ q{(T args) {
foreach (del; mixin(name ~ "_")) {
del(args);
}
}});
mixin("void clear" ~ toUpper(name[0] ~ "") ~ name[1 ..$] ~ q{() {
mixin(name ~ "_") = [];
}});
static if (__traits(compiles, typeof(this)) && is(typeof(this) : T[0])) {
mixin("void " ~ name ~ q{(T[1 .. $] args) {
foreach (del; mixin(name ~ "_")) {
if (del(this, args))
return;
}
}});
} else {
mixin("void " ~ name ~ q{(T args) {
foreach (del; mixin(name ~ "_")) {
if (del(args))
return;
}
}});
}
} | D |
/Users/HL/Documents/AppleBite/AxxessChallenge/build/Pods.build/Debug-iphonesimulator/Kingfisher.build/Objects-normal/x86_64/ImageView+Kingfisher.o : /Users/HL/Documents/AppleBite/AxxessChallenge/Pods/Kingfisher/Sources/AnimatedImageView.swift /Users/HL/Documents/AppleBite/AxxessChallenge/Pods/Kingfisher/Sources/Box.swift /Users/HL/Documents/AppleBite/AxxessChallenge/Pods/Kingfisher/Sources/CacheSerializer.swift /Users/HL/Documents/AppleBite/AxxessChallenge/Pods/Kingfisher/Sources/Filter.swift /Users/HL/Documents/AppleBite/AxxessChallenge/Pods/Kingfisher/Sources/Image.swift /Users/HL/Documents/AppleBite/AxxessChallenge/Pods/Kingfisher/Sources/ImageCache.swift /Users/HL/Documents/AppleBite/AxxessChallenge/Pods/Kingfisher/Sources/ImageDownloader.swift /Users/HL/Documents/AppleBite/AxxessChallenge/Pods/Kingfisher/Sources/ImagePrefetcher.swift /Users/HL/Documents/AppleBite/AxxessChallenge/Pods/Kingfisher/Sources/ImageProcessor.swift /Users/HL/Documents/AppleBite/AxxessChallenge/Pods/Kingfisher/Sources/ImageTransition.swift /Users/HL/Documents/AppleBite/AxxessChallenge/Pods/Kingfisher/Sources/ImageView+Kingfisher.swift /Users/HL/Documents/AppleBite/AxxessChallenge/Pods/Kingfisher/Sources/Indicator.swift /Users/HL/Documents/AppleBite/AxxessChallenge/Pods/Kingfisher/Sources/Kingfisher.swift /Users/HL/Documents/AppleBite/AxxessChallenge/Pods/Kingfisher/Sources/KingfisherManager.swift /Users/HL/Documents/AppleBite/AxxessChallenge/Pods/Kingfisher/Sources/KingfisherOptionsInfo.swift /Users/HL/Documents/AppleBite/AxxessChallenge/Pods/Kingfisher/Sources/RequestModifier.swift /Users/HL/Documents/AppleBite/AxxessChallenge/Pods/Kingfisher/Sources/Resource.swift /Users/HL/Documents/AppleBite/AxxessChallenge/Pods/Kingfisher/Sources/String+MD5.swift /Users/HL/Documents/AppleBite/AxxessChallenge/Pods/Kingfisher/Sources/ThreadHelper.swift /Users/HL/Documents/AppleBite/AxxessChallenge/Pods/Kingfisher/Sources/UIButton+Kingfisher.swift /Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/lib/swift/iphonesimulator/x86_64/Swift.swiftmodule /Users/HL/Documents/AppleBite/AxxessChallenge/Pods/Kingfisher/Sources/Kingfisher.h /Users/HL/Documents/AppleBite/AxxessChallenge/Pods/Target\ Support\ Files/Kingfisher/Kingfisher-umbrella.h /Users/HL/Documents/AppleBite/AxxessChallenge/build/Pods.build/Debug-iphonesimulator/Kingfisher.build/unextended-module.modulemap /Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/lib/swift/iphonesimulator/x86_64/UIKit.swiftmodule /Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/lib/swift/iphonesimulator/x86_64/Foundation.swiftmodule /Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/lib/swift/iphonesimulator/x86_64/Darwin.swiftmodule /Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/lib/swift/iphonesimulator/x86_64/Dispatch.swiftmodule /Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/lib/swift/iphonesimulator/x86_64/ObjectiveC.swiftmodule /Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/lib/swift/iphonesimulator/x86_64/CoreGraphics.swiftmodule /Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/lib/swift/iphonesimulator/x86_64/QuartzCore.swiftmodule /Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/lib/swift/iphonesimulator/x86_64/CoreImage.swiftmodule /Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/lib/swift/iphonesimulator/x86_64/SwiftOnoneSupport.swiftmodule
/Users/HL/Documents/AppleBite/AxxessChallenge/build/Pods.build/Debug-iphonesimulator/Kingfisher.build/Objects-normal/x86_64/ImageView+Kingfisher~partial.swiftmodule : /Users/HL/Documents/AppleBite/AxxessChallenge/Pods/Kingfisher/Sources/AnimatedImageView.swift /Users/HL/Documents/AppleBite/AxxessChallenge/Pods/Kingfisher/Sources/Box.swift /Users/HL/Documents/AppleBite/AxxessChallenge/Pods/Kingfisher/Sources/CacheSerializer.swift /Users/HL/Documents/AppleBite/AxxessChallenge/Pods/Kingfisher/Sources/Filter.swift /Users/HL/Documents/AppleBite/AxxessChallenge/Pods/Kingfisher/Sources/Image.swift /Users/HL/Documents/AppleBite/AxxessChallenge/Pods/Kingfisher/Sources/ImageCache.swift /Users/HL/Documents/AppleBite/AxxessChallenge/Pods/Kingfisher/Sources/ImageDownloader.swift /Users/HL/Documents/AppleBite/AxxessChallenge/Pods/Kingfisher/Sources/ImagePrefetcher.swift /Users/HL/Documents/AppleBite/AxxessChallenge/Pods/Kingfisher/Sources/ImageProcessor.swift /Users/HL/Documents/AppleBite/AxxessChallenge/Pods/Kingfisher/Sources/ImageTransition.swift /Users/HL/Documents/AppleBite/AxxessChallenge/Pods/Kingfisher/Sources/ImageView+Kingfisher.swift /Users/HL/Documents/AppleBite/AxxessChallenge/Pods/Kingfisher/Sources/Indicator.swift /Users/HL/Documents/AppleBite/AxxessChallenge/Pods/Kingfisher/Sources/Kingfisher.swift /Users/HL/Documents/AppleBite/AxxessChallenge/Pods/Kingfisher/Sources/KingfisherManager.swift /Users/HL/Documents/AppleBite/AxxessChallenge/Pods/Kingfisher/Sources/KingfisherOptionsInfo.swift /Users/HL/Documents/AppleBite/AxxessChallenge/Pods/Kingfisher/Sources/RequestModifier.swift /Users/HL/Documents/AppleBite/AxxessChallenge/Pods/Kingfisher/Sources/Resource.swift /Users/HL/Documents/AppleBite/AxxessChallenge/Pods/Kingfisher/Sources/String+MD5.swift /Users/HL/Documents/AppleBite/AxxessChallenge/Pods/Kingfisher/Sources/ThreadHelper.swift /Users/HL/Documents/AppleBite/AxxessChallenge/Pods/Kingfisher/Sources/UIButton+Kingfisher.swift /Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/lib/swift/iphonesimulator/x86_64/Swift.swiftmodule /Users/HL/Documents/AppleBite/AxxessChallenge/Pods/Kingfisher/Sources/Kingfisher.h /Users/HL/Documents/AppleBite/AxxessChallenge/Pods/Target\ Support\ Files/Kingfisher/Kingfisher-umbrella.h /Users/HL/Documents/AppleBite/AxxessChallenge/build/Pods.build/Debug-iphonesimulator/Kingfisher.build/unextended-module.modulemap /Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/lib/swift/iphonesimulator/x86_64/UIKit.swiftmodule /Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/lib/swift/iphonesimulator/x86_64/Foundation.swiftmodule /Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/lib/swift/iphonesimulator/x86_64/Darwin.swiftmodule /Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/lib/swift/iphonesimulator/x86_64/Dispatch.swiftmodule /Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/lib/swift/iphonesimulator/x86_64/ObjectiveC.swiftmodule /Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/lib/swift/iphonesimulator/x86_64/CoreGraphics.swiftmodule /Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/lib/swift/iphonesimulator/x86_64/QuartzCore.swiftmodule /Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/lib/swift/iphonesimulator/x86_64/CoreImage.swiftmodule /Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/lib/swift/iphonesimulator/x86_64/SwiftOnoneSupport.swiftmodule
/Users/HL/Documents/AppleBite/AxxessChallenge/build/Pods.build/Debug-iphonesimulator/Kingfisher.build/Objects-normal/x86_64/ImageView+Kingfisher~partial.swiftdoc : /Users/HL/Documents/AppleBite/AxxessChallenge/Pods/Kingfisher/Sources/AnimatedImageView.swift /Users/HL/Documents/AppleBite/AxxessChallenge/Pods/Kingfisher/Sources/Box.swift /Users/HL/Documents/AppleBite/AxxessChallenge/Pods/Kingfisher/Sources/CacheSerializer.swift /Users/HL/Documents/AppleBite/AxxessChallenge/Pods/Kingfisher/Sources/Filter.swift /Users/HL/Documents/AppleBite/AxxessChallenge/Pods/Kingfisher/Sources/Image.swift /Users/HL/Documents/AppleBite/AxxessChallenge/Pods/Kingfisher/Sources/ImageCache.swift /Users/HL/Documents/AppleBite/AxxessChallenge/Pods/Kingfisher/Sources/ImageDownloader.swift /Users/HL/Documents/AppleBite/AxxessChallenge/Pods/Kingfisher/Sources/ImagePrefetcher.swift /Users/HL/Documents/AppleBite/AxxessChallenge/Pods/Kingfisher/Sources/ImageProcessor.swift /Users/HL/Documents/AppleBite/AxxessChallenge/Pods/Kingfisher/Sources/ImageTransition.swift /Users/HL/Documents/AppleBite/AxxessChallenge/Pods/Kingfisher/Sources/ImageView+Kingfisher.swift /Users/HL/Documents/AppleBite/AxxessChallenge/Pods/Kingfisher/Sources/Indicator.swift /Users/HL/Documents/AppleBite/AxxessChallenge/Pods/Kingfisher/Sources/Kingfisher.swift /Users/HL/Documents/AppleBite/AxxessChallenge/Pods/Kingfisher/Sources/KingfisherManager.swift /Users/HL/Documents/AppleBite/AxxessChallenge/Pods/Kingfisher/Sources/KingfisherOptionsInfo.swift /Users/HL/Documents/AppleBite/AxxessChallenge/Pods/Kingfisher/Sources/RequestModifier.swift /Users/HL/Documents/AppleBite/AxxessChallenge/Pods/Kingfisher/Sources/Resource.swift /Users/HL/Documents/AppleBite/AxxessChallenge/Pods/Kingfisher/Sources/String+MD5.swift /Users/HL/Documents/AppleBite/AxxessChallenge/Pods/Kingfisher/Sources/ThreadHelper.swift /Users/HL/Documents/AppleBite/AxxessChallenge/Pods/Kingfisher/Sources/UIButton+Kingfisher.swift /Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/lib/swift/iphonesimulator/x86_64/Swift.swiftmodule /Users/HL/Documents/AppleBite/AxxessChallenge/Pods/Kingfisher/Sources/Kingfisher.h /Users/HL/Documents/AppleBite/AxxessChallenge/Pods/Target\ Support\ Files/Kingfisher/Kingfisher-umbrella.h /Users/HL/Documents/AppleBite/AxxessChallenge/build/Pods.build/Debug-iphonesimulator/Kingfisher.build/unextended-module.modulemap /Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/lib/swift/iphonesimulator/x86_64/UIKit.swiftmodule /Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/lib/swift/iphonesimulator/x86_64/Foundation.swiftmodule /Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/lib/swift/iphonesimulator/x86_64/Darwin.swiftmodule /Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/lib/swift/iphonesimulator/x86_64/Dispatch.swiftmodule /Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/lib/swift/iphonesimulator/x86_64/ObjectiveC.swiftmodule /Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/lib/swift/iphonesimulator/x86_64/CoreGraphics.swiftmodule /Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/lib/swift/iphonesimulator/x86_64/QuartzCore.swiftmodule /Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/lib/swift/iphonesimulator/x86_64/CoreImage.swiftmodule /Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/lib/swift/iphonesimulator/x86_64/SwiftOnoneSupport.swiftmodule
| D |
module android.java.org.w3c.dom.Text_d_interface;
import arsd.jni : IJavaObjectImplementation, JavaPackageId, JavaName, IJavaObject, ImportExportImpl, JavaInterfaceMembers;
static import arsd.jni;
import import5 = android.java.org.w3c.dom.Document_d_interface;
import import2 = android.java.org.w3c.dom.Node_d_interface;
import import1 = android.java.java.lang.Class_d_interface;
import import3 = android.java.org.w3c.dom.NodeList_d_interface;
import import0 = android.java.org.w3c.dom.Text_d_interface;
import import4 = android.java.org.w3c.dom.NamedNodeMap_d_interface;
import import6 = android.java.org.w3c.dom.UserDataHandler_d_interface;
final class Text : IJavaObject {
static immutable string[] _d_canCastTo = [
"org/w3c/dom/CharacterData",
];
@Import import0.Text splitText(int);
@Import bool isElementContentWhitespace();
@Import string getWholeText();
@Import import0.Text replaceWholeText(string);
@Import import1.Class getClass();
@Import int hashCode();
@Import bool equals(IJavaObject);
@Import @JavaName("toString") string toString_();
override string toString() { return arsd.jni.javaObjectToString(this); }
@Import void notify();
@Import void notifyAll();
@Import void wait(long);
@Import void wait(long, int);
@Import void wait();
@Import string getData();
@Import void setData(string);
@Import int getLength();
@Import string substringData(int, int);
@Import void appendData(string);
@Import void insertData(int, string);
@Import void deleteData(int, int);
@Import void replaceData(int, int, string);
@Import string getNodeName();
@Import string getNodeValue();
@Import void setNodeValue(string);
@Import short getNodeType();
@Import import2.Node getParentNode();
@Import import3.NodeList getChildNodes();
@Import import2.Node getFirstChild();
@Import import2.Node getLastChild();
@Import import2.Node getPreviousSibling();
@Import import2.Node getNextSibling();
@Import import4.NamedNodeMap getAttributes();
@Import import5.Document getOwnerDocument();
@Import import2.Node insertBefore(import2.Node, import2.Node);
@Import import2.Node replaceChild(import2.Node, import2.Node);
@Import import2.Node removeChild(import2.Node);
@Import import2.Node appendChild(import2.Node);
@Import bool hasChildNodes();
@Import import2.Node cloneNode(bool);
@Import void normalize();
@Import bool isSupported(string, string);
@Import string getNamespaceURI();
@Import string getPrefix();
@Import void setPrefix(string);
@Import string getLocalName();
@Import bool hasAttributes();
@Import string getBaseURI();
@Import short compareDocumentPosition(import2.Node);
@Import string getTextContent();
@Import void setTextContent(string);
@Import bool isSameNode(import2.Node);
@Import string lookupPrefix(string);
@Import bool isDefaultNamespace(string);
@Import string lookupNamespaceURI(string);
@Import bool isEqualNode(import2.Node);
@Import IJavaObject getFeature(string, string);
@Import IJavaObject setUserData(string, IJavaObject, import6.UserDataHandler);
@Import IJavaObject getUserData(string);
mixin IJavaObjectImplementation!(false);
public static immutable string _javaParameterString = "Lorg/w3c/dom/Text;";
}
| D |
instance BDT_1074_Addon_Edgor (Npc_Default)
{
// ------ NSC ------
name = "Edgor";
guild = GIL_BDT;
id = 1074;
voice = 6;
flags = 0;
npctype = NPCTYPE_MAIN;
// ------ Attribute ------
B_SetAttributesToChapter (self, 4);
// ------ Kampf-Taktik ------
fight_tactic = FAI_HUMAN_NORMAL;
// ------ Equippte Waffen ------
EquipItem (self, ItMw_1h_Sld_Sword);
EquipItem (self, ItRw_Sld_Bow);
// ------ Inventory ------
B_CreateAmbientInv (self);
// ------ visuals ------
B_SetNpcVisual (self, MALE, "Hum_Head_Fighter", Face_N_NormalBart20, BodyTex_N, ITAR_BDT_M);
Mdl_SetModelFatness (self, 0);
Mdl_ApplyOverlayMds (self, "Humans_Arrogance.mds");
// ------ NSC-relevante Talente vergeben ------
B_GiveNpcTalents (self);
// ------ Kampf-Talente ------
B_SetFightSkills (self, 65);
// ------ TA anmelden ------
daily_routine = Rtn_Start_1074;
};
FUNC VOID Rtn_Start_1074 () //RUINE
{
TA_Sit_Campfire (09,00,12,00,"ADW_BANDIT_VP1_09");
TA_Sit_Campfire (12,00,09,00,"ADW_BANDIT_VP1_09");
};
| D |
// Copyright Vladimir Panteleev 2020
// Distributed under the Boost Software License, Version 1.0.
// (See accompanying file LICENSE_1_0.txt or copy at
// http://www.boost.org/LICENSE_1_0.txt)
module dscanner.analysis.unused_result;
import dscanner.analysis.base;
import dscanner.analysis.mismatched_args : resolveSymbol, IdentVisitor;
import dscanner.utils;
import dsymbol.scope_;
import dsymbol.symbol;
import dparse.ast, dparse.lexer;
import std.algorithm.searching : canFind;
import std.range: retro;
/**
* Checks for function call statements which call non-void functions.
*
* In case the function returns a value indicating success/failure,
* ignoring this return value and continuing execution can lead to
* undesired results.
*
* When the return value is intentionally discarded, `cast(void)` can
* be prepended to silence the check.
*/
final class UnusedResultChecker : BaseAnalyzer
{
alias visit = BaseAnalyzer.visit;
mixin AnalyzerInfo!"unused_result";
private:
enum string KEY = "dscanner.unused_result";
enum string MSG = "Function return value is discarded";
public:
const(DSymbol)* void_;
///
this(string fileName, const(Scope)* sc, bool skipTests = false)
{
super(fileName, sc, skipTests);
void_ = sc.getSymbolsByName(internString("void"))[0];
}
override void visit(const(ExpressionStatement) decl)
{
import std.typecons : scoped;
super.visit(decl);
if (!decl.expression)
return;
if (decl.expression.items.length != 1)
return;
auto ue = cast(UnaryExpression) decl.expression.items[0];
if (!ue)
return;
auto fce = ue.functionCallExpression;
if (!fce)
return;
auto identVisitor = scoped!IdentVisitor;
if (fce.unaryExpression !is null)
identVisitor.visit(fce.unaryExpression);
else if (fce.type !is null)
identVisitor.visit(fce.type);
if (!identVisitor.names.length)
return;
const(DSymbol)*[] symbols = resolveSymbol(sc, identVisitor.names);
if (!symbols.length)
return;
foreach (sym; symbols)
{
if (!sym)
return;
if (!sym.type)
return;
if (sym.kind != CompletionKind.functionName)
return;
if (sym.type is void_)
return;
}
addErrorMessage(decl.expression.line, decl.expression.column, KEY, MSG);
}
}
unittest
{
import dscanner.analysis.config : StaticAnalysisConfig, Check, disabledConfig;
import dscanner.analysis.helpers : assertAnalyzerWarnings;
import std.stdio : stderr;
import std.format : format;
StaticAnalysisConfig sac = disabledConfig();
sac.unused_result = Check.enabled;
assertAnalyzerWarnings(q{
void fun() {}
void main()
{
fun();
}
}c, sac);
assertAnalyzerWarnings(q{
int fun() { return 1; }
void main()
{
fun(); // [warn]: %s
}
}c.format(UnusedResultChecker.MSG), sac);
assertAnalyzerWarnings(q{
void main()
{
void fun() {}
fun();
}
}c, sac);
version (none) // TODO: local functions
assertAnalyzerWarnings(q{
void main()
{
int fun() { return 1; }
fun(); // [warn]: %s
}
}c.format(UnusedResultChecker.MSG), sac);
assertAnalyzerWarnings(q{
int fun() { return 1; }
void main()
{
cast(void) fun();
}
}c, sac);
assertAnalyzerWarnings(q{
void fun() { }
alias gun = fun;
void main()
{
gun();
}
}c, sac);
import std.stdio: writeln;
writeln("Unittest for UnusedResultChecker passed");
}
| D |
/Users/kelvintan/Desktop/MVP/Build/Intermediates.noindex/MVP.build/Debug-iphonesimulator/MVP.build/Objects-normal/x86_64/HomePresenter.o : /Users/kelvintan/Desktop/MVP/MVP/SceneDelegate.swift /Users/kelvintan/Desktop/MVP/MVP/AppDelegate.swift /Users/kelvintan/Desktop/MVP/MVP/View/Home/HomeTableViewCell.swift /Users/kelvintan/Desktop/MVP/MVP/Controller/Home/HomeViewController.swift /Users/kelvintan/Desktop/MVP/MVP/Controller/Detail/DetailViewController.swift /Users/kelvintan/Desktop/MVP/MVP/Presenter/HomePresenter.swift /Users/kelvintan/Desktop/MVP/MVP/Model/BucketList.swift /Users/kelvintan/Desktop/MVP/MVP/Extension/Date_Ext.swift /Users/kelvintan/Desktop/MVP/MVP/Extension/View_Ext.swift /Applications/Xcode_12.4.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/lib/swift/iphonesimulator/prebuilt-modules/ObjectiveC.swiftmodule/x86_64-apple-ios-simulator.swiftmodule /Applications/Xcode_12.4.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/lib/swift/iphonesimulator/prebuilt-modules/CoreImage.swiftmodule/x86_64-apple-ios-simulator.swiftmodule /Applications/Xcode_12.4.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/lib/swift/iphonesimulator/prebuilt-modules/Combine.swiftmodule/x86_64-apple-ios-simulator.swiftmodule /Applications/Xcode_12.4.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/lib/swift/iphonesimulator/prebuilt-modules/QuartzCore.swiftmodule/x86_64-apple-ios-simulator.swiftmodule /Applications/Xcode_12.4.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/lib/swift/iphonesimulator/prebuilt-modules/Dispatch.swiftmodule/x86_64-apple-ios-simulator.swiftmodule /Applications/Xcode_12.4.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/lib/swift/iphonesimulator/prebuilt-modules/Metal.swiftmodule/x86_64-apple-ios-simulator.swiftmodule /Applications/Xcode_12.4.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/lib/swift/iphonesimulator/prebuilt-modules/Darwin.swiftmodule/x86_64-apple-ios-simulator.swiftmodule /Applications/Xcode_12.4.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/lib/swift/iphonesimulator/prebuilt-modules/Foundation.swiftmodule/x86_64-apple-ios-simulator.swiftmodule /Applications/Xcode_12.4.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/lib/swift/iphonesimulator/prebuilt-modules/CoreFoundation.swiftmodule/x86_64-apple-ios-simulator.swiftmodule /Applications/Xcode_12.4.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/lib/swift/iphonesimulator/prebuilt-modules/CoreGraphics.swiftmodule/x86_64-apple-ios-simulator.swiftmodule /Applications/Xcode_12.4.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/lib/swift/iphonesimulator/prebuilt-modules/Swift.swiftmodule/x86_64-apple-ios-simulator.swiftmodule /Applications/Xcode_12.4.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/lib/swift/iphonesimulator/prebuilt-modules/UIKit.swiftmodule/x86_64-apple-ios-simulator.swiftmodule /Applications/Xcode_12.4.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/lib/swift/iphonesimulator/prebuilt-modules/SwiftOnoneSupport.swiftmodule/x86_64-apple-ios-simulator.swiftmodule /Applications/Xcode_12.4.app/Contents/Developer/Platforms/iPhoneSimulator.platform/Developer/SDKs/iPhoneSimulator14.4.sdk/usr/include/mach-o/dyld.modulemap /Applications/Xcode_12.4.app/Contents/Developer/Platforms/iPhoneSimulator.platform/Developer/SDKs/iPhoneSimulator14.4.sdk/usr/include/mach-o/compact_unwind_encoding.modulemap /Applications/Xcode_12.4.app/Contents/Developer/Platforms/iPhoneSimulator.platform/Developer/SDKs/iPhoneSimulator14.4.sdk/usr/include/objc/ObjectiveC.apinotes /Applications/Xcode_12.4.app/Contents/Developer/Platforms/iPhoneSimulator.platform/Developer/SDKs/iPhoneSimulator14.4.sdk/System/Library/Frameworks/OpenGLES.framework/Headers/OpenGLES.apinotes /Applications/Xcode_12.4.app/Contents/Developer/Platforms/iPhoneSimulator.platform/Developer/SDKs/iPhoneSimulator14.4.sdk/System/Library/Frameworks/CoreImage.framework/Headers/CoreImage.apinotes /Applications/Xcode_12.4.app/Contents/Developer/Platforms/iPhoneSimulator.platform/Developer/SDKs/iPhoneSimulator14.4.sdk/System/Library/Frameworks/QuartzCore.framework/Headers/QuartzCore.apinotes /Applications/Xcode_12.4.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/lib/swift/apinotes/Dispatch.apinotes /Applications/Xcode_12.4.app/Contents/Developer/Platforms/iPhoneSimulator.platform/Developer/SDKs/iPhoneSimulator14.4.sdk/System/Library/Frameworks/Metal.framework/Headers/Metal.apinotes /Applications/Xcode_12.4.app/Contents/Developer/Platforms/iPhoneSimulator.platform/Developer/SDKs/iPhoneSimulator14.4.sdk/usr/include/Darwin.apinotes /Applications/Xcode_12.4.app/Contents/Developer/Platforms/iPhoneSimulator.platform/Developer/SDKs/iPhoneSimulator14.4.sdk/System/Library/Frameworks/Foundation.framework/Headers/Foundation.apinotes /Applications/Xcode_12.4.app/Contents/Developer/Platforms/iPhoneSimulator.platform/Developer/SDKs/iPhoneSimulator14.4.sdk/System/Library/Frameworks/CoreGraphics.framework/Headers/CoreGraphics.apinotes /Applications/Xcode_12.4.app/Contents/Developer/Platforms/iPhoneSimulator.platform/Developer/SDKs/iPhoneSimulator14.4.sdk/System/Library/Frameworks/UserNotifications.framework/Headers/UserNotifications.apinotes /Applications/Xcode_12.4.app/Contents/Developer/Platforms/iPhoneSimulator.platform/Developer/SDKs/iPhoneSimulator14.4.sdk/System/Library/Frameworks/UIKit.framework/Headers/UIKit.apinotes /Applications/Xcode_12.4.app/Contents/Developer/Platforms/iPhoneSimulator.platform/Developer/SDKs/iPhoneSimulator14.4.sdk/System/Library/Frameworks/CoreText.framework/Headers/CoreText.apinotes /Applications/Xcode_12.4.app/Contents/Developer/Platforms/iPhoneSimulator.platform/Developer/SDKs/iPhoneSimulator14.4.sdk/System/Library/Frameworks/Security.framework/Headers/Security.apinotes
/Users/kelvintan/Desktop/MVP/Build/Intermediates.noindex/MVP.build/Debug-iphonesimulator/MVP.build/Objects-normal/x86_64/HomePresenter~partial.swiftmodule : /Users/kelvintan/Desktop/MVP/MVP/SceneDelegate.swift /Users/kelvintan/Desktop/MVP/MVP/AppDelegate.swift /Users/kelvintan/Desktop/MVP/MVP/View/Home/HomeTableViewCell.swift /Users/kelvintan/Desktop/MVP/MVP/Controller/Home/HomeViewController.swift /Users/kelvintan/Desktop/MVP/MVP/Controller/Detail/DetailViewController.swift /Users/kelvintan/Desktop/MVP/MVP/Presenter/HomePresenter.swift /Users/kelvintan/Desktop/MVP/MVP/Model/BucketList.swift /Users/kelvintan/Desktop/MVP/MVP/Extension/Date_Ext.swift /Users/kelvintan/Desktop/MVP/MVP/Extension/View_Ext.swift /Applications/Xcode_12.4.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/lib/swift/iphonesimulator/prebuilt-modules/ObjectiveC.swiftmodule/x86_64-apple-ios-simulator.swiftmodule /Applications/Xcode_12.4.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/lib/swift/iphonesimulator/prebuilt-modules/CoreImage.swiftmodule/x86_64-apple-ios-simulator.swiftmodule /Applications/Xcode_12.4.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/lib/swift/iphonesimulator/prebuilt-modules/Combine.swiftmodule/x86_64-apple-ios-simulator.swiftmodule /Applications/Xcode_12.4.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/lib/swift/iphonesimulator/prebuilt-modules/QuartzCore.swiftmodule/x86_64-apple-ios-simulator.swiftmodule /Applications/Xcode_12.4.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/lib/swift/iphonesimulator/prebuilt-modules/Dispatch.swiftmodule/x86_64-apple-ios-simulator.swiftmodule /Applications/Xcode_12.4.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/lib/swift/iphonesimulator/prebuilt-modules/Metal.swiftmodule/x86_64-apple-ios-simulator.swiftmodule /Applications/Xcode_12.4.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/lib/swift/iphonesimulator/prebuilt-modules/Darwin.swiftmodule/x86_64-apple-ios-simulator.swiftmodule /Applications/Xcode_12.4.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/lib/swift/iphonesimulator/prebuilt-modules/Foundation.swiftmodule/x86_64-apple-ios-simulator.swiftmodule /Applications/Xcode_12.4.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/lib/swift/iphonesimulator/prebuilt-modules/CoreFoundation.swiftmodule/x86_64-apple-ios-simulator.swiftmodule /Applications/Xcode_12.4.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/lib/swift/iphonesimulator/prebuilt-modules/CoreGraphics.swiftmodule/x86_64-apple-ios-simulator.swiftmodule /Applications/Xcode_12.4.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/lib/swift/iphonesimulator/prebuilt-modules/Swift.swiftmodule/x86_64-apple-ios-simulator.swiftmodule /Applications/Xcode_12.4.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/lib/swift/iphonesimulator/prebuilt-modules/UIKit.swiftmodule/x86_64-apple-ios-simulator.swiftmodule /Applications/Xcode_12.4.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/lib/swift/iphonesimulator/prebuilt-modules/SwiftOnoneSupport.swiftmodule/x86_64-apple-ios-simulator.swiftmodule /Applications/Xcode_12.4.app/Contents/Developer/Platforms/iPhoneSimulator.platform/Developer/SDKs/iPhoneSimulator14.4.sdk/usr/include/mach-o/dyld.modulemap /Applications/Xcode_12.4.app/Contents/Developer/Platforms/iPhoneSimulator.platform/Developer/SDKs/iPhoneSimulator14.4.sdk/usr/include/mach-o/compact_unwind_encoding.modulemap /Applications/Xcode_12.4.app/Contents/Developer/Platforms/iPhoneSimulator.platform/Developer/SDKs/iPhoneSimulator14.4.sdk/usr/include/objc/ObjectiveC.apinotes /Applications/Xcode_12.4.app/Contents/Developer/Platforms/iPhoneSimulator.platform/Developer/SDKs/iPhoneSimulator14.4.sdk/System/Library/Frameworks/OpenGLES.framework/Headers/OpenGLES.apinotes /Applications/Xcode_12.4.app/Contents/Developer/Platforms/iPhoneSimulator.platform/Developer/SDKs/iPhoneSimulator14.4.sdk/System/Library/Frameworks/CoreImage.framework/Headers/CoreImage.apinotes /Applications/Xcode_12.4.app/Contents/Developer/Platforms/iPhoneSimulator.platform/Developer/SDKs/iPhoneSimulator14.4.sdk/System/Library/Frameworks/QuartzCore.framework/Headers/QuartzCore.apinotes /Applications/Xcode_12.4.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/lib/swift/apinotes/Dispatch.apinotes /Applications/Xcode_12.4.app/Contents/Developer/Platforms/iPhoneSimulator.platform/Developer/SDKs/iPhoneSimulator14.4.sdk/System/Library/Frameworks/Metal.framework/Headers/Metal.apinotes /Applications/Xcode_12.4.app/Contents/Developer/Platforms/iPhoneSimulator.platform/Developer/SDKs/iPhoneSimulator14.4.sdk/usr/include/Darwin.apinotes /Applications/Xcode_12.4.app/Contents/Developer/Platforms/iPhoneSimulator.platform/Developer/SDKs/iPhoneSimulator14.4.sdk/System/Library/Frameworks/Foundation.framework/Headers/Foundation.apinotes /Applications/Xcode_12.4.app/Contents/Developer/Platforms/iPhoneSimulator.platform/Developer/SDKs/iPhoneSimulator14.4.sdk/System/Library/Frameworks/CoreGraphics.framework/Headers/CoreGraphics.apinotes /Applications/Xcode_12.4.app/Contents/Developer/Platforms/iPhoneSimulator.platform/Developer/SDKs/iPhoneSimulator14.4.sdk/System/Library/Frameworks/UserNotifications.framework/Headers/UserNotifications.apinotes /Applications/Xcode_12.4.app/Contents/Developer/Platforms/iPhoneSimulator.platform/Developer/SDKs/iPhoneSimulator14.4.sdk/System/Library/Frameworks/UIKit.framework/Headers/UIKit.apinotes /Applications/Xcode_12.4.app/Contents/Developer/Platforms/iPhoneSimulator.platform/Developer/SDKs/iPhoneSimulator14.4.sdk/System/Library/Frameworks/CoreText.framework/Headers/CoreText.apinotes /Applications/Xcode_12.4.app/Contents/Developer/Platforms/iPhoneSimulator.platform/Developer/SDKs/iPhoneSimulator14.4.sdk/System/Library/Frameworks/Security.framework/Headers/Security.apinotes
/Users/kelvintan/Desktop/MVP/Build/Intermediates.noindex/MVP.build/Debug-iphonesimulator/MVP.build/Objects-normal/x86_64/HomePresenter~partial.swiftdoc : /Users/kelvintan/Desktop/MVP/MVP/SceneDelegate.swift /Users/kelvintan/Desktop/MVP/MVP/AppDelegate.swift /Users/kelvintan/Desktop/MVP/MVP/View/Home/HomeTableViewCell.swift /Users/kelvintan/Desktop/MVP/MVP/Controller/Home/HomeViewController.swift /Users/kelvintan/Desktop/MVP/MVP/Controller/Detail/DetailViewController.swift /Users/kelvintan/Desktop/MVP/MVP/Presenter/HomePresenter.swift /Users/kelvintan/Desktop/MVP/MVP/Model/BucketList.swift /Users/kelvintan/Desktop/MVP/MVP/Extension/Date_Ext.swift /Users/kelvintan/Desktop/MVP/MVP/Extension/View_Ext.swift /Applications/Xcode_12.4.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/lib/swift/iphonesimulator/prebuilt-modules/ObjectiveC.swiftmodule/x86_64-apple-ios-simulator.swiftmodule /Applications/Xcode_12.4.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/lib/swift/iphonesimulator/prebuilt-modules/CoreImage.swiftmodule/x86_64-apple-ios-simulator.swiftmodule /Applications/Xcode_12.4.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/lib/swift/iphonesimulator/prebuilt-modules/Combine.swiftmodule/x86_64-apple-ios-simulator.swiftmodule /Applications/Xcode_12.4.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/lib/swift/iphonesimulator/prebuilt-modules/QuartzCore.swiftmodule/x86_64-apple-ios-simulator.swiftmodule /Applications/Xcode_12.4.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/lib/swift/iphonesimulator/prebuilt-modules/Dispatch.swiftmodule/x86_64-apple-ios-simulator.swiftmodule /Applications/Xcode_12.4.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/lib/swift/iphonesimulator/prebuilt-modules/Metal.swiftmodule/x86_64-apple-ios-simulator.swiftmodule /Applications/Xcode_12.4.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/lib/swift/iphonesimulator/prebuilt-modules/Darwin.swiftmodule/x86_64-apple-ios-simulator.swiftmodule /Applications/Xcode_12.4.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/lib/swift/iphonesimulator/prebuilt-modules/Foundation.swiftmodule/x86_64-apple-ios-simulator.swiftmodule /Applications/Xcode_12.4.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/lib/swift/iphonesimulator/prebuilt-modules/CoreFoundation.swiftmodule/x86_64-apple-ios-simulator.swiftmodule /Applications/Xcode_12.4.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/lib/swift/iphonesimulator/prebuilt-modules/CoreGraphics.swiftmodule/x86_64-apple-ios-simulator.swiftmodule /Applications/Xcode_12.4.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/lib/swift/iphonesimulator/prebuilt-modules/Swift.swiftmodule/x86_64-apple-ios-simulator.swiftmodule /Applications/Xcode_12.4.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/lib/swift/iphonesimulator/prebuilt-modules/UIKit.swiftmodule/x86_64-apple-ios-simulator.swiftmodule /Applications/Xcode_12.4.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/lib/swift/iphonesimulator/prebuilt-modules/SwiftOnoneSupport.swiftmodule/x86_64-apple-ios-simulator.swiftmodule /Applications/Xcode_12.4.app/Contents/Developer/Platforms/iPhoneSimulator.platform/Developer/SDKs/iPhoneSimulator14.4.sdk/usr/include/mach-o/dyld.modulemap /Applications/Xcode_12.4.app/Contents/Developer/Platforms/iPhoneSimulator.platform/Developer/SDKs/iPhoneSimulator14.4.sdk/usr/include/mach-o/compact_unwind_encoding.modulemap /Applications/Xcode_12.4.app/Contents/Developer/Platforms/iPhoneSimulator.platform/Developer/SDKs/iPhoneSimulator14.4.sdk/usr/include/objc/ObjectiveC.apinotes /Applications/Xcode_12.4.app/Contents/Developer/Platforms/iPhoneSimulator.platform/Developer/SDKs/iPhoneSimulator14.4.sdk/System/Library/Frameworks/OpenGLES.framework/Headers/OpenGLES.apinotes /Applications/Xcode_12.4.app/Contents/Developer/Platforms/iPhoneSimulator.platform/Developer/SDKs/iPhoneSimulator14.4.sdk/System/Library/Frameworks/CoreImage.framework/Headers/CoreImage.apinotes /Applications/Xcode_12.4.app/Contents/Developer/Platforms/iPhoneSimulator.platform/Developer/SDKs/iPhoneSimulator14.4.sdk/System/Library/Frameworks/QuartzCore.framework/Headers/QuartzCore.apinotes /Applications/Xcode_12.4.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/lib/swift/apinotes/Dispatch.apinotes /Applications/Xcode_12.4.app/Contents/Developer/Platforms/iPhoneSimulator.platform/Developer/SDKs/iPhoneSimulator14.4.sdk/System/Library/Frameworks/Metal.framework/Headers/Metal.apinotes /Applications/Xcode_12.4.app/Contents/Developer/Platforms/iPhoneSimulator.platform/Developer/SDKs/iPhoneSimulator14.4.sdk/usr/include/Darwin.apinotes /Applications/Xcode_12.4.app/Contents/Developer/Platforms/iPhoneSimulator.platform/Developer/SDKs/iPhoneSimulator14.4.sdk/System/Library/Frameworks/Foundation.framework/Headers/Foundation.apinotes /Applications/Xcode_12.4.app/Contents/Developer/Platforms/iPhoneSimulator.platform/Developer/SDKs/iPhoneSimulator14.4.sdk/System/Library/Frameworks/CoreGraphics.framework/Headers/CoreGraphics.apinotes /Applications/Xcode_12.4.app/Contents/Developer/Platforms/iPhoneSimulator.platform/Developer/SDKs/iPhoneSimulator14.4.sdk/System/Library/Frameworks/UserNotifications.framework/Headers/UserNotifications.apinotes /Applications/Xcode_12.4.app/Contents/Developer/Platforms/iPhoneSimulator.platform/Developer/SDKs/iPhoneSimulator14.4.sdk/System/Library/Frameworks/UIKit.framework/Headers/UIKit.apinotes /Applications/Xcode_12.4.app/Contents/Developer/Platforms/iPhoneSimulator.platform/Developer/SDKs/iPhoneSimulator14.4.sdk/System/Library/Frameworks/CoreText.framework/Headers/CoreText.apinotes /Applications/Xcode_12.4.app/Contents/Developer/Platforms/iPhoneSimulator.platform/Developer/SDKs/iPhoneSimulator14.4.sdk/System/Library/Frameworks/Security.framework/Headers/Security.apinotes
/Users/kelvintan/Desktop/MVP/Build/Intermediates.noindex/MVP.build/Debug-iphonesimulator/MVP.build/Objects-normal/x86_64/HomePresenter~partial.swiftsourceinfo : /Users/kelvintan/Desktop/MVP/MVP/SceneDelegate.swift /Users/kelvintan/Desktop/MVP/MVP/AppDelegate.swift /Users/kelvintan/Desktop/MVP/MVP/View/Home/HomeTableViewCell.swift /Users/kelvintan/Desktop/MVP/MVP/Controller/Home/HomeViewController.swift /Users/kelvintan/Desktop/MVP/MVP/Controller/Detail/DetailViewController.swift /Users/kelvintan/Desktop/MVP/MVP/Presenter/HomePresenter.swift /Users/kelvintan/Desktop/MVP/MVP/Model/BucketList.swift /Users/kelvintan/Desktop/MVP/MVP/Extension/Date_Ext.swift /Users/kelvintan/Desktop/MVP/MVP/Extension/View_Ext.swift /Applications/Xcode_12.4.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/lib/swift/iphonesimulator/prebuilt-modules/ObjectiveC.swiftmodule/x86_64-apple-ios-simulator.swiftmodule /Applications/Xcode_12.4.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/lib/swift/iphonesimulator/prebuilt-modules/CoreImage.swiftmodule/x86_64-apple-ios-simulator.swiftmodule /Applications/Xcode_12.4.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/lib/swift/iphonesimulator/prebuilt-modules/Combine.swiftmodule/x86_64-apple-ios-simulator.swiftmodule /Applications/Xcode_12.4.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/lib/swift/iphonesimulator/prebuilt-modules/QuartzCore.swiftmodule/x86_64-apple-ios-simulator.swiftmodule /Applications/Xcode_12.4.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/lib/swift/iphonesimulator/prebuilt-modules/Dispatch.swiftmodule/x86_64-apple-ios-simulator.swiftmodule /Applications/Xcode_12.4.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/lib/swift/iphonesimulator/prebuilt-modules/Metal.swiftmodule/x86_64-apple-ios-simulator.swiftmodule /Applications/Xcode_12.4.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/lib/swift/iphonesimulator/prebuilt-modules/Darwin.swiftmodule/x86_64-apple-ios-simulator.swiftmodule /Applications/Xcode_12.4.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/lib/swift/iphonesimulator/prebuilt-modules/Foundation.swiftmodule/x86_64-apple-ios-simulator.swiftmodule /Applications/Xcode_12.4.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/lib/swift/iphonesimulator/prebuilt-modules/CoreFoundation.swiftmodule/x86_64-apple-ios-simulator.swiftmodule /Applications/Xcode_12.4.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/lib/swift/iphonesimulator/prebuilt-modules/CoreGraphics.swiftmodule/x86_64-apple-ios-simulator.swiftmodule /Applications/Xcode_12.4.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/lib/swift/iphonesimulator/prebuilt-modules/Swift.swiftmodule/x86_64-apple-ios-simulator.swiftmodule /Applications/Xcode_12.4.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/lib/swift/iphonesimulator/prebuilt-modules/UIKit.swiftmodule/x86_64-apple-ios-simulator.swiftmodule /Applications/Xcode_12.4.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/lib/swift/iphonesimulator/prebuilt-modules/SwiftOnoneSupport.swiftmodule/x86_64-apple-ios-simulator.swiftmodule /Applications/Xcode_12.4.app/Contents/Developer/Platforms/iPhoneSimulator.platform/Developer/SDKs/iPhoneSimulator14.4.sdk/usr/include/mach-o/dyld.modulemap /Applications/Xcode_12.4.app/Contents/Developer/Platforms/iPhoneSimulator.platform/Developer/SDKs/iPhoneSimulator14.4.sdk/usr/include/mach-o/compact_unwind_encoding.modulemap /Applications/Xcode_12.4.app/Contents/Developer/Platforms/iPhoneSimulator.platform/Developer/SDKs/iPhoneSimulator14.4.sdk/usr/include/objc/ObjectiveC.apinotes /Applications/Xcode_12.4.app/Contents/Developer/Platforms/iPhoneSimulator.platform/Developer/SDKs/iPhoneSimulator14.4.sdk/System/Library/Frameworks/OpenGLES.framework/Headers/OpenGLES.apinotes /Applications/Xcode_12.4.app/Contents/Developer/Platforms/iPhoneSimulator.platform/Developer/SDKs/iPhoneSimulator14.4.sdk/System/Library/Frameworks/CoreImage.framework/Headers/CoreImage.apinotes /Applications/Xcode_12.4.app/Contents/Developer/Platforms/iPhoneSimulator.platform/Developer/SDKs/iPhoneSimulator14.4.sdk/System/Library/Frameworks/QuartzCore.framework/Headers/QuartzCore.apinotes /Applications/Xcode_12.4.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/lib/swift/apinotes/Dispatch.apinotes /Applications/Xcode_12.4.app/Contents/Developer/Platforms/iPhoneSimulator.platform/Developer/SDKs/iPhoneSimulator14.4.sdk/System/Library/Frameworks/Metal.framework/Headers/Metal.apinotes /Applications/Xcode_12.4.app/Contents/Developer/Platforms/iPhoneSimulator.platform/Developer/SDKs/iPhoneSimulator14.4.sdk/usr/include/Darwin.apinotes /Applications/Xcode_12.4.app/Contents/Developer/Platforms/iPhoneSimulator.platform/Developer/SDKs/iPhoneSimulator14.4.sdk/System/Library/Frameworks/Foundation.framework/Headers/Foundation.apinotes /Applications/Xcode_12.4.app/Contents/Developer/Platforms/iPhoneSimulator.platform/Developer/SDKs/iPhoneSimulator14.4.sdk/System/Library/Frameworks/CoreGraphics.framework/Headers/CoreGraphics.apinotes /Applications/Xcode_12.4.app/Contents/Developer/Platforms/iPhoneSimulator.platform/Developer/SDKs/iPhoneSimulator14.4.sdk/System/Library/Frameworks/UserNotifications.framework/Headers/UserNotifications.apinotes /Applications/Xcode_12.4.app/Contents/Developer/Platforms/iPhoneSimulator.platform/Developer/SDKs/iPhoneSimulator14.4.sdk/System/Library/Frameworks/UIKit.framework/Headers/UIKit.apinotes /Applications/Xcode_12.4.app/Contents/Developer/Platforms/iPhoneSimulator.platform/Developer/SDKs/iPhoneSimulator14.4.sdk/System/Library/Frameworks/CoreText.framework/Headers/CoreText.apinotes /Applications/Xcode_12.4.app/Contents/Developer/Platforms/iPhoneSimulator.platform/Developer/SDKs/iPhoneSimulator14.4.sdk/System/Library/Frameworks/Security.framework/Headers/Security.apinotes
| D |
/**
* Compiler implementation of the
* $(LINK2 http://www.dlang.org, D programming language).
*
* Copyright: Copyright (c) 1999-2016 by Digital Mars, All Rights Reserved
* Authors: $(LINK2 http://www.digitalmars.com, Walter Bright)
* License: $(LINK2 http://www.boost.org/LICENSE_1_0.txt, Boost License 1.0)
* Source: $(DMDSRC _traits.d)
*/
module ddmd.traits;
import core.stdc.stdio;
import core.stdc.string;
import ddmd.aggregate;
import ddmd.arraytypes;
import ddmd.canthrow;
import ddmd.dclass;
import ddmd.declaration;
import ddmd.dscope;
import ddmd.dsymbol;
import ddmd.dtemplate;
import ddmd.errors;
import ddmd.expression;
import ddmd.func;
import ddmd.globals;
import ddmd.hdrgen;
import ddmd.id;
import ddmd.identifier;
import ddmd.mtype;
import ddmd.nogc;
import ddmd.root.array;
import ddmd.root.speller;
import ddmd.root.stringtable;
import ddmd.tokens;
import ddmd.visitor;
enum LOGSEMANTIC = false;
/************************ TraitsExp ************************************/
// callback for TypeFunction::attributesApply
struct PushAttributes
{
Expressions* mods;
extern (C++) static int fp(void* param, const(char)* str)
{
PushAttributes* p = cast(PushAttributes*)param;
p.mods.push(new StringExp(Loc(), cast(char*)str));
return 0;
}
}
extern (C++) __gshared StringTable traitsStringTable;
static this()
{
static immutable string[] names =
[
"isAbstractClass",
"isArithmetic",
"isAssociativeArray",
"isFinalClass",
"isPOD",
"isNested",
"isFloating",
"isIntegral",
"isScalar",
"isStaticArray",
"isUnsigned",
"isVirtualFunction",
"isVirtualMethod",
"isAbstractFunction",
"isFinalFunction",
"isOverrideFunction",
"isStaticFunction",
"isRef",
"isOut",
"isLazy",
"hasMember",
"identifier",
"getProtection",
"parent",
"getMember",
"getOverloads",
"getVirtualFunctions",
"getVirtualMethods",
"classInstanceSize",
"allMembers",
"derivedMembers",
"isSame",
"compiles",
"parameters",
"getAliasThis",
"getAttributes",
"getFunctionAttributes",
"getUnitTests",
"getVirtualIndex",
"getPointerBitmap",
];
traitsStringTable._init(40);
foreach (s; names)
{
auto sv = traitsStringTable.insert(s.ptr, s.length, cast(void*)s.ptr);
assert(sv);
}
}
/**
* get an array of size_t values that indicate possible pointer words in memory
* if interpreted as the type given as argument
* the first array element is the size of the type for independent interpretation
* of the array
* following elements bits represent one word (4/8 bytes depending on the target
* architecture). If set the corresponding memory might contain a pointer/reference.
*
* [T.sizeof, pointerbit0-31/63, pointerbit32/64-63/128, ...]
*/
extern (C++) Expression pointerBitmap(TraitsExp e)
{
if (!e.args || e.args.dim != 1)
{
error(e.loc, "a single type expected for trait pointerBitmap");
return new ErrorExp();
}
Type t = getType((*e.args)[0]);
if (!t)
{
error(e.loc, "%s is not a type", (*e.args)[0].toChars());
return new ErrorExp();
}
d_uns64 sz;
if (t.ty == Tclass && !(cast(TypeClass)t).sym.isInterfaceDeclaration())
sz = (cast(TypeClass)t).sym.AggregateDeclaration.size(e.loc);
else
sz = t.size(e.loc);
if (sz == SIZE_INVALID)
return new ErrorExp();
const sz_size_t = Type.tsize_t.size(e.loc);
if (sz > sz.max - sz_size_t)
{
error(e.loc, "size overflow for type %s", t.toChars());
return new ErrorExp();
}
d_uns64 bitsPerWord = sz_size_t * 8;
d_uns64 cntptr = (sz + sz_size_t - 1) / sz_size_t;
d_uns64 cntdata = (cntptr + bitsPerWord - 1) / bitsPerWord;
Array!(d_uns64) data;
data.setDim(cast(size_t)cntdata);
data.zero();
extern (C++) final class PointerBitmapVisitor : Visitor
{
alias visit = super.visit;
public:
extern (D) this(Array!(d_uns64)* _data, d_uns64 _sz_size_t)
{
this.data = _data;
this.sz_size_t = _sz_size_t;
}
void setpointer(d_uns64 off)
{
d_uns64 ptroff = off / sz_size_t;
(*data)[cast(size_t)(ptroff / (8 * sz_size_t))] |= 1L << (ptroff % (8 * sz_size_t));
}
override void visit(Type t)
{
Type tb = t.toBasetype();
if (tb != t)
tb.accept(this);
}
override void visit(TypeError t)
{
visit(cast(Type)t);
}
override void visit(TypeNext t)
{
assert(0);
}
override void visit(TypeBasic t)
{
if (t.ty == Tvoid)
setpointer(offset);
}
override void visit(TypeVector t)
{
}
override void visit(TypeArray t)
{
assert(0);
}
override void visit(TypeSArray t)
{
d_uns64 arrayoff = offset;
d_uns64 nextsize = t.next.size();
if (nextsize == SIZE_INVALID)
error = true;
d_uns64 dim = t.dim.toInteger();
for (d_uns64 i = 0; i < dim; i++)
{
offset = arrayoff + i * nextsize;
t.next.accept(this);
}
offset = arrayoff;
}
override void visit(TypeDArray t)
{
setpointer(offset + sz_size_t);
}
// dynamic array is {length,ptr}
override void visit(TypeAArray t)
{
setpointer(offset);
}
override void visit(TypePointer t)
{
if (t.nextOf().ty != Tfunction) // don't mark function pointers
setpointer(offset);
}
override void visit(TypeReference t)
{
setpointer(offset);
}
override void visit(TypeClass t)
{
setpointer(offset);
}
override void visit(TypeFunction t)
{
}
override void visit(TypeDelegate t)
{
setpointer(offset);
}
// delegate is {context, function}
override void visit(TypeQualified t)
{
assert(0);
}
// assume resolved
override void visit(TypeIdentifier t)
{
assert(0);
}
override void visit(TypeInstance t)
{
assert(0);
}
override void visit(TypeTypeof t)
{
assert(0);
}
override void visit(TypeReturn t)
{
assert(0);
}
override void visit(TypeEnum t)
{
visit(cast(Type)t);
}
override void visit(TypeTuple t)
{
visit(cast(Type)t);
}
override void visit(TypeSlice t)
{
assert(0);
}
override void visit(TypeNull t)
{
// always a null pointer
}
override void visit(TypeStruct t)
{
d_uns64 structoff = offset;
foreach (v; t.sym.fields)
{
offset = structoff + v.offset;
if (v.type.ty == Tclass)
setpointer(offset);
else
v.type.accept(this);
}
offset = structoff;
}
// a "toplevel" class is treated as an instance, while TypeClass fields are treated as references
void visitClass(TypeClass t)
{
d_uns64 classoff = offset;
// skip vtable-ptr and monitor
if (t.sym.baseClass)
visitClass(cast(TypeClass)t.sym.baseClass.type);
foreach (v; t.sym.fields)
{
offset = classoff + v.offset;
v.type.accept(this);
}
offset = classoff;
}
Array!(d_uns64)* data;
d_uns64 offset;
d_uns64 sz_size_t;
bool error;
}
scope PointerBitmapVisitor pbv = new PointerBitmapVisitor(&data, sz_size_t);
if (t.ty == Tclass)
pbv.visitClass(cast(TypeClass)t);
else
t.accept(pbv);
if (pbv.error)
return new ErrorExp();
auto exps = new Expressions();
exps.push(new IntegerExp(e.loc, sz, Type.tsize_t));
foreach (d_uns64 i; 0 .. cntdata)
exps.push(new IntegerExp(e.loc, data[cast(size_t)i], Type.tsize_t));
auto ale = new ArrayLiteralExp(e.loc, exps);
ale.type = Type.tsize_t.sarrayOf(cntdata + 1);
return ale;
}
extern (C++) Expression semanticTraits(TraitsExp e, Scope* sc)
{
static if (LOGSEMANTIC)
{
printf("TraitsExp::semantic() %s\n", e.toChars());
}
if (e.ident != Id.compiles &&
e.ident != Id.isSame &&
e.ident != Id.identifier &&
e.ident != Id.getProtection)
{
if (!TemplateInstance.semanticTiargs(e.loc, sc, e.args, 1))
return new ErrorExp();
}
size_t dim = e.args ? e.args.dim : 0;
Expression dimError(int expected)
{
e.error("expected %d arguments for %s but had %d", expected, e.ident.toChars(), cast(int)dim);
return new ErrorExp();
}
Expression isX(T)(bool function(T) fp)
{
int result = 0;
if (!dim)
goto Lfalse;
foreach (o; *e.args)
{
static if (is(T == Type))
auto y = getType(o);
static if (is(T : Dsymbol))
{
auto s = getDsymbol(o);
if (!s)
goto Lfalse;
}
static if (is(T == Dsymbol))
alias y = s;
static if (is(T == Declaration))
auto y = s.isDeclaration();
static if (is(T == FuncDeclaration))
auto y = s.isFuncDeclaration();
if (!y || !fp(y))
goto Lfalse;
}
result = 1;
Lfalse:
return new IntegerExp(e.loc, result, Type.tbool);
}
alias isTypeX = isX!Type;
alias isDsymX = isX!Dsymbol;
alias isDeclX = isX!Declaration;
alias isFuncX = isX!FuncDeclaration;
if (e.ident == Id.isArithmetic)
{
return isTypeX(t => t.isintegral() || t.isfloating());
}
if (e.ident == Id.isFloating)
{
return isTypeX(t => t.isfloating());
}
if (e.ident == Id.isIntegral)
{
return isTypeX(t => t.isintegral());
}
if (e.ident == Id.isScalar)
{
return isTypeX(t => t.isscalar());
}
if (e.ident == Id.isUnsigned)
{
return isTypeX(t => t.isunsigned());
}
if (e.ident == Id.isAssociativeArray)
{
return isTypeX(t => t.toBasetype().ty == Taarray);
}
if (e.ident == Id.isStaticArray)
{
return isTypeX(t => t.toBasetype().ty == Tsarray);
}
if (e.ident == Id.isAbstractClass)
{
return isTypeX(t => t.toBasetype().ty == Tclass &&
(cast(TypeClass)t.toBasetype()).sym.isAbstract());
}
if (e.ident == Id.isFinalClass)
{
return isTypeX(t => t.toBasetype().ty == Tclass &&
((cast(TypeClass)t.toBasetype()).sym.storage_class & STCfinal) != 0);
}
if (e.ident == Id.isTemplate)
{
return isDsymX((s)
{
if (!s.toAlias().isOverloadable())
return false;
return overloadApply(s,
sm => sm.isTemplateDeclaration() !is null) != 0;
});
}
if (e.ident == Id.isPOD)
{
if (dim != 1)
return dimError(1);
auto o = (*e.args)[0];
auto t = isType(o);
if (!t)
{
e.error("type expected as second argument of __traits %s instead of %s",
e.ident.toChars(), o.toChars());
return new ErrorExp();
}
Type tb = t.baseElemOf();
if (auto sd = tb.ty == Tstruct ? (cast(TypeStruct)tb).sym : null)
{
if (sd.isPOD())
goto Ltrue;
else
goto Lfalse;
}
goto Ltrue;
}
if (e.ident == Id.isNested)
{
if (dim != 1)
return dimError(1);
auto o = (*e.args)[0];
auto s = getDsymbol(o);
if (!s)
{
}
else if (auto ad = s.isAggregateDeclaration())
{
if (ad.isNested())
goto Ltrue;
else
goto Lfalse;
}
else if (auto fd = s.isFuncDeclaration())
{
if (fd.isNested())
goto Ltrue;
else
goto Lfalse;
}
e.error("aggregate or function expected instead of '%s'", o.toChars());
return new ErrorExp();
}
if (e.ident == Id.isAbstractFunction)
{
return isFuncX(f => f.isAbstract());
}
if (e.ident == Id.isVirtualFunction)
{
return isFuncX(f => f.isVirtual());
}
if (e.ident == Id.isVirtualMethod)
{
return isFuncX(f => f.isVirtualMethod());
}
if (e.ident == Id.isFinalFunction)
{
return isFuncX(f => f.isFinalFunc());
}
if (e.ident == Id.isOverrideFunction)
{
return isFuncX(f => f.isOverride());
}
if (e.ident == Id.isStaticFunction)
{
return isFuncX(f => !f.needThis() && !f.isNested());
}
if (e.ident == Id.isRef)
{
return isDeclX(d => d.isRef());
}
if (e.ident == Id.isOut)
{
return isDeclX(d => d.isOut());
}
if (e.ident == Id.isLazy)
{
return isDeclX(d => (d.storage_class & STClazy) != 0);
}
if (e.ident == Id.identifier)
{
// Get identifier for symbol as a string literal
/* Specify 0 for bit 0 of the flags argument to semanticTiargs() so that
* a symbol should not be folded to a constant.
* Bit 1 means don't convert Parameter to Type if Parameter has an identifier
*/
if (!TemplateInstance.semanticTiargs(e.loc, sc, e.args, 2))
return new ErrorExp();
if (dim != 1)
return dimError(1);
auto o = (*e.args)[0];
Identifier id;
if (auto po = isParameter(o))
{
id = po.ident;
assert(id);
}
else
{
Dsymbol s = getDsymbol(o);
if (!s || !s.ident)
{
e.error("argument %s has no identifier", o.toChars());
return new ErrorExp();
}
id = s.ident;
}
auto se = new StringExp(e.loc, cast(char*)id.toChars());
return se.semantic(sc);
}
if (e.ident == Id.getProtection)
{
if (dim != 1)
return dimError(1);
Scope* sc2 = sc.push();
sc2.flags = sc.flags | SCOPEnoaccesscheck;
bool ok = TemplateInstance.semanticTiargs(e.loc, sc2, e.args, 1);
sc2.pop();
if (!ok)
return new ErrorExp();
auto o = (*e.args)[0];
auto s = getDsymbol(o);
if (!s)
{
if (!isError(o))
e.error("argument %s has no protection", o.toChars());
return new ErrorExp();
}
if (s._scope)
s.semantic(s._scope);
auto protName = protectionToChars(s.prot().kind); // TODO: How about package(names)
assert(protName);
auto se = new StringExp(e.loc, cast(char*)protName);
return se.semantic(sc);
}
if (e.ident == Id.parent)
{
if (dim != 1)
return dimError(1);
auto o = (*e.args)[0];
auto s = getDsymbol(o);
if (s)
{
if (auto fd = s.isFuncDeclaration()) // Bugzilla 8943
s = fd.toAliasFunc();
if (!s.isImport()) // Bugzilla 8922
s = s.toParent();
}
if (!s || s.isImport())
{
e.error("argument %s has no parent", o.toChars());
return new ErrorExp();
}
if (auto f = s.isFuncDeclaration())
{
if (auto td = getFuncTemplateDecl(f))
{
if (td.overroot) // if not start of overloaded list of TemplateDeclaration's
td = td.overroot; // then get the start
Expression ex = new TemplateExp(e.loc, td, f);
ex = ex.semantic(sc);
return ex;
}
if (auto fld = f.isFuncLiteralDeclaration())
{
// Directly translate to VarExp instead of FuncExp
Expression ex = new VarExp(e.loc, fld, true);
return ex.semantic(sc);
}
}
return DsymbolExp.resolve(e.loc, sc, s, false);
}
if (e.ident == Id.hasMember ||
e.ident == Id.getMember ||
e.ident == Id.getOverloads ||
e.ident == Id.getVirtualMethods ||
e.ident == Id.getVirtualFunctions)
{
if (dim != 2)
return dimError(2);
auto o = (*e.args)[0];
auto ex = isExpression((*e.args)[1]);
if (!ex)
{
e.error("expression expected as second argument of __traits %s", e.ident.toChars());
return new ErrorExp();
}
ex = ex.ctfeInterpret();
StringExp se = ex.toStringExp();
if (!se || se.len == 0)
{
e.error("string expected as second argument of __traits %s instead of %s", e.ident.toChars(), ex.toChars());
return new ErrorExp();
}
se = se.toUTF8(sc);
if (se.sz != 1)
{
e.error("string must be chars");
return new ErrorExp();
}
auto id = Identifier.idPool(se.peekSlice());
/* Prefer dsymbol, because it might need some runtime contexts.
*/
Dsymbol sym = getDsymbol(o);
if (sym)
{
ex = new DsymbolExp(e.loc, sym);
ex = new DotIdExp(e.loc, ex, id);
}
else if (auto t = isType(o))
ex = typeDotIdExp(e.loc, t, id);
else if (auto ex2 = isExpression(o))
ex = new DotIdExp(e.loc, ex2, id);
else
{
e.error("invalid first argument");
return new ErrorExp();
}
// ignore symbol visibility for these traits, should disable access checks as well
Scope* scx = sc.push();
scx.flags |= SCOPEignoresymbolvisibility;
scope (exit) scx.pop();
if (e.ident == Id.hasMember)
{
if (sym)
{
if (auto sm = sym.search(e.loc, id))
goto Ltrue;
}
/* Take any errors as meaning it wasn't found
*/
ex = ex.trySemantic(scx);
if (!ex)
goto Lfalse;
else
goto Ltrue;
}
else if (e.ident == Id.getMember)
{
ex = ex.semantic(scx);
return ex;
}
else if (e.ident == Id.getVirtualFunctions ||
e.ident == Id.getVirtualMethods ||
e.ident == Id.getOverloads)
{
uint errors = global.errors;
Expression eorig = ex;
ex = ex.semantic(scx);
if (errors < global.errors)
e.error("%s cannot be resolved", eorig.toChars());
//ex.print();
/* Create tuple of functions of ex
*/
auto exps = new Expressions();
FuncDeclaration f;
if (ex.op == TOKvar)
{
VarExp ve = cast(VarExp)ex;
f = ve.var.isFuncDeclaration();
ex = null;
}
else if (ex.op == TOKdotvar)
{
DotVarExp dve = cast(DotVarExp)ex;
f = dve.var.isFuncDeclaration();
if (dve.e1.op == TOKdottype || dve.e1.op == TOKthis)
ex = null;
else
ex = dve.e1;
}
overloadApply(f, (Dsymbol s)
{
auto fd = s.isFuncDeclaration();
if (!fd)
return 0;
if (e.ident == Id.getVirtualFunctions && !fd.isVirtual())
return 0;
if (e.ident == Id.getVirtualMethods && !fd.isVirtualMethod())
return 0;
auto fa = new FuncAliasDeclaration(fd.ident, fd, false);
fa.protection = fd.protection;
auto e = ex ? new DotVarExp(Loc(), ex, fa, false)
: new DsymbolExp(Loc(), fa, false);
exps.push(e);
return 0;
});
auto tup = new TupleExp(e.loc, exps);
return tup.semantic(scx);
}
else
assert(0);
}
if (e.ident == Id.classInstanceSize)
{
if (dim != 1)
return dimError(1);
auto o = (*e.args)[0];
auto s = getDsymbol(o);
auto cd = s ? s.isClassDeclaration() : null;
if (!cd)
{
e.error("first argument is not a class");
return new ErrorExp();
}
if (cd.sizeok != SIZEOKdone)
{
cd.size(e.loc);
}
if (cd.sizeok != SIZEOKdone)
{
e.error("%s %s is forward referenced", cd.kind(), cd.toChars());
return new ErrorExp();
}
return new IntegerExp(e.loc, cd.structsize, Type.tsize_t);
}
if (e.ident == Id.getAliasThis)
{
if (dim != 1)
return dimError(1);
auto o = (*e.args)[0];
auto s = getDsymbol(o);
auto ad = s ? s.isAggregateDeclaration() : null;
if (!ad)
{
e.error("argument is not an aggregate type");
return new ErrorExp();
}
auto exps = new Expressions();
if (ad.aliasthis)
exps.push(new StringExp(e.loc, cast(char*)ad.aliasthis.ident.toChars()));
Expression ex = new TupleExp(e.loc, exps);
ex = ex.semantic(sc);
return ex;
}
if (e.ident == Id.getAttributes)
{
if (dim != 1)
return dimError(1);
auto o = (*e.args)[0];
auto s = getDsymbol(o);
if (!s)
{
version (none)
{
Expression x = isExpression(o);
Type t = isType(o);
if (x)
printf("e = %s %s\n", Token.toChars(x.op), x.toChars());
if (t)
printf("t = %d %s\n", t.ty, t.toChars());
}
e.error("first argument is not a symbol");
return new ErrorExp();
}
if (auto imp = s.isImport())
{
s = imp.mod;
}
//printf("getAttributes %s, attrs = %p, scope = %p\n", s.toChars(), s.userAttribDecl, s.scope);
auto udad = s.userAttribDecl;
auto exps = udad ? udad.getAttributes() : new Expressions();
auto tup = new TupleExp(e.loc, exps);
return tup.semantic(sc);
}
if (e.ident == Id.getFunctionAttributes)
{
// extract all function attributes as a tuple (const/shared/inout/pure/nothrow/etc) except UDAs.
if (dim != 1)
return dimError(1);
auto o = (*e.args)[0];
auto s = getDsymbol(o);
auto t = isType(o);
TypeFunction tf = null;
if (s)
{
if (auto fd = s.isFuncDeclaration())
t = fd.type;
else if (auto vd = s.isVarDeclaration())
t = vd.type;
}
if (t)
{
if (t.ty == Tfunction)
tf = cast(TypeFunction)t;
else if (t.ty == Tdelegate)
tf = cast(TypeFunction)t.nextOf();
else if (t.ty == Tpointer && t.nextOf().ty == Tfunction)
tf = cast(TypeFunction)t.nextOf();
}
if (!tf)
{
e.error("first argument is not a function");
return new ErrorExp();
}
auto mods = new Expressions();
PushAttributes pa;
pa.mods = mods;
tf.modifiersApply(&pa, &PushAttributes.fp);
tf.attributesApply(&pa, &PushAttributes.fp, TRUSTformatSystem);
auto tup = new TupleExp(e.loc, mods);
return tup.semantic(sc);
}
if (e.ident == Id.allMembers ||
e.ident == Id.derivedMembers)
{
if (dim != 1)
return dimError(1);
auto o = (*e.args)[0];
auto s = getDsymbol(o);
if (!s)
{
e.error("argument has no members");
return new ErrorExp();
}
if (auto imp = s.isImport())
{
// Bugzilla 9692
s = imp.mod;
}
auto sds = s.isScopeDsymbol();
if (!sds || sds.isTemplateDeclaration())
{
e.error("%s %s has no members", s.kind(), s.toChars());
return new ErrorExp();
}
auto idents = new Identifiers();
int pushIdentsDg(size_t n, Dsymbol sm)
{
if (!sm)
return 1;
//printf("\t[%i] %s %s\n", i, sm.kind(), sm.toChars());
if (sm.ident)
{
const idx = sm.ident.toChars();
if (idx[0] == '_' &&
idx[1] == '_' &&
sm.ident != Id.ctor &&
sm.ident != Id.dtor &&
sm.ident != Id.__xdtor &&
sm.ident != Id.postblit &&
sm.ident != Id.__xpostblit)
{
return 0;
}
if (sm.ident == Id.empty)
{
return 0;
}
if (sm.isTypeInfoDeclaration()) // Bugzilla 15177
return 0;
//printf("\t%s\n", sm.ident.toChars());
/* Skip if already present in idents[]
*/
foreach (id; *idents)
{
if (id == sm.ident)
return 0;
// Avoid using strcmp in the first place due to the performance impact in an O(N^2) loop.
debug assert(strcmp(id.toChars(), sm.ident.toChars()) != 0);
}
idents.push(sm.ident);
}
else if (auto ed = sm.isEnumDeclaration())
{
ScopeDsymbol._foreach(null, ed.members, &pushIdentsDg);
}
return 0;
}
ScopeDsymbol._foreach(sc, sds.members, &pushIdentsDg);
auto cd = sds.isClassDeclaration();
if (cd && e.ident == Id.allMembers)
{
if (cd._scope)
cd.semantic(null); // Bugzilla 13668: Try to resolve forward reference
void pushBaseMembersDg(ClassDeclaration cd)
{
for (size_t i = 0; i < cd.baseclasses.dim; i++)
{
auto cb = (*cd.baseclasses)[i].sym;
assert(cb);
ScopeDsymbol._foreach(null, cb.members, &pushIdentsDg);
if (cb.baseclasses.dim)
pushBaseMembersDg(cb);
}
}
pushBaseMembersDg(cd);
}
// Turn Identifiers into StringExps reusing the allocated array
assert(Expressions.sizeof == Identifiers.sizeof);
auto exps = cast(Expressions*)idents;
foreach (i, id; *idents)
{
auto se = new StringExp(e.loc, cast(char*)id.toChars());
(*exps)[i] = se;
}
/* Making this a tuple is more flexible, as it can be statically unrolled.
* To make an array literal, enclose __traits in [ ]:
* [ __traits(allMembers, ...) ]
*/
Expression ex = new TupleExp(e.loc, exps);
ex = ex.semantic(sc);
return ex;
}
if (e.ident == Id.compiles)
{
/* Determine if all the objects - types, expressions, or symbols -
* compile without error
*/
if (!dim)
goto Lfalse;
foreach (o; *e.args)
{
uint errors = global.startGagging();
Scope* sc2 = sc.push();
sc2.tinst = null;
sc2.minst = null;
sc2.flags = (sc.flags & ~(SCOPEctfe | SCOPEcondition)) | SCOPEcompile | SCOPEfullinst;
bool err = false;
auto t = isType(o);
auto ex = t ? t.toExpression() : isExpression(o);
if (!ex && t)
{
Dsymbol s;
t.resolve(e.loc, sc2, &ex, &t, &s);
if (t)
{
t.semantic(e.loc, sc2);
if (t.ty == Terror)
err = true;
}
else if (s && s.errors)
err = true;
}
if (ex)
{
ex = ex.semantic(sc2);
ex = resolvePropertiesOnly(sc2, ex);
ex = ex.optimize(WANTvalue);
if (sc2.func && sc2.func.type.ty == Tfunction)
{
auto tf = cast(TypeFunction)sc2.func.type;
canThrow(ex, sc2.func, tf.isnothrow);
}
ex = checkGC(sc2, ex);
if (ex.op == TOKerror)
err = true;
}
sc2.pop();
if (global.endGagging(errors) || err)
{
goto Lfalse;
}
}
goto Ltrue;
}
if (e.ident == Id.isSame)
{
/* Determine if two symbols are the same
*/
if (dim != 2)
return dimError(2);
if (!TemplateInstance.semanticTiargs(e.loc, sc, e.args, 0))
return new ErrorExp();
auto o1 = (*e.args)[0];
auto o2 = (*e.args)[1];
auto s1 = getDsymbol(o1);
auto s2 = getDsymbol(o2);
//printf("isSame: %s, %s\n", o1.toChars(), o2.toChars());
version (none)
{
printf("o1: %p\n", o1);
printf("o2: %p\n", o2);
if (!s1)
{
if (auto ea = isExpression(o1))
printf("%s\n", ea.toChars());
if (auto ta = isType(o1))
printf("%s\n", ta.toChars());
goto Lfalse;
}
else
printf("%s %s\n", s1.kind(), s1.toChars());
}
if (!s1 && !s2)
{
auto ea1 = isExpression(o1);
auto ea2 = isExpression(o2);
if (ea1 && ea2)
{
if (ea1.equals(ea2))
goto Ltrue;
}
}
if (!s1 || !s2)
goto Lfalse;
s1 = s1.toAlias();
s2 = s2.toAlias();
if (auto fa1 = s1.isFuncAliasDeclaration())
s1 = fa1.toAliasFunc();
if (auto fa2 = s2.isFuncAliasDeclaration())
s2 = fa2.toAliasFunc();
if (s1 == s2)
goto Ltrue;
else
goto Lfalse;
}
if (e.ident == Id.getUnitTests)
{
if (dim != 1)
return dimError(1);
auto o = (*e.args)[0];
auto s = getDsymbol(o);
if (!s)
{
e.error("argument %s to __traits(getUnitTests) must be a module or aggregate",
o.toChars());
return new ErrorExp();
}
if (auto imp = s.isImport()) // Bugzilla 10990
s = imp.mod;
auto sds = s.isScopeDsymbol();
if (!sds)
{
e.error("argument %s to __traits(getUnitTests) must be a module or aggregate, not a %s",
s.toChars(), s.kind());
return new ErrorExp();
}
auto exps = new Expressions();
if (global.params.useUnitTests)
{
bool[void*] uniqueUnitTests;
void collectUnitTests(Dsymbols* a)
{
if (!a)
return;
foreach (s; *a)
{
if (auto atd = s.isAttribDeclaration())
{
collectUnitTests(atd.include(null, null));
continue;
}
if (auto ud = s.isUnitTestDeclaration())
{
if (cast(void*)ud in uniqueUnitTests)
continue;
auto ad = new FuncAliasDeclaration(ud.ident, ud, false);
ad.protection = ud.protection;
auto e = new DsymbolExp(Loc(), ad, false);
exps.push(e);
uniqueUnitTests[cast(void*)ud] = true;
}
}
}
collectUnitTests(sds.members);
}
auto te = new TupleExp(e.loc, exps);
return te.semantic(sc);
}
if (e.ident == Id.getVirtualIndex)
{
if (dim != 1)
return dimError(1);
auto o = (*e.args)[0];
auto s = getDsymbol(o);
auto fd = s ? s.isFuncDeclaration() : null;
if (!fd)
{
e.error("first argument to __traits(getVirtualIndex) must be a function");
return new ErrorExp();
}
fd = fd.toAliasFunc(); // Neccessary to support multiple overloads.
return new IntegerExp(e.loc, fd.vtblIndex, Type.tptrdiff_t);
}
if (e.ident == Id.getPointerBitmap)
{
return pointerBitmap(e);
}
extern (D) void* trait_search_fp(const(char)* seed, ref int cost)
{
//printf("trait_search_fp('%s')\n", seed);
size_t len = strlen(seed);
if (!len)
return null;
cost = 0;
StringValue* sv = traitsStringTable.lookup(seed, len);
return sv ? sv.ptrvalue : null;
}
if (auto sub = cast(const(char)*)speller(e.ident.toChars(), &trait_search_fp, idchars))
e.error("unrecognized trait '%s', did you mean '%s'?", e.ident.toChars(), sub);
else
e.error("unrecognized trait '%s'", e.ident.toChars());
return new ErrorExp();
Lfalse:
return new IntegerExp(e.loc, 0, Type.tbool);
Ltrue:
return new IntegerExp(e.loc, 1, Type.tbool);
}
| D |
/**
DDBC - D DataBase Connector - abstraction layer for RDBMS access, with interface similar to JDBC.
Source file ddbc/package.d
DDBC library attempts to provide implementation independent interface to different databases. API is similar to Java JDBC API.
http://docs.oracle.com/javase/7/docs/technotes/guides/jdbc/
For using DDBC, import this file:
import dstruct.ddbc;
Supported (built-in) RDBMS drivers: MySQL, PostgreSQL, SQLite
Configuration name Version constants Drivers included
-------------------------- ---------------------------------- ---------------------------------
full USE_MYSQL, USE_SQLITE, USE_PGSQL mysql, sqlite, postgresql, odbc
MySQL USE_MYSQL mysql
SQLite USE_SQLITE sqlite
PGSQL USE_PGSQL postgresql
ODBC USE_ODBC odbc
API (none) (no drivers, API only)
When using in DUB based project, add "ddbc" dependency to your project's dub.json:
"dependencies": {
"ddbc": "~>0.2.35"
}
Default configuration is "full". You can choose other configuration by specifying subConfiguration for ddbc, e.g.:
"subConfigurations": {
"ddbc": "SQLite"
}
If you want to support all DDBC configuration in your project, use configurations section:
"configurations": [
{
"name": "default",
"subConfigurations": {
"ddbc": "full"
}
},
{
"name": "MySQL",
"subConfigurations": {
"ddbc": "MySQL"
}
},
{
"name": "SQLite",
"subConfigurations": {
"ddbc": "SQLite"
}
},
{
"name": "PGSQL",
"subConfigurations": {
"ddbc": "PGSQL"
}
},
{
"name": "API",
"subConfigurations": {
"ddbc": "API"
}
},
]
DDBC URLs
=========
For creation of DDBC drivers or data sources, you can use DDBC URL.
Common form of DDBC URL: driver://host:port/dbname?param1=value1,param2=value2
As well, you can prefix url with "ddbc:"
ddbc:driver://host:port/dbname?param1=value1,param2=value2
Following helper function may be used to create URL
string makeDDBCUrl(string driverName, string host, int port, string dbName, string[string] params = null);
For PostgreSQL, use following form of URL:
postgresql://host:port/dbname
Optionally you can put user name, password, and ssl option as url parameters:
postgresql://host:port/dbname?user=username,password=userpassword,ssl=true
For MySQL, use following form of URL:
mysql://host:port/dbname
Optionally you can put user name and password as url parameters:
mysql://host:port/dbname?user=username,password=userpassword
For SQLite, use following form of URL:
sqlite:db_file_path_name
Sample urls:
string pgsqlurl = "postgresql://localhost:5432/ddbctestdb?user=ddbctest,password=ddbctestpass,ssl=true";
string mysqlurl = "mysql://localhost:3306/ddbctestdb?user=ddbctest,password=ddbctestpass";
string sqliteurl = "sqlite:testdb.sqlite";
Drivers, connections, data sources and connection pools.
=======================================================
Driver - factory interface for DB connections. This interface implements single method to create connections:
Connection connect(string url, string[string] params);
DataSource - factory interface for creating connections to specific DB instance, holds enough information to create connection using simple call of getConnection()
ConnectionPool - DataSource which implements pool of opened connections to avoid slow connection establishment. It keeps several connections opened in pool.
Connection - main object for dealing with DB.
Driver may be created using one of factory methods:
/// create driver by name, e.g. "mysql", "postgresql", "sqlite"
DriverFactory.createDriver(string driverName);
/// create driver by url, e.g. "mysql://host:port/db", "postgresql://host:port/db", "sqlite://"
DriverFactory.createDriverForURL(string url);
There are helper functions to create Connection, DataSource or ConnectionPool from URL and parameters.
/// Helper function to create DDBC connection, automatically selecting driver based on URL
Connection createConnection(string url, string[string]params = null);
/// Helper function to create simple DDBC DataSource, automatically selecting driver based on URL
DataSource createDataSource(string url, string[string]params = null);
/// Helper function to create connection pool data source, automatically selecting driver based on URL
DataSource createConnectionPool(string url, string[string]params = null, int maxPoolSize = 1, int timeToLive = 600, int waitTimeOut = 30);
If you are planning to create several connections, consider using DataSource or ConnectionPool.
For simple cases, it's enough to create connection directly.
Connection conn = createConnection("sqlite:testfile.sqlite");
If you need to get / release connection multiple times, it makes sense to use ConnectionPool
DataSource ds = createConnectionPool("ddbc:postgresql://localhost:5432/ddbctestdb?user=ddbctest,password=ddbctestpass,ssl=true");
// now we can take connection from pool when needed
auto conn = ds.getConnection();
// and then release it back to pool when no more needed
conn.close();
// if we call ds.getConnection() one more time, existing connection from pool will be used
Copyright: Copyright 2014
License: $(LINK www.boost.org/LICENSE_1_0.txt, Boost License 1.0).
Author: Vadim Lopatin
*/
module dstruct.ddbc;
public import dstruct.ddbc.core;
public import dstruct.ddbc.common;
public import dstruct.ddbc.pods;
version( USE_SQLITE )
{
// register SQLite driver
private import dstruct.ddbc.drivers.sqliteddbc;
}
version( USE_PGSQL )
{
// register Postgres driver
private import dstruct.ddbc.drivers.pgsqlddbc;
} | D |
module dbg.glhelpers;
import glad.gl.all;
import glad.gl.loader;
import bindbc.glfw;
import std.conv, std.math;
import std.string, std.algorithm;
public import std.exception;
private string LoadFileAsStrRet(string path)
{
import std.file : readText;
return readText!string(path);
}
/// Floating-point type
alias GFXnum = float;
/// Integer type
alias GFXint = int;
/// Unsigned integer type
alias GFXuint = uint;
private GFXnum _dummy_num = GFXnum.nan;
/// 3D Vector type
struct GFXvector3
{
/// X
GFXnum x = 0;
/// Y
GFXnum y = 0;
/// Z
GFXnum z = 0;
alias v0 = x;
alias v1 = y;
alias v2 = z;
/// Convert to GFXvector4
GFXvector4 to4(GFXnum w = 0)
{
return gVec4(x, y, z, w);
}
GFXvector3 opUnary(string op)() if (op == "-")
{
return GFXvector3(-x, -y, -z);
}
GFXvector3 opUnary(string op)() if (op == "+")
{
return GFXvector3(x, y, z);
}
GLdouble* opCast(T : GLdouble*)()
{
return [x, y, z].ptr;
}
float[] arr()
{
return [x, y, z];
}
private static pure string strOpBinary(string op)
{
return "GFXvector3 opBinary(string op)(GFXvector3 o) if(op==\"" ~ op ~ "\")"
~ "{return GFXvector3(x" ~ op ~ "o.x," ~ "y" ~ op ~ "o.y, z" ~ op ~ "o.z);}";
}
public ref GFXnum opIndex(size_t i) return
{
switch (i)
{
case 0:
return x;
case 1:
return y;
case 2:
return z;
default:
return _dummy_num;
}
}
mixin(strOpBinary("+"));
mixin(strOpBinary("-"));
mixin(strOpBinary("*"));
mixin(strOpBinary("/"));
}
/// 4D Vector type
struct GFXvector4
{
/// X
GFXnum x = 0;
/// Y
GFXnum y = 0;
/// Z
GFXnum z = 0;
/// W
GFXnum w = 0;
alias v0 = x;
alias v1 = y;
alias v2 = z;
alias v3 = w;
/// Convert to GFXvector3 (cut out w coordinate)
GFXvector3 to3()
{
return gVec3(x, y, z);
}
float[] arr()
{
return [x, y, z, w];
}
GFXvector4 opUnary(string op)() if (op == "-")
{
return GFXvector4(-x, -y, -z, -w);
}
GFXvector4 opUnary(string op)() if (op == "+")
{
return GFXvector4(x, y, z, w);
}
GLdouble* opCast(T : GLdouble*)()
{
return [x, y, z, w].ptr;
}
private static pure string strOpBinary(string op)
{
return "GFXvector4 opBinary(string op)(GFXvector4 o) if(op==\"" ~ op ~ "\")"
~ "{return GFXvector4(x" ~ op ~ "o.x," ~ "y" ~ op ~ "o.y, z" ~ op
~ "o.z,w" ~ op ~ "o.w);}";
}
public ref GFXnum opIndex(size_t i) return
{
switch (i)
{
case 0:
return x;
case 1:
return y;
case 2:
return z;
case 3:
return w;
default:
return _dummy_num;
}
}
mixin(strOpBinary("+"));
mixin(strOpBinary("-"));
mixin(strOpBinary("*"));
mixin(strOpBinary("/"));
}
/// 3x3 matrix type
alias GFXmatrix3 = GFXnum[9];
/// 4x4 matrix type
alias GFXmatrix4 = GFXnum[16];
// ---------------------------------------------------------
// Basic vector operations
// ---------------------------------------------------------
/// Helper for creating new 3d vector
GFXvector3 gVec3(GFXnum x, GFXnum y, GFXnum z)
{
return GFXvector3(x, y, z);
}
/// Helper for creating new 4d vector
GFXvector4 gVec4(GFXnum x, GFXnum y, GFXnum z, GFXnum w)
{
return GFXvector4(x, y, z, w);
}
/// Vector3 dot product (a . b)
GFXnum gDot3(GFXvector3 a, GFXvector3 b)
{
return a.x * b.x + a.y * b.y + a.z * b.z;
}
/// Vector3 cross product (a x b)
GFXvector3 gCross3(GFXvector3 a, GFXvector3 b)
{
return gVec3(a.y * b.z - a.z * b.y, a.z * b.x - a.x * b.z, a.x * b.y - a.y * b.x);
}
/// Vector4 dot product (a . b)
GFXnum gDot4(GFXvector4 a, GFXvector4 b)
{
return a.x * b.x + a.y * b.y + a.z * b.z + a.w * b.w;
}
/// Convert homogenous vector to a 3d vector
GFXvector3 gFromHomogenous(GFXvector4 X)
{
return gVec3(X.x / X.w, X.y / X.w, X.z / X.w);
}
/// Calculates the square of length of a Vector3
GFXnum gLengthSq3(GFXvector3 A)
{
return ((A.x * A.x) + (A.y * A.y) + (A.z * A.z));
}
/// Calculates the length of a Vector3
GFXnum gLength3(GFXvector3 A)
{
return sqrt(gLengthSq3(A));
}
/// Returns normalized Vector3
GFXvector3 gNormalize3(GFXvector3 A)
{
GFXnum len = gLength3(A);
return gVec3(A.x / len, A.y / len, A.z / len);
}
// ---------------------------------------------------------
// Matrix operations
// ---------------------------------------------------------
/// Returns an 3x3 identity matrix
GFXmatrix3 gIdentity3()
{
return [1, 0, 0, 0, 1, 0, 0, 0, 1];
}
/// Returns an 4x4 identity matrix
GFXmatrix4 gIdentity4()
{
return [1, 0, 0, 0, 0, 1, 0, 0, 0, 0, 1, 0, 0, 0, 0, 1];
}
/// Returns product of 3x3 matrices (A x B)
GFXmatrix3 gMat3Mul(GFXmatrix3 A, GFXmatrix3 B)
{
GFXnum[3] C1 = [B[0], B[3], B[6]];
GFXnum[3] C2 = [B[1], B[4], B[7]];
GFXnum[3] C3 = [B[2], B[5], B[8]];
GFXmatrix3 O;
GFXnum[3] T;
for (int i = 0; i < 3; i++)
{
GFXnum[3] R = A[i .. i + 3];
T[] = R[] * C1[];
O[3 * i + 0] = T[0] + T[1] + T[2];
T[] = R[] * C2[];
O[3 * i + 1] = T[0] + T[1] + T[2];
T[] = R[] * C3[];
O[3 * i + 2] = T[0] + T[1] + T[2];
}
return O;
}
GFXvector4 gVecMatTransform(GFXmatrix4 M, GFXvector4 V)
{
return gVec4(M[0] * (V.x) + M[1] * (V.y) + M[2] * V.z + M[3] * V.w,
M[4] * (V.x) + M[5] * (V.y) + M[6] * V.z + M[7] * V.w,
M[8] * (V.x) + M[9] * (V.y) + M[10] * V.z + M[11] * V.w,
M[12] * (V.x) + M[13] * (V.y) + M[14] * V.z + M[15] * V.w);
}
/// Returns product of 4x4 matrices (A x B)
GFXmatrix4 gMat4Mul(GFXmatrix4 A, GFXmatrix4 B)
{
GFXnum[4] C1 = [B[0], B[4], B[8], B[12]];
GFXnum[4] C2 = [B[1], B[5], B[9], B[13]];
GFXnum[4] C3 = [B[2], B[6], B[10], B[14]];
GFXnum[4] C4 = [B[3], B[7], B[11], B[15]];
GFXmatrix4 O;
GFXnum[4] T;
for (int i = 0; i < 4; i++)
{
GFXnum[4] R = A[4 * i .. 4 * (i + 1)];
T[] = R[] * C1[];
O[4 * i + 0] = T[0] + T[1] + T[2] + T[3];
T[] = R[] * C2[];
O[4 * i + 1] = T[0] + T[1] + T[2] + T[3];
T[] = R[] * C3[];
O[4 * i + 2] = T[0] + T[1] + T[2] + T[3];
T[] = R[] * C4[];
O[4 * i + 3] = T[0] + T[1] + T[2] + T[3];
}
return O;
}
/// Transposes 3x3 matrix (A^T)
GFXmatrix3 gMat3Transpose(GFXmatrix3 A)
{
GFXmatrix3 T;
T[0] = A[0];
T[1] = A[3];
T[2] = A[6];
T[3] = A[1];
T[4] = A[4];
T[5] = A[7];
T[6] = A[2];
T[7] = A[5];
T[8] = A[8];
return T;
}
/// Transposes 4x4 matrix (A^T)
GFXmatrix4 gMat4Transpose(GFXmatrix4 A)
{
GFXmatrix4 T;
T[0] = A[0];
T[1] = A[4];
T[2] = A[8];
T[3] = A[12];
T[4] = A[1];
T[5] = A[5];
T[6] = A[9];
T[7] = A[13];
T[8] = A[2];
T[9] = A[6];
T[10] = A[10];
T[11] = A[14];
T[12] = A[3];
T[13] = A[7];
T[14] = A[11];
T[15] = A[15];
return T;
}
/// Calculates the determinant of 3x3 matrix (|A|)
GFXnum gMat3Det(GFXmatrix3 A)
{
GFXnum D = 0;
D += A[0] * (A[4] * A[8] - A[5] * A[7]);
D -= A[1] * (A[3] * A[8] - A[5] * A[6]);
D += A[2] * (A[3] * A[7] - A[4] * A[6]);
return D;
}
/// Calculates the determinant of 4x4 matrix (|A|)
/// Thanks http://stackoverflow.com/questions/2922690/calculating-an-nxn-matrix-determinant-in-c-sharp/2980966#2980966
GFXnum gMat4Det(GFXmatrix4 A)
{
return A[12] * A[9] * A[6] * A[3] - A[8] * A[13] * A[6] * A[3] - A[12] * A[5]
* A[10] * A[3] + A[4] * A[13] * A[10] * A[3] + A[8] * A[5] * A[14] * A[3]
- A[4] * A[9] * A[14] * A[3] - A[12] * A[9] * A[2] * A[7] + A[8] * A[13]
* A[2] * A[7] + A[12] * A[1] * A[10] * A[7] - A[0] * A[13] * A[10] * A[7]
- A[8] * A[1] * A[14] * A[7] + A[0] * A[9] * A[14] * A[7] + A[12] * A[5]
* A[2] * A[11] - A[4] * A[13] * A[2] * A[11] - A[12] * A[1] * A[6]
* A[11] + A[0] * A[13] * A[6] * A[11] + A[4] * A[1] * A[14] * A[11]
- A[0] * A[5] * A[14] * A[11] - A[8] * A[5] * A[2] * A[15] + A[4] * A[9]
* A[2] * A[15] + A[8] * A[1] * A[6] * A[15] - A[0] * A[9] * A[6] * A[15]
- A[4] * A[1] * A[10] * A[15] + A[0] * A[5] * A[10] * A[15];
}
/// Calculates the inverse of a 4x4 matrix
GFXmatrix4 gMat4Inverse(GFXmatrix4 vals)
{
GFXmatrix4 tmp;
tmp[0] = gMat3Det([vals[5], vals[6], vals[7], vals[9], vals[10], vals[11],
vals[13], vals[14], vals[15]]);
tmp[1] = -gMat3Det([vals[4], vals[6], vals[7], vals[8], vals[10], vals[11],
vals[12], vals[14], vals[15]]);
tmp[2] = gMat3Det([vals[4], vals[5], vals[7], vals[8], vals[9], vals[11],
vals[12], vals[13], vals[15]]);
tmp[3] = -gMat3Det([vals[4], vals[5], vals[6], vals[8], vals[9], vals[10],
vals[12], vals[13], vals[14]]);
tmp[4] = -gMat3Det([vals[1], vals[2], vals[3], vals[9], vals[10], vals[11],
vals[13], vals[14], vals[15]]);
tmp[5] = gMat3Det([vals[0], vals[2], vals[3], vals[8], vals[10], vals[11],
vals[12], vals[14], vals[15]]);
tmp[6] = -gMat3Det([vals[0], vals[1], vals[3], vals[8], vals[9], vals[11],
vals[12], vals[13], vals[15]]);
tmp[7] = gMat3Det([vals[0], vals[1], vals[2], vals[8], vals[9], vals[10],
vals[12], vals[13], vals[14]]);
tmp[8] = gMat3Det([vals[1], vals[2], vals[3], vals[5], vals[6], vals[7],
vals[13], vals[14], vals[15]]);
tmp[9] = -gMat3Det([vals[0], vals[2], vals[3], vals[4], vals[6], vals[7],
vals[12], vals[14], vals[15]]);
tmp[10] = gMat3Det([vals[0], vals[1], vals[3], vals[4], vals[5], vals[7],
vals[12], vals[13], vals[15]]);
tmp[11] = -gMat3Det([vals[0], vals[1], vals[2], vals[4], vals[5], vals[6],
vals[12], vals[13], vals[14]]);
tmp[12] = -gMat3Det([vals[1], vals[2], vals[3], vals[5], vals[6], vals[7],
vals[9], vals[10], vals[11]]);
tmp[13] = gMat3Det([vals[0], vals[2], vals[3], vals[4], vals[6], vals[7],
vals[8], vals[10], vals[11]]);
tmp[14] = -gMat3Det([vals[0], vals[1], vals[3], vals[4], vals[5], vals[7],
vals[8], vals[9], vals[11]]);
tmp[15] = gMat3Det([vals[0], vals[1], vals[2], vals[4], vals[5], vals[6],
vals[8], vals[9], vals[10]]);
return gMat4Scale(gMat4Transpose(tmp), 1 / gMat4Det(vals));
}
/// Returns 3x3 matrix multiplied by a scalar (A*n)
GFXmatrix3 gMat3Scale(GFXmatrix3 A, GFXnum n)
{
GFXmatrix3 S = A.dup;
S[] *= n;
return S;
}
/// Returns 4x4 matrix multiplied by a scalar (A*n)
GFXmatrix4 gMat4Scale(GFXmatrix4 A, GFXnum n)
{
GFXmatrix4 S = A.dup;
S[] *= n;
return S;
}
/// -
GFXmatrix4 gMatTranslation(GFXvector3 v)
{
return [1, 0, 0, v.x, 0, 1, 0, v.y, 0, 0, 1, v.z, 0, 0, 0, 1];
}
/// -
GFXmatrix4 gMatScaling(GFXvector3 v)
{
return [v.x, 0, 0, 0, 0, v.y, 0, 0, 0, 0, v.z, 0, 0, 0, 0, 1];
}
/// X
GFXmatrix4 gMatRotX(float a)
{
return [1, 0, 0, 0, 0, cos(a), -sin(a), 0, 0, sin(a), cos(a), 0, 0, 0, 0, 1];
}
/// Y
GFXmatrix4 gMatRotY(float a)
{
return [cos(a), 0, -sin(a), 0, 0, 1, 0, 0, sin(a), 0, cos(a), 0, 0, 0, 0, 1];
}
/// Z
GFXmatrix4 gMatRotZ(float a)
{
return [cos(a), -sin(a), 0, 0, sin(a), cos(a), 0, 0, 0, 0, 1, 0, 0, 0, 0, 1];
}
GFXvector3 gMat3MulVec3(GFXmatrix3 mat, GFXvector3 vec)
{
return gVec3(mat[0] * vec.x + mat[1] * vec.y + mat[2] * vec.z,
mat[3] * vec.x + mat[4] * vec.y + mat[5] * vec.z,
mat[6] * vec.x + mat[7] * vec.y + mat[8] * vec.z);
}
//Based on
//math.stackexchange.com/questions/180418/calculate-rotation-matrix-to-align-vector-a-to-vector-b-in-3d
GFXmatrix3 gMat3RotateVectorOntoVector(GFXvector3 vec, GFXvector3 target)
{
vec = gNormalize3(vec);
target = gNormalize3(target);
GFXvector3 v = gCross3(vec, target);
double s = gLength3(v);
double c = gDot3(vec, target);
GFXmatrix3 v_mat = [0, -v.z, v.y, v.z, 0, -v.x, -v.y, v.x, 0];
GFXmatrix3 res = gIdentity3()[] + v_mat[] + gMat3Scale(gMat3Mul(v_mat, v_mat), (1 - c) / (s * s))[];
return res;
}
/**
Constructs a projection matrix with given arguments
Params:
fov = Vertical Field of View in radians
aspectratio=Width/Height of the viewport
near = Distance to the near clipping plane
far = Distance to the far clipping plane (far > near)
**/
GFXmatrix4 gMatProjection(GFXnum fov, GFXnum aspectratio, GFXnum near, GFXnum far)
{
GFXnum e = 1.0 / (tan(fov * 0.5));
auto a = aspectratio;
return [e, 0, 0, 0, 0, e / a, 0, 0, 0, 0, (far + near) / (near - far),
(2 * far * near) / (near - far), 0, 0, -1, 0];
}
/// Works the same way as gMatProjection but far clipping plane is at infinity.
GFXmatrix4 gMatProjectionInfty(GFXnum fov, GFXnum aspectratio, GFXnum near)
{
GFXnum e = 1.0 / (tan(fov * 0.5));
auto a = aspectratio;
return [e, 0, 0, 0, 0, e / a, 0, 0, 0, 0, -1, -2 * near, 0, 0, -1, 0];
}
/// Constructs an orthographic projection matrix
GFXmatrix4 gMatOrthographic(GFXnum Xmin, GFXnum Xmax, GFXnum Ymin, GFXnum Ymax,
GFXnum Znear, GFXnum Zfar)
{
alias left = Xmin;
alias right = Xmax;
alias top = Ymax;
alias bottom = Ymin;
GFXnum Xn = 2.0 / (right - left);
GFXnum Yn = 2.0 / (top - bottom);
GFXnum Zn = 2.0 / (Znear - Zfar);
GFXnum Xt = (-right - left) / (left - right);
GFXnum Yt = (-top - bottom) / (bottom - top);
GFXnum Zt = (Zfar + Znear) / (Zfar - Znear);
return [Xn, 0, 0, Xt, 0, Yn, 0, Yt, 0, 0, Zn, Zt, 0, 0, 0, 1];
}
/// Convert OpenGL error code to a human-readable string
string gErrorStr(int code)
{
switch (code)
{
case GL_NO_ERROR:
return "No error";
case GL_INVALID_ENUM:
return "Invalid enum value";
case GL_INVALID_VALUE:
return "Invalid value";
case GL_INVALID_OPERATION:
return "Invalid operation";
case GL_INVALID_FRAMEBUFFER_OPERATION:
return "Invalid framebuffer operation";
case GL_OUT_OF_MEMORY:
return "Out of memory";
default:
return "Unknown error " ~ text(code);
}
}
/// Enforce there is no OpenGL error currently.
void gAssertGl()
{
auto err = glGetError();
if (err != GL_NO_ERROR)
{
throw new Error("OpenGL error: " ~ gErrorStr(err));
}
}
/// Check if there are OpenGL errors (do not throw an error).
bool gCheckGl() nothrow
{
return (glGetError() != GL_NO_ERROR);
}
/// Enum defining data types
/// S* means the type is signed and U* means unsigned, A* are array types (numerically-indexed tables in Lua)
enum gDataType
{
Sint8,
Uint8,
Sint16,
Uint16,
Sint32,
Uint32,
Sint64,
Uint64,
Sfloat32,
Sfloat64,
Avector3,
Avector4,
Amatrix3x3,
Amatrix4x4,
Tpad8 /// special type that has no effect except adding 1-byte padding in the structure.
}
private class gDataTypeField
{
public gDataType type;
public ptrdiff_t offset;
public this(gDataType T)
{
type = T;
}
size_t size()
{
return 1;
}
void SetFromD(T)(void* ptr, T val)
{
SetFromDvoid(ptr, cast(void*)(&val));
}
T GetToD(T)(void* ptr)
{
return *(cast(T*) GetToDvoid(ptr));
}
void SetFromDvoid(void* ptr, void* val)
{
assert(0);
}
void* GetToDvoid(void* ptr)
{
assert(0);
}
}
private class gDataImpl(T) : gDataTypeField
{
public this(gDataType T)
{
super(T);
}
override size_t size()
{
return T.sizeof;
}
}
private template mixDataInt(T)
{
public this(gDataType T)
{
super(T);
}
immutable static size_t sz = T.sizeof;
override size_t size()
{
return sz;
}
override void SetFromDvoid(void* ptr, void* val)
{
ptr[0 .. sz] = val[0 .. sz];
}
T bufV;
override void* GetToDvoid(void* ptr)
{
T V;
(cast(void*)(&V))[0 .. sz] = ptr[0 .. sz];
bufV = V;
return &bufV;
}
}
private template mixDataUInt(T)
{
public this(gDataType T)
{
super(T);
}
immutable static size_t sz = T.sizeof;
override size_t size()
{
return sz;
}
override void SetFromDvoid(void* ptr, void* val)
{
ptr[0 .. sz] = val[0 .. sz];
}
T bufV;
override void* GetToDvoid(void* ptr)
{
T V;
(cast(void*)(&V))[0 .. sz] = ptr[0 .. sz];
bufV = V;
return &bufV;
}
}
private template mixDataFloat(T)
{
public this(gDataType T)
{
super(T);
}
immutable static size_t sz = T.sizeof;
override size_t size()
{
return sz;
}
override void SetFromDvoid(void* ptr, void* val)
{
ptr[0 .. sz] = val[0 .. sz];
}
T bufV;
override void* GetToDvoid(void* ptr)
{
T V;
(cast(void*)(&V))[0 .. sz] = ptr[0 .. sz];
bufV = V;
return &bufV;
}
}
private class gDataImpl(T : void) : gDataTypeField
{
static void* nptr = null;
public this(gDataType T)
{
super(T);
}
override size_t size()
{
return 1;
}
override void SetFromDvoid(void* ptr, void* val)
{
}
override void* GetToDvoid(void* ptr)
{
return &nptr;
}
}
private class gDataImpl(T : byte) : gDataTypeField
{
mixin mixDataInt!(T);
}
private class gDataImpl(T : short) : gDataTypeField
{
mixin mixDataInt!(T);
}
private class gDataImpl(T : int) : gDataTypeField
{
mixin mixDataInt!(T);
}
private class gDataImpl(T : long) : gDataTypeField
{
mixin mixDataUInt!(T);
}
private class gDataImpl(T : ubyte) : gDataTypeField
{
mixin mixDataUInt!(T);
}
private class gDataImpl(T : ushort) : gDataTypeField
{
mixin mixDataUInt!(T);
}
private class gDataImpl(T : uint) : gDataTypeField
{
mixin mixDataUInt!(T);
}
private class gDataImpl(T : ulong) : gDataTypeField
{
mixin mixDataUInt!(T);
}
private class gDataImpl(T : float) : gDataTypeField
{
mixin mixDataFloat!(T);
}
private class gDataImpl(T : double) : gDataTypeField
{
mixin mixDataFloat!(T);
}
private class gDataImpl(T : GFXvector3) : gDataTypeField
{
public this(gDataType T)
{
super(T);
}
immutable static size_t sz = float.sizeof * 3;
override size_t size()
{
return sz;
}
override void SetFromDvoid(void* ptr, void* val)
{
GFXvector3 V = *(cast(T*) val);
float[3] A = [V.x, V.y, V.z];
ptr[0 .. sz] = (cast(void*)(A.ptr))[0 .. sz];
}
T bufV;
override void* GetToDvoid(void* ptr)
{
float[3] A;
(cast(void*)(A.ptr))[0 .. sz] = ptr[0 .. sz];
bufV = gVec3(A[0], A[1], A[2]);
return &bufV;
}
}
private class gDataImpl(T : GFXmatrix3) : gDataTypeField
{
public this(gDataType T)
{
super(T);
}
immutable static size_t sz = float.sizeof * 9;
override size_t size()
{
return sz;
}
override void SetFromDvoid(void* ptr, void* val)
{
T* V = cast(T*) val;
ptr[0 .. sz] = (cast(void*)(V))[0 .. sz];
}
T bufV;
override void* GetToDvoid(void* ptr)
{
(cast(void*)(bufV.ptr))[0 .. sz] = ptr[0 .. sz];
return &bufV;
}
}
private class gDataImpl(T : GFXvector4) : gDataTypeField
{
public this(gDataType T)
{
super(T);
}
immutable static size_t sz = float.sizeof * 4;
override size_t size()
{
return sz;
}
override void SetFromDvoid(void* ptr, void* val)
{
T* V = cast(T*) val;
float[4] A = [V.x, V.y, V.z, V.w];
ptr[0 .. sz] = (cast(void*)(A))[0 .. sz];
}
T bufV;
override void* GetToDvoid(void* ptr)
{
float[4] A;
(cast(void*)(A.ptr))[0 .. sz] = ptr[0 .. sz];
bufV = gVec4(A[0], A[1], A[2], A[3]);
return &bufV;
}
}
private class gDataImpl(T : GFXmatrix4) : gDataTypeField
{
public this(gDataType T)
{
super(T);
}
immutable static size_t sz = float.sizeof * 16;
override size_t size()
{
return sz;
}
override void SetFromDvoid(void* ptr, void* val)
{
T* V = cast(T*) val;
ptr[0 .. sz] = (cast(void*)(V))[0 .. sz];
}
T bufV;
override void* GetToDvoid(void* ptr)
{
(cast(void*)(bufV.ptr))[0 .. sz] = ptr[0 .. sz];
return &bufV;
}
}
/** Class for storing arbitrary binary formatted data. It represents a structure dynamic array. (0-indexed!!!)
Initially it is in defining mode, which means you can only append new gDataTypes to the type definition.
After calling declarationComplete() it switches to data mode, in which it can only accept data.
*/
class GFXdataStruct
{
private bool _defining = true;
/// Checks if the struct is still in defining mode.
public @property bool defining()
{
return _defining;
}
public this()
{
}
// Do not modify!!! [public for performance reasons]
public gDataTypeField[] fieldTypes;
protected uint _stride = 0, _len = 0;
public uint stride()
{
return _stride;
}
public uint length()
{
return _len;
};
public ubyte[] data;
/// Appends a new type to the struct declaration
/// Returns: field index if succeeded, -1 if in not in defining mode, -2 if T is not a correct value.
public int appendType(gDataType T)
{
if (!_defining)
return -1;
gDataTypeField F;
switch (T)
{
case gDataType.Sint8:
F = new gDataImpl!(byte)(T);
break;
case gDataType.Sint16:
F = new gDataImpl!(short)(T);
break;
case gDataType.Sint32:
F = new gDataImpl!(int)(T);
break;
case gDataType.Sint64:
F = new gDataImpl!(long)(T);
break;
case gDataType.Uint8:
F = new gDataImpl!(ubyte)(T);
break;
case gDataType.Uint16:
F = new gDataImpl!(ushort)(T);
break;
case gDataType.Uint32:
F = new gDataImpl!(uint)(T);
break;
case gDataType.Uint64:
F = new gDataImpl!(ulong)(T);
break;
case gDataType.Sfloat32:
F = new gDataImpl!(float)(T);
break;
case gDataType.Sfloat64:
F = new gDataImpl!(double)(T);
break;
case gDataType.Avector3:
F = new gDataImpl!(GFXvector3)(T);
break;
case gDataType.Avector4:
F = new gDataImpl!(GFXvector4)(T);
break;
case gDataType.Amatrix3x3:
F = new gDataImpl!(GFXmatrix3)(T);
break;
case gDataType.Amatrix4x4:
F = new gDataImpl!(GFXmatrix4)(T);
break;
case gDataType.Tpad8:
F = new gDataImpl!(void)(T);
break;
default:
return -2;
}
F.offset = _stride;
_stride += F.size();
fieldTypes ~= [F];
return cast(int)(fieldTypes.length - 1);
}
/// Switch to data mode.
public void declarationComplete()
{
if (!_defining)
throw new Error(
"Trying to use a defining mode function in data mode in a GFXdataStruct");
// Setup place for 1 object.
data.length = 0;
_len = 0;
_defining = false;
}
/// Sets the length of the struct array to numels (1 is a single struct)
public void setLength(int numels)
{
if (_defining)
throw new Error(
"Trying to use a data mode function in defining mode in a GFXdataStruct");
data.length = numels * _stride;
_len = numels;
}
/// D template-aware version of setValue
public void setValueD(T)(int field, int idx, T val)
{
if (_defining)
throw new Error(
"Trying to use a data mode function in defining mode in a GFXdataStruct");
if (field >= fieldTypes.length)
throw new Error("Trying to access a non-existant field of a GFXdataStruct");
if (idx >= _len)
throw new Error("Trying to access a non-existant index of a GFXdataStruct");
void* ptr = data.ptr + _stride * idx;
fieldTypes[field].SetFromD(ptr, val);
}
/// D template-aware version of getValue
public T getValueD(T)(int field, int idx)
{
if (_defining)
throw new Error(
"Trying to use a data mode function in defining mode in a GFXdataStruct");
if (field >= fieldTypes.length)
throw new Error("Trying to access a non-existant field of a GFXdataStruct");
if (idx >= _len)
throw new Error("Trying to access a non-existant index of a GFXdataStruct");
void* ptr = data.ptr + _stride * idx;
return fieldTypes[field].GetFromD!T(ptr);
}
override public string toString() const
{
return to!string(data);
}
}
/** Buffer usage
Static - rarely updated
Dynamic - updated quite often
Stream - updated very often
Push - the buffer will be used mostly for sending data to OpenGL
Pull - the buffer will be used mostly for receiving data from OpenGL
Server - the buffer will be used mostly for in-GPU-memory data transfers
*/
enum gBufferUsage
{
StaticPush,
DynamicPush,
StreamPush,
StaticPull,
DynamicPull,
StreamPull,
StaticServer,
DynamicServer,
StreamServer
}
/// Converts gBufferUsage enum to a correct OpenGL enum value
public GLuint gBufferUsageEnum(gBufferUsage u)
{
switch (u)
{
case gBufferUsage.StaticPush:
return GL_STATIC_DRAW;
case gBufferUsage.StaticPull:
return GL_STATIC_READ;
case gBufferUsage.StaticServer:
return GL_STATIC_COPY;
case gBufferUsage.DynamicPush:
return GL_DYNAMIC_DRAW;
case gBufferUsage.DynamicPull:
return GL_DYNAMIC_READ;
case gBufferUsage.DynamicServer:
return GL_DYNAMIC_COPY;
case gBufferUsage.StreamPush:
return GL_STREAM_DRAW;
case gBufferUsage.StreamPull:
return GL_STREAM_READ;
case gBufferUsage.StreamServer:
return GL_STREAM_COPY;
default:
return GL_DYNAMIC_DRAW;
}
}
/// Enum describing binding targets of a buffer object (See: $(LINK https://www.opengl.org/wiki/Buffer_Object#General_use) )
enum gBufferTarget
{
VertexArray,
ElementArray,
CopyRead,
CopyWrite,
PixelUnpack,
PixelPack,
Query,
Texture,
TransformFeedback,
Uniform
}
/// Converts gBufferTarget enum to a correct OpenGL enum value
public GLuint gBufferTargetEnum(gBufferTarget t)
{
switch (t)
{
case gBufferTarget.VertexArray:
return GL_ARRAY_BUFFER;
case gBufferTarget.ElementArray:
return GL_ELEMENT_ARRAY_BUFFER;
case gBufferTarget.CopyRead:
return GL_COPY_READ_BUFFER;
case gBufferTarget.CopyWrite:
return GL_COPY_WRITE_BUFFER;
case gBufferTarget.PixelUnpack:
return GL_PIXEL_UNPACK_BUFFER;
case gBufferTarget.PixelPack:
return GL_PIXEL_PACK_BUFFER;
case gBufferTarget.Query:
return GL_QUERY_BUFFER;
case gBufferTarget.Texture:
return GL_TEXTURE_BUFFER;
case gBufferTarget.TransformFeedback:
return GL_TRANSFORM_FEEDBACK_BUFFER;
case gBufferTarget.Uniform:
return GL_UNIFORM_BUFFER;
default:
return GL_COPY_READ_BUFFER;
}
}
public GLuint gBufferTargetBindingEnum(gBufferTarget t)
{
switch (t)
{
case gBufferTarget.VertexArray:
return GL_ARRAY_BUFFER_BINDING;
case gBufferTarget.ElementArray:
return GL_ELEMENT_ARRAY_BUFFER_BINDING;
case gBufferTarget.PixelUnpack:
return GL_PIXEL_UNPACK_BUFFER_BINDING;
case gBufferTarget.PixelPack:
return GL_PIXEL_PACK_BUFFER_BINDING;
case gBufferTarget.Query:
return GL_QUERY_BUFFER_BINDING;
case gBufferTarget.TransformFeedback:
return GL_TRANSFORM_FEEDBACK_BUFFER_BINDING;
case gBufferTarget.Uniform:
return GL_UNIFORM_BUFFER_BINDING;
default:
return GL_ARRAY_BUFFER_BINDING;
}
}
/// Wraps OpenGL buffer objects, uses GFXdataStruct.
class GFXbufferObject
{
protected GLuint _id;
protected size_t _dsz = size_t.max;
protected gBufferUsage _usage;
protected gBufferTarget _bndX;
protected GLuint _bnd;
protected long _bid = 0;
protected static long _shbid = -1;
/// Gets the buffer id
public uint id()
{
return cast(uint) _id;
}
/// Gets the buffer usage
public gBufferUsage usage()
{
return _usage;
}
/// Sets buffer usage
public void changeUsage(gBufferUsage usg)
{
_usage = usg;
}
/// Constructor
public this(gBufferUsage usg)
{
glGenBuffers(1, &_id);
gAssertGl();
_usage = usg;
_bnd = GL_COPY_READ_BUFFER;
_bndX = gBufferTarget.CopyRead;
}
/// Binds a buffer to the given target
public void bindTo(gBufferTarget target)
{
_bndX = target;
_bnd = gBufferTargetEnum(target);
glBindBuffer(_bnd, _id);
gAssertGl();
_bid = ++_shbid;
}
/// Unbinds the buffer from a target
public void unbindFrom(gBufferTarget target)
{
_bndX = gBufferTarget.CopyRead;
_bnd = GL_COPY_READ_BUFFER;
glBindBuffer(gBufferTargetEnum(target), 0);
gAssertGl();
++_shbid;
}
/// Ensure this is bound.
protected void fenceMe()
{
if (_bid != _shbid)
{
GLint boundid;
glGetIntegerv(gBufferTargetBindingEnum(_bndX), &boundid);
if (boundid != _id)
throw new Error("Trying to use unbound GFXbufferObject");
else
_bid = _shbid;
}
}
/// Updates the buffer data from a GFXdataStruct (requires previous binding)
public void updateData(GFXdataStruct data)
{
fenceMe();
if (data.data.length != _dsz)
{
_dsz = data.data.length;
glBufferData(_bnd, _dsz, cast(const(GLvoid)*)(data.data.ptr),
gBufferUsageEnum(_usage));
}
else
{
glBufferSubData(_bnd, 0, _dsz, cast(const(GLvoid)*)(data.data.ptr));
}
gAssertGl();
}
/// Updates the buffer data from bytes
public void updateData(ubyte[] data)
{
fenceMe();
if (data.length != _dsz)
{
_dsz = data.length;
glBufferData(_bnd, _dsz, cast(const(GLvoid)*)(data.ptr), gBufferUsageEnum(_usage));
}
else
{
glBufferSubData(_bnd, 0, _dsz, cast(const(GLvoid)*)(data.ptr));
}
gAssertGl();
}
/// Updates a part of buffer data from a GFXdataStruct (requires previous binding)
public void updateDataPart(GFXdataStruct data, GFXuint offsetBuffer,
GFXuint amount, GFXuint offsetStruct)
{
fenceMe();
amount *= data.stride;
offsetBuffer *= data.stride;
offsetStruct *= data.stride;
GFXuint str2 = offsetStruct + amount;
(str2 <= data.data.length) || assert(0);
glBufferSubData(_bnd, offsetBuffer, amount,
cast(const(GLvoid)*)(data.data[offsetStruct .. $].ptr));
gAssertGl();
}
/// Copies data to another buffer object (both must be bound to different targets and the other buffer must have enough space for the source data)
public void copyData(GFXbufferObject target)
{
fenceMe();
target.fenceMe();
glCopyBufferSubData(this._bnd, target._bnd, 0, 0, this._dsz);
gAssertGl();
}
}
// ---------------------------------------------------------
// Vertex Array Object
// ---------------------------------------------------------
/// Wraps OpenGL Vertex Array Objects
class GFXvertexArrayObject
{
protected GLuint id;
protected long _bid = 0;
protected static long _shbid = -1;
protected int[] attribs;
/// Constructor
public this()
{
glGenVertexArrays(1, &id);
bind();
}
/// Binds this VAO
public void bind()
{
_shbid++;
_bid = _shbid;
glBindVertexArray(id);
gAssertGl();
}
protected void fenceMe()
{
if (_bid != _shbid)
{
GLint bound;
glGetIntegerv(GL_VERTEX_ARRAY_BINDING, &bound);
if (bound != id)
throw new Error("Trying to use unbound gVertexArrayObject");
else
_bid = _shbid;
}
}
public void enableAttribs()
{
foreach (int attr; attribs)
{
glEnableVertexAttribArray(attr);
}
}
public void disableAttribs()
{
foreach (int attr; attribs)
{
glDisableVertexAttribArray(attr);
}
}
/**
Configures an attribute in the vertex array (wraps glVertexAttrib[I]Pointer)
shaderIndex is the location in shader of the specified attribute.
normalize is only used when the parameter is of type float/matrix3x3/matrix4x4/vector3/vector4.
WARNING! 64-bit integers will be cut off to first 32 bits!
*/
public void configureAttribute(GFXdataStruct str, int fieldIdx,
int shaderIndex, bool convToFloat = false, bool normalize = false)
{
fenceMe();
glEnableVertexAttribArray(shaderIndex);
attribs ~= shaderIndex;
gDataTypeField F = str.fieldTypes[fieldIdx];
auto ffVertexAttribLPointer = function(GLuint a1, GLint a2, GLenum a3,
GLsizei a4, const(GLvoid)* a5) {
glVertexAttribPointer(a1, a2, a3, GL_FALSE, a4, a5);
};
if (GL_ARB_vertex_attrib_64bit)
{
ffVertexAttribLPointer = function(GLuint a1, GLint a2, GLenum a3,
GLsizei a4, const(GLvoid)* a5) {
glVertexAttribLPointer(a1, a2, a3, a4, a5);
};
}
enum void* Z = null;
switch (F.type)
{
case gDataType.Sint8:
glVertexAttribIPointer(shaderIndex, 1, GL_BYTE,
str.stride(), Z + F.offset);
break;
case gDataType.Sint16:
glVertexAttribIPointer(shaderIndex, 1, GL_SHORT,
str.stride(), Z + F.offset);
break;
case gDataType.Sint32:
glVertexAttribIPointer(shaderIndex, 1, GL_INT,
str.stride(), Z + F.offset);
break;
case gDataType.Sint64:
glVertexAttribIPointer(shaderIndex, 1, GL_INT,
str.stride(), Z + F.offset + 4);
break;
case gDataType.Uint8:
glVertexAttribIPointer(shaderIndex, 1,
GL_UNSIGNED_BYTE, str.stride(), Z + F.offset);
break;
case gDataType.Uint16:
glVertexAttribIPointer(shaderIndex, 1,
GL_UNSIGNED_SHORT, str.stride(), Z + F.offset);
break;
case gDataType.Uint32:
glVertexAttribIPointer(shaderIndex, 1,
GL_UNSIGNED_INT, str.stride(), Z + F.offset);
break;
case gDataType.Uint64:
glVertexAttribIPointer(shaderIndex, 1,
GL_UNSIGNED_INT, str.stride(), Z + F.offset + 4);
break;
case gDataType.Sfloat32:
glVertexAttribPointer(shaderIndex, 1,
GL_FLOAT, (normalize) ? GL_TRUE : GL_FALSE, str.stride(), Z + F.offset);
break;
case gDataType.Sfloat64:
ffVertexAttribLPointer(shaderIndex, 1,
GL_DOUBLE, str.stride(), Z + F.offset);
break;
case gDataType.Avector3:
glVertexAttribPointer(shaderIndex, 3,
GL_FLOAT, (normalize) ? GL_TRUE : GL_FALSE, str.stride(), Z + F.offset);
break;
case gDataType.Avector4:
glVertexAttribPointer(shaderIndex, 4,
GL_FLOAT, (normalize) ? GL_TRUE : GL_FALSE, str.stride(), Z + F.offset);
break;
case gDataType.Amatrix3x3:
glVertexAttribPointer(shaderIndex, 3, GL_FLOAT,
(normalize) ? GL_TRUE : GL_FALSE, GFXnum.sizeof * 3, Z + F.offset);
glVertexAttribPointer(shaderIndex + 1, 3, GL_FLOAT, (normalize)
? GL_TRUE : GL_FALSE, GFXnum.sizeof * 3, Z + F.offset + GFXnum.sizeof);
glVertexAttribPointer(shaderIndex + 2, 3, GL_FLOAT, (normalize)
? GL_TRUE : GL_FALSE, GFXnum.sizeof * 3, Z + F.offset + GFXnum.sizeof * 2);
break;
case gDataType.Amatrix4x4:
glVertexAttribPointer(shaderIndex, 3, GL_FLOAT,
(normalize) ? GL_TRUE : GL_FALSE, GFXnum.sizeof * 4, Z + F.offset);
glVertexAttribPointer(shaderIndex + 1, 3, GL_FLOAT, (normalize)
? GL_TRUE : GL_FALSE, GFXnum.sizeof * 4, Z + F.offset + GFXnum.sizeof);
glVertexAttribPointer(shaderIndex + 2, 3, GL_FLOAT, (normalize)
? GL_TRUE : GL_FALSE, GFXnum.sizeof * 4, Z + F.offset + GFXnum.sizeof * 2);
glVertexAttribPointer(shaderIndex + 3, 3, GL_FLOAT, (normalize)
? GL_TRUE : GL_FALSE, GFXnum.sizeof * 4, Z + F.offset + GFXnum.sizeof * 3);
break;
default:
break;
}
gAssertGl();
//glVertexAttribPointer(shaderIndex, NUMC, TYPE, (normalize)?GL_TRUE:GL_FALSE, str.stride(), str.data.ptr + F.offset);
}
}
// ---------------------------------------------------------
// Shaders
// ---------------------------------------------------------
/// Shader Compilation Error
class ShaderCompileError : Error
{
public this(string msg, string shpath)
{
super(format("Shader compile error in file '%s': '%s'", shpath, msg));
}
}
/// Shader&program wrapper class
class GFXshader
{
protected int idVert = -1, idGeom = -1, idFrag = -1, idProg = -1;
protected bool linked = false;
/// Constructor
public this()
{
idProg = glCreateProgram();
gAssertGl();
}
protected void compileSrc(GLenum shType, string src, string path)
{
if (linked)
assert(0, "Trying to load shader into an already linked program.");
int* id;
switch (shType)
{
case GL_VERTEX_SHADER:
id = &idVert;
break;
case GL_FRAGMENT_SHADER:
id = &idFrag;
break;
case GL_GEOMETRY_SHADER:
id = &idProg;
break;
default:
assert(0);
}
if ((*id) >= 0)
assert(0);
*id = cast(int) glCreateShader(shType);
int vid = *id;
glShaderSource(vid, 1, cast(const(char*)*)([src.ptr].ptr), [cast(int)(src.length)].ptr);
glCompileShader(vid);
gAssertGl();
GLint succ = 0;
glGetShaderiv(vid, GL_COMPILE_STATUS, &succ);
if (succ == GL_FALSE)
{
GLint logSize = 0;
glGetShaderiv(vid, GL_INFO_LOG_LENGTH, &logSize);
char[] loga;
loga.length = logSize;
glGetShaderInfoLog(vid, logSize, &succ, loga.ptr);
loga = loga[0 .. succ];
glDeleteShader(vid);
throw new ShaderCompileError(loga.idup, path);
}
glAttachShader(idProg, *id);
gAssertGl();
}
/// Loads vertex shader from VFS path vpath
public void loadVertShader(string vpath)
{
string src = LoadFileAsStrRet(vpath);
compileSrc(GL_VERTEX_SHADER, src, vpath);
}
/// Loads fragment shader from VFS path vpath
public void loadFragShader(string vpath)
{
string src = LoadFileAsStrRet(vpath);
compileSrc(GL_FRAGMENT_SHADER, src, vpath);
}
/// Loads geometry shader from VFS path vpath
public void loadGeomShader(string vpath)
{
string src = LoadFileAsStrRet(vpath);
compileSrc(GL_GEOMETRY_SHADER, src, vpath);
}
/// Binds attribute location
int bindAttribLocation(int loc, string attribName)
{
if (linked)
assert(0, "Trying to bind attribute location in an already linked program.");
glBindAttribLocation(idProg, loc, attribName.toStringz());
return loc;
}
/// Binds FragData location
void bindFragDataLocation(GLuint colorName, string attribName)
{
if (linked)
assert(0, "Trying to bind fragment data location in an already linked program.");
glBindFragDataLocation(idProg, colorName, attribName.toStringz());
gAssertGl();
}
/// Links the program
public void link()
{
glLinkProgram(idProg);
GLint isLinked = 0;
glGetProgramiv(idProg, GL_LINK_STATUS, &isLinked);
if (isLinked == GL_FALSE)
{
GLint maxLen;
glGetProgramiv(idProg, GL_INFO_LOG_LENGTH, &maxLen);
char[] plog;
plog.length = maxLen;
glGetProgramInfoLog(idProg, maxLen, &isLinked, plog.ptr);
plog = plog[0 .. isLinked];
throw new ShaderCompileError(plog.idup, "[program linking]");
}
else
{
if (idVert != -1)
{
glDetachShader(idProg, idVert);
glDeleteShader(idVert);
}
if (idFrag != -1)
{
glDetachShader(idProg, idFrag);
glDeleteShader(idFrag);
}
if (idGeom != -1)
{
glDetachShader(idProg, idGeom);
glDeleteShader(idGeom);
}
linked = true;
}
gAssertGl();
}
/// Binds this program
public void bind()
{
glUseProgram(idProg);
gAssertGl();
}
/// Unbinds current program
public void unbind()
{
glUseProgram(0);
gAssertGl();
}
protected int[string] uniIds;
/// Gets location of `id` uniform in the linked program.
public int getUniformLocation(string id)
{
if (!linked)
assert(0, "You cannot get uniform location from an unlinked program");
int* rid = id in uniIds;
if (rid is null)
{
int V = glGetUniformLocation(idProg, id.toStringz());
uniIds[id] = V;
return V;
}
else
{
return *rid;
}
}
protected int[string] attrIds;
/// Gets location of `id` vertex attribute in the linked program
public int getAttribLocation(string id)
{
if (!linked)
assert(0, "You cannot get attribute location from an unlinked program");
int* rid = id in attrIds;
if (rid is null)
{
int V = glGetAttribLocation(idProg, id.toStringz());
//if(V==-1){throw new Exception("Could not find attribute "~id~" in shader.");}
attrIds[id] = V;
return V;
}
else
{
return *rid;
}
}
/// Sets uniform value
public void setUniform1f(string id, float v0)
{
glUniform1f(getUniformLocation(id), v0);
}
/// Sets uniform value
public void setUniform1i(string id, int v0)
{
glUniform1i(getUniformLocation(id), v0);
}
/// Sets uniform value
public void setUniform2f(string id, float v0, float v1)
{
glUniform2f(getUniformLocation(id), v0, v1);
}
/// Sets uniform value
public void setUniform2i(string id, int v0, int v1)
{
glUniform2i(getUniformLocation(id), v0, v1);
}
/// Sets uniform value
public void setUniform3f(string id, float v0, float v1, float v2)
{
glUniform3f(getUniformLocation(id), v0, v1, v2);
}
/// Sets uniform value
public void setUniform3i(string id, int v0, int v1, int v2)
{
glUniform3i(getUniformLocation(id), v0, v1, v2);
}
/// Sets uniform value
public void setUniform4f(string id, float v0, float v1, float v2, float v3)
{
glUniform4f(getUniformLocation(id), v0, v1, v2, v3);
}
/// Sets uniform value
public void setUniform4i(string id, int v0, int v1, int v2, int v3)
{
glUniform4i(getUniformLocation(id), v0, v1, v2, v3);
}
/// Sets uniform array
public void setUniformAf(string id, int numComponents, float[] values)
{
int loc = getUniformLocation(id);
switch (numComponents)
{
case 1:
glUniform1fv(loc, cast(GLsizei) values.length, values.ptr);
break;
case 2:
glUniform2fv(loc, cast(GLsizei) values.length / 2, values.ptr);
break;
case 3:
glUniform3fv(loc, cast(GLsizei) values.length / 3, values.ptr);
break;
case 4:
glUniform4fv(loc, cast(GLsizei) values.length / 4, values.ptr);
break;
default:
assert(0);
}
}
/// Sets uniform array
public void setUniformAi(string id, int numComponents, int[] values)
{
int loc = getUniformLocation(id);
switch (numComponents)
{
case 1:
glUniform1iv(loc, cast(GLsizei) values.length, values.ptr);
break;
case 2:
glUniform2iv(loc, cast(GLsizei) values.length / 2, values.ptr);
break;
case 3:
glUniform3iv(loc, cast(GLsizei) values.length / 3, values.ptr);
break;
case 4:
glUniform4iv(loc, cast(GLsizei) values.length / 4, values.ptr);
break;
default:
assert(0);
}
}
/// Sets uniform matrix
public void setUniformM3(string id, GFXmatrix3 mat)
{
glUniformMatrix3fv(getUniformLocation(id), 1, GL_TRUE, mat.ptr);
}
/// Sets uniform matrix
public void setUniformM4(string id, GFXmatrix4 mat)
{
glUniformMatrix4fv(getUniformLocation(id), 1, GL_TRUE, mat.ptr);
}
}
/// -
class GFXtexture
{
import image.memory : Image;
protected bool _loaded = false;
protected bool _monochrome = false;
protected bool _filter_linear = true;
protected bool _repeat = true;
protected uint _id = 0xFFFFFFFF;
protected int _w, _h;
/// -
public @property uint getWidth()
{
return _w;
}
/// -
public @property uint getHeight()
{
return _h;
}
/// Constructor
this()
{
glGenTextures(1, &_id);
if (_id == 0)
assert(0, "Couldn't create texture");
gAssertGl();
}
/// Creates/recreates a texture with new image
public void recreateTexture(Image img)
{
_loaded = true;
_monochrome = false;
_w = cast(int) img.w;
_h = cast(int) img.h;
if (GL_EXT_direct_state_access)
{
glTextureImage2DEXT(_id, GL_TEXTURE_2D, 0, (_monochrome) ? (GL_R8)
: (GL_RGB8), _w, _h, 0, (_monochrome) ? (GL_RED) : (GL_RGB),
GL_UNSIGNED_BYTE, img.data.ptr);
}
else
{
glBindTexture(GL_TEXTURE_2D, _id);
glTexImage2D(GL_TEXTURE_2D, 0, (_monochrome) ? (GL_R8) : (GL_RGB8),
_w, _h, 0, (_monochrome) ? (GL_RED) : (GL_RGB), GL_UNSIGNED_BYTE, img.data.ptr);
}
gAssertGl();
}
/// Replaces texture's image with img's image, requires img to be in the same format as the texture.
public void reuploadTexture(Image img)
{
_loaded || assert(0);
(_w == img.w) || assert(0);
(_h == img.h) || assert(0);
if (GL_EXT_direct_state_access)
{
glTextureSubImage2DEXT(_id, GL_TEXTURE_2D, 0, 0, 0, _w, _h,
(_monochrome) ? (GL_RED) : (GL_RGB), GL_UNSIGNED_BYTE, img.data.ptr);
}
else
{
glBindTexture(GL_TEXTURE_2D, _id);
glTexSubImage2D(GL_TEXTURE_2D, 0, 0, 0, _w, _h, (_monochrome)
? (GL_RED) : (GL_RGB), GL_UNSIGNED_BYTE, img.data.ptr);
}
gAssertGl();
}
/// -
public void generateMipmaps()
{
glGenerateMipmap(GL_TEXTURE_2D);
}
/// Binds the texture
public void bind()
{
glBindTexture(GL_TEXTURE_2D, _id);
gAssertGl();
}
}
| D |
/*
REQUIRED_ARGS: -o- -H -Hf${RESULTS_DIR}/compilable/testheader12567a.di
PERMUTE_ARGS:
OUTPUT_FILES: ${RESULTS_DIR}/compilable/testheader12567a.di
TEST_OUTPUT:
---
=== ${RESULTS_DIR}/compilable/testheader12567a.di
// D import file generated from 'compilable/testheader12567a.d'
deprecated module header12567a;
void main();
---
*/
deprecated module header12567a;
void main() {}
| D |
/Users/Jorge/Desktop/Projects/Web/Swift/kisiBootcamp/.build/x86_64-apple-macosx/debug/SQL.build/SQLCreateIndexBuilder.swift.o : /Users/Jorge/Desktop/Projects/Web/Swift/kisiBootcamp/.build/checkouts/sql/Sources/SQL/SQLBind.swift /Users/Jorge/Desktop/Projects/Web/Swift/kisiBootcamp/.build/checkouts/sql/Sources/SQL/SQLJoinMethod.swift /Users/Jorge/Desktop/Projects/Web/Swift/kisiBootcamp/.build/checkouts/sql/Sources/SQL/SQLTable.swift /Users/Jorge/Desktop/Projects/Web/Swift/kisiBootcamp/.build/checkouts/sql/Sources/SQL/SQLCreateTable.swift /Users/Jorge/Desktop/Projects/Web/Swift/kisiBootcamp/.build/checkouts/sql/Sources/SQL/SQLDropTable.swift /Users/Jorge/Desktop/Projects/Web/Swift/kisiBootcamp/.build/checkouts/sql/Sources/SQL/SQLAlterTable.swift /Users/Jorge/Desktop/Projects/Web/Swift/kisiBootcamp/.build/checkouts/sql/Sources/SQL/SQLSerializable.swift /Users/Jorge/Desktop/Projects/Web/Swift/kisiBootcamp/.build/checkouts/sql/Sources/SQL/SQLDataType.swift /Users/Jorge/Desktop/Projects/Web/Swift/kisiBootcamp/.build/checkouts/sql/Sources/SQL/SQLUpdate.swift /Users/Jorge/Desktop/Projects/Web/Swift/kisiBootcamp/.build/checkouts/sql/Sources/SQL/SQLDelete.swift /Users/Jorge/Desktop/Projects/Web/Swift/kisiBootcamp/.build/checkouts/sql/Sources/SQL/SQLLiteral.swift /Users/Jorge/Desktop/Projects/Web/Swift/kisiBootcamp/.build/checkouts/sql/Sources/SQL/SQLBoolLiteral.swift /Users/Jorge/Desktop/Projects/Web/Swift/kisiBootcamp/.build/checkouts/sql/Sources/SQL/SQLDefaultLiteral.swift /Users/Jorge/Desktop/Projects/Web/Swift/kisiBootcamp/.build/checkouts/sql/Sources/SQL/SQLTableConstraintAlgorithm.swift /Users/Jorge/Desktop/Projects/Web/Swift/kisiBootcamp/.build/checkouts/sql/Sources/SQL/SQLColumnConstraintAlgorithm.swift /Users/Jorge/Desktop/Projects/Web/Swift/kisiBootcamp/.build/checkouts/sql/Sources/SQL/SQLJoin.swift /Users/Jorge/Desktop/Projects/Web/Swift/kisiBootcamp/.build/checkouts/sql/Sources/SQL/SQLExpression.swift /Users/Jorge/Desktop/Projects/Web/Swift/kisiBootcamp/.build/checkouts/sql/Sources/SQL/SQLSelectExpression.swift /Users/Jorge/Desktop/Projects/Web/Swift/kisiBootcamp/.build/checkouts/sql/Sources/SQL/SQLCollation.swift /Users/Jorge/Desktop/Projects/Web/Swift/kisiBootcamp/.build/checkouts/sql/Sources/SQL/SQLForeignKeyAction.swift /Users/Jorge/Desktop/Projects/Web/Swift/kisiBootcamp/.build/checkouts/sql/Sources/SQL/SQLConnection.swift /Users/Jorge/Desktop/Projects/Web/Swift/kisiBootcamp/.build/checkouts/sql/Sources/SQL/SQLDirection.swift /Users/Jorge/Desktop/Projects/Web/Swift/kisiBootcamp/.build/checkouts/sql/Sources/SQL/SQLFunction.swift /Users/Jorge/Desktop/Projects/Web/Swift/kisiBootcamp/.build/checkouts/sql/Sources/SQL/SQLColumnDefinition.swift /Users/Jorge/Desktop/Projects/Web/Swift/kisiBootcamp/.build/checkouts/sql/Sources/SQL/SQLCreateTableBuilder.swift /Users/Jorge/Desktop/Projects/Web/Swift/kisiBootcamp/.build/checkouts/sql/Sources/SQL/SQLDropTableBuilder.swift /Users/Jorge/Desktop/Projects/Web/Swift/kisiBootcamp/.build/checkouts/sql/Sources/SQL/SQLAlterTableBuilder.swift /Users/Jorge/Desktop/Projects/Web/Swift/kisiBootcamp/.build/checkouts/sql/Sources/SQL/SQLPredicateBuilder.swift /Users/Jorge/Desktop/Projects/Web/Swift/kisiBootcamp/.build/checkouts/sql/Sources/SQL/SQLUpdateBuilder.swift /Users/Jorge/Desktop/Projects/Web/Swift/kisiBootcamp/.build/checkouts/sql/Sources/SQL/SQLDeleteBuilder.swift /Users/Jorge/Desktop/Projects/Web/Swift/kisiBootcamp/.build/checkouts/sql/Sources/SQL/SQLColumnBuilder.swift /Users/Jorge/Desktop/Projects/Web/Swift/kisiBootcamp/.build/checkouts/sql/Sources/SQL/SQLPredicateGroupBuilder.swift /Users/Jorge/Desktop/Projects/Web/Swift/kisiBootcamp/.build/checkouts/sql/Sources/SQL/SQLSelectBuilder.swift /Users/Jorge/Desktop/Projects/Web/Swift/kisiBootcamp/.build/checkouts/sql/Sources/SQL/SQLInsertBuilder.swift /Users/Jorge/Desktop/Projects/Web/Swift/kisiBootcamp/.build/checkouts/sql/Sources/SQL/SQLRawBuilder.swift /Users/Jorge/Desktop/Projects/Web/Swift/kisiBootcamp/.build/checkouts/sql/Sources/SQL/SQLCreateIndexBuilder.swift /Users/Jorge/Desktop/Projects/Web/Swift/kisiBootcamp/.build/checkouts/sql/Sources/SQL/SQLQueryBuilder.swift /Users/Jorge/Desktop/Projects/Web/Swift/kisiBootcamp/.build/checkouts/sql/Sources/SQL/SQLQueryEncoder.swift /Users/Jorge/Desktop/Projects/Web/Swift/kisiBootcamp/.build/checkouts/sql/Sources/SQL/SQLQueryFetcher.swift /Users/Jorge/Desktop/Projects/Web/Swift/kisiBootcamp/.build/checkouts/sql/Sources/SQL/SQLIndexModifier.swift /Users/Jorge/Desktop/Projects/Web/Swift/kisiBootcamp/.build/checkouts/sql/Sources/SQL/SQLIdentifier.swift /Users/Jorge/Desktop/Projects/Web/Swift/kisiBootcamp/.build/checkouts/sql/Sources/SQL/SQLTableIdentifier.swift /Users/Jorge/Desktop/Projects/Web/Swift/kisiBootcamp/.build/checkouts/sql/Sources/SQL/SQLColumnIdentifier.swift /Users/Jorge/Desktop/Projects/Web/Swift/kisiBootcamp/.build/checkouts/sql/Sources/SQL/SQLError.swift /Users/Jorge/Desktop/Projects/Web/Swift/kisiBootcamp/.build/checkouts/sql/Sources/SQL/SQLBinaryOperator.swift /Users/Jorge/Desktop/Projects/Web/Swift/kisiBootcamp/.build/checkouts/sql/Sources/SQL/Exports.swift /Users/Jorge/Desktop/Projects/Web/Swift/kisiBootcamp/.build/checkouts/sql/Sources/SQL/SQLSelect.swift /Users/Jorge/Desktop/Projects/Web/Swift/kisiBootcamp/.build/checkouts/sql/Sources/SQL/SQLDistinct.swift /Users/Jorge/Desktop/Projects/Web/Swift/kisiBootcamp/.build/checkouts/sql/Sources/SQL/SQLFunctionArgument.swift /Users/Jorge/Desktop/Projects/Web/Swift/kisiBootcamp/.build/checkouts/sql/Sources/SQL/SQLTableConstraint.swift /Users/Jorge/Desktop/Projects/Web/Swift/kisiBootcamp/.build/checkouts/sql/Sources/SQL/SQLColumnConstraint.swift /Users/Jorge/Desktop/Projects/Web/Swift/kisiBootcamp/.build/checkouts/sql/Sources/SQL/SQLInsert.swift /Users/Jorge/Desktop/Projects/Web/Swift/kisiBootcamp/.build/checkouts/sql/Sources/SQL/SQLCreateIndex.swift /Users/Jorge/Desktop/Projects/Web/Swift/kisiBootcamp/.build/checkouts/sql/Sources/SQL/SQLDropIndex.swift /Users/Jorge/Desktop/Projects/Web/Swift/kisiBootcamp/.build/checkouts/sql/Sources/SQL/SQLGroupBy.swift /Users/Jorge/Desktop/Projects/Web/Swift/kisiBootcamp/.build/checkouts/sql/Sources/SQL/SQLOrderBy.swift /Users/Jorge/Desktop/Projects/Web/Swift/kisiBootcamp/.build/checkouts/sql/Sources/SQL/SQLForeignKey.swift /Users/Jorge/Desktop/Projects/Web/Swift/kisiBootcamp/.build/checkouts/sql/Sources/SQL/SQLPrimaryKey.swift /Users/Jorge/Desktop/Projects/Web/Swift/kisiBootcamp/.build/checkouts/sql/Sources/SQL/SQLQuery.swift /Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/lib/swift/macosx/x86_64/ObjectiveC.swiftmodule /Users/Jorge/Desktop/Projects/Web/Swift/kisiBootcamp/.build/x86_64-apple-macosx/debug/NIO.swiftmodule /Users/Jorge/Desktop/Projects/Web/Swift/kisiBootcamp/.build/x86_64-apple-macosx/debug/Async.swiftmodule /Users/Jorge/Desktop/Projects/Web/Swift/kisiBootcamp/.build/x86_64-apple-macosx/debug/Service.swiftmodule /Users/Jorge/Desktop/Projects/Web/Swift/kisiBootcamp/.build/x86_64-apple-macosx/debug/Core.swiftmodule /Users/Jorge/Desktop/Projects/Web/Swift/kisiBootcamp/.build/x86_64-apple-macosx/debug/Debugging.swiftmodule /Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/lib/swift/macosx/x86_64/Dispatch.swiftmodule /Users/Jorge/Desktop/Projects/Web/Swift/kisiBootcamp/.build/x86_64-apple-macosx/debug/COperatingSystem.swiftmodule /Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/lib/swift/macosx/x86_64/Darwin.swiftmodule /Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/lib/swift/macosx/x86_64/Foundation.swiftmodule /Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/lib/swift/macosx/x86_64/CoreFoundation.swiftmodule /Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/lib/swift/macosx/x86_64/CoreGraphics.swiftmodule /Users/Jorge/Desktop/Projects/Web/Swift/kisiBootcamp/.build/x86_64-apple-macosx/debug/NIOConcurrencyHelpers.swiftmodule /Users/Jorge/Desktop/Projects/Web/Swift/kisiBootcamp/.build/x86_64-apple-macosx/debug/Bits.swiftmodule /Users/Jorge/Desktop/Projects/Web/Swift/kisiBootcamp/.build/x86_64-apple-macosx/debug/NIOFoundationCompat.swiftmodule /Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/lib/swift/macosx/x86_64/Swift.swiftmodule /Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/lib/swift/macosx/x86_64/IOKit.swiftmodule /Users/Jorge/Desktop/Projects/Web/Swift/kisiBootcamp/.build/x86_64-apple-macosx/debug/DatabaseKit.swiftmodule /Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/lib/swift/macosx/x86_64/SwiftOnoneSupport.swiftmodule /Users/Jorge/Desktop/Projects/Web/Swift/kisiBootcamp/.build/checkouts/swift-nio/Sources/CNIOAtomics/include/cpp_magic.h /Users/Jorge/Desktop/Projects/Web/Swift/kisiBootcamp/.build/checkouts/swift-nio/Sources/CNIOLinux/include/ifaddrs-android.h /Users/Jorge/Desktop/Projects/Web/Swift/kisiBootcamp/.build/checkouts/swift-nio/Sources/CNIODarwin/include/CNIODarwin.h /Users/Jorge/Desktop/Projects/Web/Swift/kisiBootcamp/.build/checkouts/swift-nio/Sources/CNIOAtomics/include/CNIOAtomics.h /Users/Jorge/Desktop/Projects/Web/Swift/kisiBootcamp/.build/checkouts/swift-nio/Sources/CNIOLinux/include/CNIOLinux.h /Users/Jorge/Desktop/Projects/Web/Swift/kisiBootcamp/.build/x86_64-apple-macosx/debug/CNIOSHA1.build/module.modulemap /Users/Jorge/Desktop/Projects/Web/Swift/kisiBootcamp/.build/x86_64-apple-macosx/debug/CNIOOpenSSL.build/module.modulemap /Users/Jorge/Desktop/Projects/Web/Swift/kisiBootcamp/.build/x86_64-apple-macosx/debug/CCryptoOpenSSL.build/module.modulemap /Users/Jorge/Desktop/Projects/Web/Swift/kisiBootcamp/.build/x86_64-apple-macosx/debug/CNIOZlib.build/module.modulemap /Users/Jorge/Desktop/Projects/Web/Swift/kisiBootcamp/.build/x86_64-apple-macosx/debug/CNIODarwin.build/module.modulemap /Users/Jorge/Desktop/Projects/Web/Swift/kisiBootcamp/.build/x86_64-apple-macosx/debug/CNIOHTTPParser.build/module.modulemap /Users/Jorge/Desktop/Projects/Web/Swift/kisiBootcamp/.build/x86_64-apple-macosx/debug/CNIOAtomics.build/module.modulemap /Users/Jorge/Desktop/Projects/Web/Swift/kisiBootcamp/.build/x86_64-apple-macosx/debug/CNIOLinux.build/module.modulemap /Users/Jorge/Desktop/Projects/Web/Swift/kisiBootcamp/.build/checkouts/swift-nio-zlib-support/module.modulemap /Applications/Xcode.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX10.14.sdk/usr/include/objc/ObjectiveC.apinotes /Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/lib/swift/macosx/x86_64/Dispatch.apinotes /Applications/Xcode.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX10.14.sdk/usr/include/Darwin.apinotes /Applications/Xcode.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX10.14.sdk/System/Library/Frameworks/Foundation.framework/Headers/Foundation.apinotes /Applications/Xcode.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX10.14.sdk/System/Library/Frameworks/CoreGraphics.framework/Headers/CoreGraphics.apinotes /Applications/Xcode.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX10.14.sdk/System/Library/Frameworks/ApplicationServices.framework/Headers/ApplicationServices.apinotes /Applications/Xcode.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX10.14.sdk/System/Library/Frameworks/CoreText.framework/Headers/CoreText.apinotes /Applications/Xcode.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX10.14.sdk/System/Library/Frameworks/Security.framework/Headers/Security.apinotes
/Users/Jorge/Desktop/Projects/Web/Swift/kisiBootcamp/.build/x86_64-apple-macosx/debug/SQL.build/SQLCreateIndexBuilder~partial.swiftmodule : /Users/Jorge/Desktop/Projects/Web/Swift/kisiBootcamp/.build/checkouts/sql/Sources/SQL/SQLBind.swift /Users/Jorge/Desktop/Projects/Web/Swift/kisiBootcamp/.build/checkouts/sql/Sources/SQL/SQLJoinMethod.swift /Users/Jorge/Desktop/Projects/Web/Swift/kisiBootcamp/.build/checkouts/sql/Sources/SQL/SQLTable.swift /Users/Jorge/Desktop/Projects/Web/Swift/kisiBootcamp/.build/checkouts/sql/Sources/SQL/SQLCreateTable.swift /Users/Jorge/Desktop/Projects/Web/Swift/kisiBootcamp/.build/checkouts/sql/Sources/SQL/SQLDropTable.swift /Users/Jorge/Desktop/Projects/Web/Swift/kisiBootcamp/.build/checkouts/sql/Sources/SQL/SQLAlterTable.swift /Users/Jorge/Desktop/Projects/Web/Swift/kisiBootcamp/.build/checkouts/sql/Sources/SQL/SQLSerializable.swift /Users/Jorge/Desktop/Projects/Web/Swift/kisiBootcamp/.build/checkouts/sql/Sources/SQL/SQLDataType.swift /Users/Jorge/Desktop/Projects/Web/Swift/kisiBootcamp/.build/checkouts/sql/Sources/SQL/SQLUpdate.swift /Users/Jorge/Desktop/Projects/Web/Swift/kisiBootcamp/.build/checkouts/sql/Sources/SQL/SQLDelete.swift /Users/Jorge/Desktop/Projects/Web/Swift/kisiBootcamp/.build/checkouts/sql/Sources/SQL/SQLLiteral.swift /Users/Jorge/Desktop/Projects/Web/Swift/kisiBootcamp/.build/checkouts/sql/Sources/SQL/SQLBoolLiteral.swift /Users/Jorge/Desktop/Projects/Web/Swift/kisiBootcamp/.build/checkouts/sql/Sources/SQL/SQLDefaultLiteral.swift /Users/Jorge/Desktop/Projects/Web/Swift/kisiBootcamp/.build/checkouts/sql/Sources/SQL/SQLTableConstraintAlgorithm.swift /Users/Jorge/Desktop/Projects/Web/Swift/kisiBootcamp/.build/checkouts/sql/Sources/SQL/SQLColumnConstraintAlgorithm.swift /Users/Jorge/Desktop/Projects/Web/Swift/kisiBootcamp/.build/checkouts/sql/Sources/SQL/SQLJoin.swift /Users/Jorge/Desktop/Projects/Web/Swift/kisiBootcamp/.build/checkouts/sql/Sources/SQL/SQLExpression.swift /Users/Jorge/Desktop/Projects/Web/Swift/kisiBootcamp/.build/checkouts/sql/Sources/SQL/SQLSelectExpression.swift /Users/Jorge/Desktop/Projects/Web/Swift/kisiBootcamp/.build/checkouts/sql/Sources/SQL/SQLCollation.swift /Users/Jorge/Desktop/Projects/Web/Swift/kisiBootcamp/.build/checkouts/sql/Sources/SQL/SQLForeignKeyAction.swift /Users/Jorge/Desktop/Projects/Web/Swift/kisiBootcamp/.build/checkouts/sql/Sources/SQL/SQLConnection.swift /Users/Jorge/Desktop/Projects/Web/Swift/kisiBootcamp/.build/checkouts/sql/Sources/SQL/SQLDirection.swift /Users/Jorge/Desktop/Projects/Web/Swift/kisiBootcamp/.build/checkouts/sql/Sources/SQL/SQLFunction.swift /Users/Jorge/Desktop/Projects/Web/Swift/kisiBootcamp/.build/checkouts/sql/Sources/SQL/SQLColumnDefinition.swift /Users/Jorge/Desktop/Projects/Web/Swift/kisiBootcamp/.build/checkouts/sql/Sources/SQL/SQLCreateTableBuilder.swift /Users/Jorge/Desktop/Projects/Web/Swift/kisiBootcamp/.build/checkouts/sql/Sources/SQL/SQLDropTableBuilder.swift /Users/Jorge/Desktop/Projects/Web/Swift/kisiBootcamp/.build/checkouts/sql/Sources/SQL/SQLAlterTableBuilder.swift /Users/Jorge/Desktop/Projects/Web/Swift/kisiBootcamp/.build/checkouts/sql/Sources/SQL/SQLPredicateBuilder.swift /Users/Jorge/Desktop/Projects/Web/Swift/kisiBootcamp/.build/checkouts/sql/Sources/SQL/SQLUpdateBuilder.swift /Users/Jorge/Desktop/Projects/Web/Swift/kisiBootcamp/.build/checkouts/sql/Sources/SQL/SQLDeleteBuilder.swift /Users/Jorge/Desktop/Projects/Web/Swift/kisiBootcamp/.build/checkouts/sql/Sources/SQL/SQLColumnBuilder.swift /Users/Jorge/Desktop/Projects/Web/Swift/kisiBootcamp/.build/checkouts/sql/Sources/SQL/SQLPredicateGroupBuilder.swift /Users/Jorge/Desktop/Projects/Web/Swift/kisiBootcamp/.build/checkouts/sql/Sources/SQL/SQLSelectBuilder.swift /Users/Jorge/Desktop/Projects/Web/Swift/kisiBootcamp/.build/checkouts/sql/Sources/SQL/SQLInsertBuilder.swift /Users/Jorge/Desktop/Projects/Web/Swift/kisiBootcamp/.build/checkouts/sql/Sources/SQL/SQLRawBuilder.swift /Users/Jorge/Desktop/Projects/Web/Swift/kisiBootcamp/.build/checkouts/sql/Sources/SQL/SQLCreateIndexBuilder.swift /Users/Jorge/Desktop/Projects/Web/Swift/kisiBootcamp/.build/checkouts/sql/Sources/SQL/SQLQueryBuilder.swift /Users/Jorge/Desktop/Projects/Web/Swift/kisiBootcamp/.build/checkouts/sql/Sources/SQL/SQLQueryEncoder.swift /Users/Jorge/Desktop/Projects/Web/Swift/kisiBootcamp/.build/checkouts/sql/Sources/SQL/SQLQueryFetcher.swift /Users/Jorge/Desktop/Projects/Web/Swift/kisiBootcamp/.build/checkouts/sql/Sources/SQL/SQLIndexModifier.swift /Users/Jorge/Desktop/Projects/Web/Swift/kisiBootcamp/.build/checkouts/sql/Sources/SQL/SQLIdentifier.swift /Users/Jorge/Desktop/Projects/Web/Swift/kisiBootcamp/.build/checkouts/sql/Sources/SQL/SQLTableIdentifier.swift /Users/Jorge/Desktop/Projects/Web/Swift/kisiBootcamp/.build/checkouts/sql/Sources/SQL/SQLColumnIdentifier.swift /Users/Jorge/Desktop/Projects/Web/Swift/kisiBootcamp/.build/checkouts/sql/Sources/SQL/SQLError.swift /Users/Jorge/Desktop/Projects/Web/Swift/kisiBootcamp/.build/checkouts/sql/Sources/SQL/SQLBinaryOperator.swift /Users/Jorge/Desktop/Projects/Web/Swift/kisiBootcamp/.build/checkouts/sql/Sources/SQL/Exports.swift /Users/Jorge/Desktop/Projects/Web/Swift/kisiBootcamp/.build/checkouts/sql/Sources/SQL/SQLSelect.swift /Users/Jorge/Desktop/Projects/Web/Swift/kisiBootcamp/.build/checkouts/sql/Sources/SQL/SQLDistinct.swift /Users/Jorge/Desktop/Projects/Web/Swift/kisiBootcamp/.build/checkouts/sql/Sources/SQL/SQLFunctionArgument.swift /Users/Jorge/Desktop/Projects/Web/Swift/kisiBootcamp/.build/checkouts/sql/Sources/SQL/SQLTableConstraint.swift /Users/Jorge/Desktop/Projects/Web/Swift/kisiBootcamp/.build/checkouts/sql/Sources/SQL/SQLColumnConstraint.swift /Users/Jorge/Desktop/Projects/Web/Swift/kisiBootcamp/.build/checkouts/sql/Sources/SQL/SQLInsert.swift /Users/Jorge/Desktop/Projects/Web/Swift/kisiBootcamp/.build/checkouts/sql/Sources/SQL/SQLCreateIndex.swift /Users/Jorge/Desktop/Projects/Web/Swift/kisiBootcamp/.build/checkouts/sql/Sources/SQL/SQLDropIndex.swift /Users/Jorge/Desktop/Projects/Web/Swift/kisiBootcamp/.build/checkouts/sql/Sources/SQL/SQLGroupBy.swift /Users/Jorge/Desktop/Projects/Web/Swift/kisiBootcamp/.build/checkouts/sql/Sources/SQL/SQLOrderBy.swift /Users/Jorge/Desktop/Projects/Web/Swift/kisiBootcamp/.build/checkouts/sql/Sources/SQL/SQLForeignKey.swift /Users/Jorge/Desktop/Projects/Web/Swift/kisiBootcamp/.build/checkouts/sql/Sources/SQL/SQLPrimaryKey.swift /Users/Jorge/Desktop/Projects/Web/Swift/kisiBootcamp/.build/checkouts/sql/Sources/SQL/SQLQuery.swift /Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/lib/swift/macosx/x86_64/ObjectiveC.swiftmodule /Users/Jorge/Desktop/Projects/Web/Swift/kisiBootcamp/.build/x86_64-apple-macosx/debug/NIO.swiftmodule /Users/Jorge/Desktop/Projects/Web/Swift/kisiBootcamp/.build/x86_64-apple-macosx/debug/Async.swiftmodule /Users/Jorge/Desktop/Projects/Web/Swift/kisiBootcamp/.build/x86_64-apple-macosx/debug/Service.swiftmodule /Users/Jorge/Desktop/Projects/Web/Swift/kisiBootcamp/.build/x86_64-apple-macosx/debug/Core.swiftmodule /Users/Jorge/Desktop/Projects/Web/Swift/kisiBootcamp/.build/x86_64-apple-macosx/debug/Debugging.swiftmodule /Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/lib/swift/macosx/x86_64/Dispatch.swiftmodule /Users/Jorge/Desktop/Projects/Web/Swift/kisiBootcamp/.build/x86_64-apple-macosx/debug/COperatingSystem.swiftmodule /Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/lib/swift/macosx/x86_64/Darwin.swiftmodule /Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/lib/swift/macosx/x86_64/Foundation.swiftmodule /Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/lib/swift/macosx/x86_64/CoreFoundation.swiftmodule /Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/lib/swift/macosx/x86_64/CoreGraphics.swiftmodule /Users/Jorge/Desktop/Projects/Web/Swift/kisiBootcamp/.build/x86_64-apple-macosx/debug/NIOConcurrencyHelpers.swiftmodule /Users/Jorge/Desktop/Projects/Web/Swift/kisiBootcamp/.build/x86_64-apple-macosx/debug/Bits.swiftmodule /Users/Jorge/Desktop/Projects/Web/Swift/kisiBootcamp/.build/x86_64-apple-macosx/debug/NIOFoundationCompat.swiftmodule /Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/lib/swift/macosx/x86_64/Swift.swiftmodule /Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/lib/swift/macosx/x86_64/IOKit.swiftmodule /Users/Jorge/Desktop/Projects/Web/Swift/kisiBootcamp/.build/x86_64-apple-macosx/debug/DatabaseKit.swiftmodule /Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/lib/swift/macosx/x86_64/SwiftOnoneSupport.swiftmodule /Users/Jorge/Desktop/Projects/Web/Swift/kisiBootcamp/.build/checkouts/swift-nio/Sources/CNIOAtomics/include/cpp_magic.h /Users/Jorge/Desktop/Projects/Web/Swift/kisiBootcamp/.build/checkouts/swift-nio/Sources/CNIOLinux/include/ifaddrs-android.h /Users/Jorge/Desktop/Projects/Web/Swift/kisiBootcamp/.build/checkouts/swift-nio/Sources/CNIODarwin/include/CNIODarwin.h /Users/Jorge/Desktop/Projects/Web/Swift/kisiBootcamp/.build/checkouts/swift-nio/Sources/CNIOAtomics/include/CNIOAtomics.h /Users/Jorge/Desktop/Projects/Web/Swift/kisiBootcamp/.build/checkouts/swift-nio/Sources/CNIOLinux/include/CNIOLinux.h /Users/Jorge/Desktop/Projects/Web/Swift/kisiBootcamp/.build/x86_64-apple-macosx/debug/CNIOSHA1.build/module.modulemap /Users/Jorge/Desktop/Projects/Web/Swift/kisiBootcamp/.build/x86_64-apple-macosx/debug/CNIOOpenSSL.build/module.modulemap /Users/Jorge/Desktop/Projects/Web/Swift/kisiBootcamp/.build/x86_64-apple-macosx/debug/CCryptoOpenSSL.build/module.modulemap /Users/Jorge/Desktop/Projects/Web/Swift/kisiBootcamp/.build/x86_64-apple-macosx/debug/CNIOZlib.build/module.modulemap /Users/Jorge/Desktop/Projects/Web/Swift/kisiBootcamp/.build/x86_64-apple-macosx/debug/CNIODarwin.build/module.modulemap /Users/Jorge/Desktop/Projects/Web/Swift/kisiBootcamp/.build/x86_64-apple-macosx/debug/CNIOHTTPParser.build/module.modulemap /Users/Jorge/Desktop/Projects/Web/Swift/kisiBootcamp/.build/x86_64-apple-macosx/debug/CNIOAtomics.build/module.modulemap /Users/Jorge/Desktop/Projects/Web/Swift/kisiBootcamp/.build/x86_64-apple-macosx/debug/CNIOLinux.build/module.modulemap /Users/Jorge/Desktop/Projects/Web/Swift/kisiBootcamp/.build/checkouts/swift-nio-zlib-support/module.modulemap /Applications/Xcode.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX10.14.sdk/usr/include/objc/ObjectiveC.apinotes /Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/lib/swift/macosx/x86_64/Dispatch.apinotes /Applications/Xcode.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX10.14.sdk/usr/include/Darwin.apinotes /Applications/Xcode.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX10.14.sdk/System/Library/Frameworks/Foundation.framework/Headers/Foundation.apinotes /Applications/Xcode.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX10.14.sdk/System/Library/Frameworks/CoreGraphics.framework/Headers/CoreGraphics.apinotes /Applications/Xcode.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX10.14.sdk/System/Library/Frameworks/ApplicationServices.framework/Headers/ApplicationServices.apinotes /Applications/Xcode.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX10.14.sdk/System/Library/Frameworks/CoreText.framework/Headers/CoreText.apinotes /Applications/Xcode.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX10.14.sdk/System/Library/Frameworks/Security.framework/Headers/Security.apinotes
/Users/Jorge/Desktop/Projects/Web/Swift/kisiBootcamp/.build/x86_64-apple-macosx/debug/SQL.build/SQLCreateIndexBuilder~partial.swiftdoc : /Users/Jorge/Desktop/Projects/Web/Swift/kisiBootcamp/.build/checkouts/sql/Sources/SQL/SQLBind.swift /Users/Jorge/Desktop/Projects/Web/Swift/kisiBootcamp/.build/checkouts/sql/Sources/SQL/SQLJoinMethod.swift /Users/Jorge/Desktop/Projects/Web/Swift/kisiBootcamp/.build/checkouts/sql/Sources/SQL/SQLTable.swift /Users/Jorge/Desktop/Projects/Web/Swift/kisiBootcamp/.build/checkouts/sql/Sources/SQL/SQLCreateTable.swift /Users/Jorge/Desktop/Projects/Web/Swift/kisiBootcamp/.build/checkouts/sql/Sources/SQL/SQLDropTable.swift /Users/Jorge/Desktop/Projects/Web/Swift/kisiBootcamp/.build/checkouts/sql/Sources/SQL/SQLAlterTable.swift /Users/Jorge/Desktop/Projects/Web/Swift/kisiBootcamp/.build/checkouts/sql/Sources/SQL/SQLSerializable.swift /Users/Jorge/Desktop/Projects/Web/Swift/kisiBootcamp/.build/checkouts/sql/Sources/SQL/SQLDataType.swift /Users/Jorge/Desktop/Projects/Web/Swift/kisiBootcamp/.build/checkouts/sql/Sources/SQL/SQLUpdate.swift /Users/Jorge/Desktop/Projects/Web/Swift/kisiBootcamp/.build/checkouts/sql/Sources/SQL/SQLDelete.swift /Users/Jorge/Desktop/Projects/Web/Swift/kisiBootcamp/.build/checkouts/sql/Sources/SQL/SQLLiteral.swift /Users/Jorge/Desktop/Projects/Web/Swift/kisiBootcamp/.build/checkouts/sql/Sources/SQL/SQLBoolLiteral.swift /Users/Jorge/Desktop/Projects/Web/Swift/kisiBootcamp/.build/checkouts/sql/Sources/SQL/SQLDefaultLiteral.swift /Users/Jorge/Desktop/Projects/Web/Swift/kisiBootcamp/.build/checkouts/sql/Sources/SQL/SQLTableConstraintAlgorithm.swift /Users/Jorge/Desktop/Projects/Web/Swift/kisiBootcamp/.build/checkouts/sql/Sources/SQL/SQLColumnConstraintAlgorithm.swift /Users/Jorge/Desktop/Projects/Web/Swift/kisiBootcamp/.build/checkouts/sql/Sources/SQL/SQLJoin.swift /Users/Jorge/Desktop/Projects/Web/Swift/kisiBootcamp/.build/checkouts/sql/Sources/SQL/SQLExpression.swift /Users/Jorge/Desktop/Projects/Web/Swift/kisiBootcamp/.build/checkouts/sql/Sources/SQL/SQLSelectExpression.swift /Users/Jorge/Desktop/Projects/Web/Swift/kisiBootcamp/.build/checkouts/sql/Sources/SQL/SQLCollation.swift /Users/Jorge/Desktop/Projects/Web/Swift/kisiBootcamp/.build/checkouts/sql/Sources/SQL/SQLForeignKeyAction.swift /Users/Jorge/Desktop/Projects/Web/Swift/kisiBootcamp/.build/checkouts/sql/Sources/SQL/SQLConnection.swift /Users/Jorge/Desktop/Projects/Web/Swift/kisiBootcamp/.build/checkouts/sql/Sources/SQL/SQLDirection.swift /Users/Jorge/Desktop/Projects/Web/Swift/kisiBootcamp/.build/checkouts/sql/Sources/SQL/SQLFunction.swift /Users/Jorge/Desktop/Projects/Web/Swift/kisiBootcamp/.build/checkouts/sql/Sources/SQL/SQLColumnDefinition.swift /Users/Jorge/Desktop/Projects/Web/Swift/kisiBootcamp/.build/checkouts/sql/Sources/SQL/SQLCreateTableBuilder.swift /Users/Jorge/Desktop/Projects/Web/Swift/kisiBootcamp/.build/checkouts/sql/Sources/SQL/SQLDropTableBuilder.swift /Users/Jorge/Desktop/Projects/Web/Swift/kisiBootcamp/.build/checkouts/sql/Sources/SQL/SQLAlterTableBuilder.swift /Users/Jorge/Desktop/Projects/Web/Swift/kisiBootcamp/.build/checkouts/sql/Sources/SQL/SQLPredicateBuilder.swift /Users/Jorge/Desktop/Projects/Web/Swift/kisiBootcamp/.build/checkouts/sql/Sources/SQL/SQLUpdateBuilder.swift /Users/Jorge/Desktop/Projects/Web/Swift/kisiBootcamp/.build/checkouts/sql/Sources/SQL/SQLDeleteBuilder.swift /Users/Jorge/Desktop/Projects/Web/Swift/kisiBootcamp/.build/checkouts/sql/Sources/SQL/SQLColumnBuilder.swift /Users/Jorge/Desktop/Projects/Web/Swift/kisiBootcamp/.build/checkouts/sql/Sources/SQL/SQLPredicateGroupBuilder.swift /Users/Jorge/Desktop/Projects/Web/Swift/kisiBootcamp/.build/checkouts/sql/Sources/SQL/SQLSelectBuilder.swift /Users/Jorge/Desktop/Projects/Web/Swift/kisiBootcamp/.build/checkouts/sql/Sources/SQL/SQLInsertBuilder.swift /Users/Jorge/Desktop/Projects/Web/Swift/kisiBootcamp/.build/checkouts/sql/Sources/SQL/SQLRawBuilder.swift /Users/Jorge/Desktop/Projects/Web/Swift/kisiBootcamp/.build/checkouts/sql/Sources/SQL/SQLCreateIndexBuilder.swift /Users/Jorge/Desktop/Projects/Web/Swift/kisiBootcamp/.build/checkouts/sql/Sources/SQL/SQLQueryBuilder.swift /Users/Jorge/Desktop/Projects/Web/Swift/kisiBootcamp/.build/checkouts/sql/Sources/SQL/SQLQueryEncoder.swift /Users/Jorge/Desktop/Projects/Web/Swift/kisiBootcamp/.build/checkouts/sql/Sources/SQL/SQLQueryFetcher.swift /Users/Jorge/Desktop/Projects/Web/Swift/kisiBootcamp/.build/checkouts/sql/Sources/SQL/SQLIndexModifier.swift /Users/Jorge/Desktop/Projects/Web/Swift/kisiBootcamp/.build/checkouts/sql/Sources/SQL/SQLIdentifier.swift /Users/Jorge/Desktop/Projects/Web/Swift/kisiBootcamp/.build/checkouts/sql/Sources/SQL/SQLTableIdentifier.swift /Users/Jorge/Desktop/Projects/Web/Swift/kisiBootcamp/.build/checkouts/sql/Sources/SQL/SQLColumnIdentifier.swift /Users/Jorge/Desktop/Projects/Web/Swift/kisiBootcamp/.build/checkouts/sql/Sources/SQL/SQLError.swift /Users/Jorge/Desktop/Projects/Web/Swift/kisiBootcamp/.build/checkouts/sql/Sources/SQL/SQLBinaryOperator.swift /Users/Jorge/Desktop/Projects/Web/Swift/kisiBootcamp/.build/checkouts/sql/Sources/SQL/Exports.swift /Users/Jorge/Desktop/Projects/Web/Swift/kisiBootcamp/.build/checkouts/sql/Sources/SQL/SQLSelect.swift /Users/Jorge/Desktop/Projects/Web/Swift/kisiBootcamp/.build/checkouts/sql/Sources/SQL/SQLDistinct.swift /Users/Jorge/Desktop/Projects/Web/Swift/kisiBootcamp/.build/checkouts/sql/Sources/SQL/SQLFunctionArgument.swift /Users/Jorge/Desktop/Projects/Web/Swift/kisiBootcamp/.build/checkouts/sql/Sources/SQL/SQLTableConstraint.swift /Users/Jorge/Desktop/Projects/Web/Swift/kisiBootcamp/.build/checkouts/sql/Sources/SQL/SQLColumnConstraint.swift /Users/Jorge/Desktop/Projects/Web/Swift/kisiBootcamp/.build/checkouts/sql/Sources/SQL/SQLInsert.swift /Users/Jorge/Desktop/Projects/Web/Swift/kisiBootcamp/.build/checkouts/sql/Sources/SQL/SQLCreateIndex.swift /Users/Jorge/Desktop/Projects/Web/Swift/kisiBootcamp/.build/checkouts/sql/Sources/SQL/SQLDropIndex.swift /Users/Jorge/Desktop/Projects/Web/Swift/kisiBootcamp/.build/checkouts/sql/Sources/SQL/SQLGroupBy.swift /Users/Jorge/Desktop/Projects/Web/Swift/kisiBootcamp/.build/checkouts/sql/Sources/SQL/SQLOrderBy.swift /Users/Jorge/Desktop/Projects/Web/Swift/kisiBootcamp/.build/checkouts/sql/Sources/SQL/SQLForeignKey.swift /Users/Jorge/Desktop/Projects/Web/Swift/kisiBootcamp/.build/checkouts/sql/Sources/SQL/SQLPrimaryKey.swift /Users/Jorge/Desktop/Projects/Web/Swift/kisiBootcamp/.build/checkouts/sql/Sources/SQL/SQLQuery.swift /Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/lib/swift/macosx/x86_64/ObjectiveC.swiftmodule /Users/Jorge/Desktop/Projects/Web/Swift/kisiBootcamp/.build/x86_64-apple-macosx/debug/NIO.swiftmodule /Users/Jorge/Desktop/Projects/Web/Swift/kisiBootcamp/.build/x86_64-apple-macosx/debug/Async.swiftmodule /Users/Jorge/Desktop/Projects/Web/Swift/kisiBootcamp/.build/x86_64-apple-macosx/debug/Service.swiftmodule /Users/Jorge/Desktop/Projects/Web/Swift/kisiBootcamp/.build/x86_64-apple-macosx/debug/Core.swiftmodule /Users/Jorge/Desktop/Projects/Web/Swift/kisiBootcamp/.build/x86_64-apple-macosx/debug/Debugging.swiftmodule /Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/lib/swift/macosx/x86_64/Dispatch.swiftmodule /Users/Jorge/Desktop/Projects/Web/Swift/kisiBootcamp/.build/x86_64-apple-macosx/debug/COperatingSystem.swiftmodule /Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/lib/swift/macosx/x86_64/Darwin.swiftmodule /Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/lib/swift/macosx/x86_64/Foundation.swiftmodule /Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/lib/swift/macosx/x86_64/CoreFoundation.swiftmodule /Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/lib/swift/macosx/x86_64/CoreGraphics.swiftmodule /Users/Jorge/Desktop/Projects/Web/Swift/kisiBootcamp/.build/x86_64-apple-macosx/debug/NIOConcurrencyHelpers.swiftmodule /Users/Jorge/Desktop/Projects/Web/Swift/kisiBootcamp/.build/x86_64-apple-macosx/debug/Bits.swiftmodule /Users/Jorge/Desktop/Projects/Web/Swift/kisiBootcamp/.build/x86_64-apple-macosx/debug/NIOFoundationCompat.swiftmodule /Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/lib/swift/macosx/x86_64/Swift.swiftmodule /Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/lib/swift/macosx/x86_64/IOKit.swiftmodule /Users/Jorge/Desktop/Projects/Web/Swift/kisiBootcamp/.build/x86_64-apple-macosx/debug/DatabaseKit.swiftmodule /Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/lib/swift/macosx/x86_64/SwiftOnoneSupport.swiftmodule /Users/Jorge/Desktop/Projects/Web/Swift/kisiBootcamp/.build/checkouts/swift-nio/Sources/CNIOAtomics/include/cpp_magic.h /Users/Jorge/Desktop/Projects/Web/Swift/kisiBootcamp/.build/checkouts/swift-nio/Sources/CNIOLinux/include/ifaddrs-android.h /Users/Jorge/Desktop/Projects/Web/Swift/kisiBootcamp/.build/checkouts/swift-nio/Sources/CNIODarwin/include/CNIODarwin.h /Users/Jorge/Desktop/Projects/Web/Swift/kisiBootcamp/.build/checkouts/swift-nio/Sources/CNIOAtomics/include/CNIOAtomics.h /Users/Jorge/Desktop/Projects/Web/Swift/kisiBootcamp/.build/checkouts/swift-nio/Sources/CNIOLinux/include/CNIOLinux.h /Users/Jorge/Desktop/Projects/Web/Swift/kisiBootcamp/.build/x86_64-apple-macosx/debug/CNIOSHA1.build/module.modulemap /Users/Jorge/Desktop/Projects/Web/Swift/kisiBootcamp/.build/x86_64-apple-macosx/debug/CNIOOpenSSL.build/module.modulemap /Users/Jorge/Desktop/Projects/Web/Swift/kisiBootcamp/.build/x86_64-apple-macosx/debug/CCryptoOpenSSL.build/module.modulemap /Users/Jorge/Desktop/Projects/Web/Swift/kisiBootcamp/.build/x86_64-apple-macosx/debug/CNIOZlib.build/module.modulemap /Users/Jorge/Desktop/Projects/Web/Swift/kisiBootcamp/.build/x86_64-apple-macosx/debug/CNIODarwin.build/module.modulemap /Users/Jorge/Desktop/Projects/Web/Swift/kisiBootcamp/.build/x86_64-apple-macosx/debug/CNIOHTTPParser.build/module.modulemap /Users/Jorge/Desktop/Projects/Web/Swift/kisiBootcamp/.build/x86_64-apple-macosx/debug/CNIOAtomics.build/module.modulemap /Users/Jorge/Desktop/Projects/Web/Swift/kisiBootcamp/.build/x86_64-apple-macosx/debug/CNIOLinux.build/module.modulemap /Users/Jorge/Desktop/Projects/Web/Swift/kisiBootcamp/.build/checkouts/swift-nio-zlib-support/module.modulemap /Applications/Xcode.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX10.14.sdk/usr/include/objc/ObjectiveC.apinotes /Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/lib/swift/macosx/x86_64/Dispatch.apinotes /Applications/Xcode.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX10.14.sdk/usr/include/Darwin.apinotes /Applications/Xcode.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX10.14.sdk/System/Library/Frameworks/Foundation.framework/Headers/Foundation.apinotes /Applications/Xcode.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX10.14.sdk/System/Library/Frameworks/CoreGraphics.framework/Headers/CoreGraphics.apinotes /Applications/Xcode.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX10.14.sdk/System/Library/Frameworks/ApplicationServices.framework/Headers/ApplicationServices.apinotes /Applications/Xcode.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX10.14.sdk/System/Library/Frameworks/CoreText.framework/Headers/CoreText.apinotes /Applications/Xcode.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX10.14.sdk/System/Library/Frameworks/Security.framework/Headers/Security.apinotes
| D |
/home/cmd/Programming/code/rust/hello_world/target/debug/deps/hello_world-b45241a20cf0faac.rmeta: src/main.rs
/home/cmd/Programming/code/rust/hello_world/target/debug/deps/hello_world-b45241a20cf0faac.d: src/main.rs
src/main.rs:
| D |
/*******************************************************************************
Memory Channel Storage Engine
This module implements the IStorageEngine for a memory channel using
Tokyo Cabinet as the real storage engine.
copyright:
Copyright (c) 2013-2017 sociomantic labs GmbH. All rights reserved
License:
Boost Software License Version 1.0. See LICENSE.txt for details.
*******************************************************************************/
module dhtnode.storage.StorageEngine;
/*******************************************************************************
Imports
*******************************************************************************/
import ocean.transition;
import dhtproto.client.legacy.DhtConst;
import swarm.node.storage.model.IStorageEngine;
import swarm.node.storage.listeners.Listeners;
import dhtnode.storage.StorageEngineStepIterator;
import ocean.util.log.Logger;
/*******************************************************************************
Static module logger
*******************************************************************************/
private Logger log;
static this ( )
{
log = Log.lookup("dhtnode.storage.MemoryStorage");
}
/***************************************************************************
Memory storage engine
***************************************************************************/
public class StorageEngine : IStorageEngine
{
import dhtnode.node.DhtHashRange;
import dhtnode.storage.tokyocabinet.c.tcmdb :
TCMDB,
tcmdbnew, tcmdbnew2, tcmdbvanish, tcmdbdel,
tcmdbput, tcmdbputkeep, tcmdbputcat,
tcmdbget, tcmdbforeach,
tcmdbout, tcmdbrnum, tcmdbmsiz, tcmdbvsiz,
tcmdbiterinit, tcmdbiterinit2, tcmdbiternext;
import Hash = swarm.util.Hash;
import ocean.core.TypeConvert;
import core.stdc.stdlib : free;
/***********************************************************************
Callback type used to delete channel files when the channel is removed.
Params:
id = name of the channel to remove
***********************************************************************/
public alias void delegate ( cstring id ) DeleteChannelCb;
private DeleteChannelCb delete_channel;
/***************************************************************************
Set of listeners waiting for data on this storage channel. When data
arrives (or a flush / finish signal for the channel), all registered
listeners are notified.
***************************************************************************/
protected alias IListeners!(cstring) Listeners;
protected Listeners listeners;
/***************************************************************************
Alias for a listener.
***************************************************************************/
public alias Listeners.Listener IListener;
/***************************************************************************
Tokyo cabinet database instance
***************************************************************************/
private TCMDB* db;
/***************************************************************************
Minimum and maximum record hashes supported by node
***************************************************************************/
private DhtHashRange hash_range;
/***********************************************************************
Constructor.
Params:
id = identifier string for this instance
hash_range = hash range for which this node is responsible
bnum = memory storage channels bnum value
delete_channel = callback used to delete channel files when the
channel is removed
***********************************************************************/
public this ( cstring id, DhtHashRange hash_range, uint bnum,
DeleteChannelCb delete_channel )
{
super(id);
this.hash_range = hash_range;
this.delete_channel = delete_channel;
this.listeners = new Listeners;
if ( bnum == 0 )
{
this.db = tcmdbnew();
}
else
{
this.db = tcmdbnew2(bnum);
}
}
/***********************************************************************
Puts a record into the database.
Params:
key = record key
value = record value
trigger_listeners = if true, any listeners registered for this
channel will be notified of the update to this record
Returns:
this instance
***********************************************************************/
public typeof(this) put ( cstring key, cstring value,
bool trigger_listeners = true )
{
tcmdbput(this.db, key.ptr, castFrom!(size_t).to!(int)(key.length),
value.ptr, castFrom!(size_t).to!(int)(value.length));
if ( trigger_listeners )
this.listeners.trigger(Listeners.Listener.Code.DataReady, key);
return this;
}
/***********************************************************************
Get record
Params:
key = key to lookup
value_buffer = buffer to receive record value output. The length of
this buffer is never decreased, only increased (if necessary).
This is an optimization, as this method is called extremely
frequently and array length resetting is not free (especially in
D2 builds, where assumeSafeAppend must be called).
value = record value output (slice of value_buffer)
Returns:
this instance
***********************************************************************/
public typeof(this) get ( cstring key, ref mstring value_buffer,
out mstring value )
{
int len;
void* value_;
value_ = cast(void*)tcmdbget(this.db, key.ptr,
castFrom!(size_t).to!(int)(key.length), &len);
bool found = !!value_;
if (found)
{
if ( value_buffer.length < len )
value_buffer.length = len;
value_buffer[0..len] = (cast(char*)value_)[0..len];
value = value_buffer[0..len];
free(value_);
}
return this;
}
/***********************************************************************
Get record's size
Params:
key = key to lookup
Returns:
size of record in bytes (0 if it doesn't exist)
***********************************************************************/
public size_t getSize ( cstring key )
{
auto s = tcmdbvsiz(this.db,
key.ptr, castFrom!(size_t).to!(int)(key.length));
return s < 0 ? 0 : s;
}
/***********************************************************************
Tells whether a record exists
Params:
key = record key
Returns:
true if record exists or false itherwise
************************************************************************/
public bool exists ( cstring key )
{
int size;
size = tcmdbvsiz(this.db, key.ptr, castFrom!(size_t).to!(int)(key.length));
return size >= 0;
}
/***********************************************************************
Remove record
Params:
key = key of record to remove
Returns:
this instance
***********************************************************************/
public typeof(this) remove ( cstring key )
{
tcmdbout(this.db, key.ptr, castFrom!(size_t).to!(int)(key.length));
return this;
}
/***************************************************************************
Checks whether the specified key string (expected to be a hex number) is
within the hash range of this storage engine.
Params:
key = record key
Returns:
true if the key is within the storage engine's hash range
TODO: duplicate of same function in MemoryStorageChannels
***************************************************************************/
public bool responsibleForKey ( cstring key )
{
auto hash = Hash.straightToHash(key);
return Hash.isWithinNodeResponsibility(hash, this.hash_range.range.min,
this.hash_range.range.max);
}
/**************************************************************************
opApply delegate. If the delegate returns <> 0, the iteration will be
aborted.
***************************************************************************/
public alias int delegate ( ref char[] key, ref char[] value ) IterDg;
/***************************************************************************
Context for db iteration (just stores a user-provided delegate)
***************************************************************************/
private struct IterContext
{
/***********************************************************************
User-provided opApply delegate to receive each record's key and
value
***********************************************************************/
IterDg dg;
/***********************************************************************
Return value of last call of the delegate. Required by opApply.
***********************************************************************/
int ret;
}
/***************************************************************************
TokyoCabinet-compatible iteration function. The opaque void* (the last
parameter) contains the iteration context (see iterate(), above), which
in turn contains the user-provided iteration delegate.
Params:
key_ptr = pointer to buffer containing record key
key_len = length of buffer containing record key
val_ptr = pointer to buffer containing record value
val_len = length of buffer containing record value
context_ = opaque context pointer (set in opApply(), above)
Returns:
true to continue iterating, false to break
***************************************************************************/
extern ( C ) private static bool db_iter ( void* key_ptr, int key_len,
void* val_ptr, int val_len, void* context_ )
{
auto key = (cast(char*)key_ptr)[0..key_len];
auto val = (cast(char*)val_ptr)[0..val_len];
auto context = cast(IterContext*)context_;
context.ret = context.dg(key, val);
return context.ret == 0;
}
/***************************************************************************
opApply over the complete contents of the storage engine. Note that this
iteration is non-interruptible and should only be used in cases where
you are certain that no other iterations will interfere with it.
***************************************************************************/
public int opApply ( IterDg dg )
{
IterContext context;
context.dg = dg;
tcmdbforeach(this.db, &db_iter, cast(void*)&context);
return context.ret;
}
/***********************************************************************
Initialises a step-by-step iterator over the keys of all records in
the database.
Params:
iterator = iterator to initialise
***********************************************************************/
public typeof(this) getAll ( StorageEngineStepIterator iterator )
{
iterator.setStorage(this);
return this;
}
/***************************************************************************
Reset method, called when the storage engine is returned to the pool in
IStorageChannels. Sends the Finish trigger to all registered listeners,
which will cause the requests to end (as the channel being listened to
is now gone).
***************************************************************************/
public override void reset ( )
{
this.listeners.trigger(IListener.Code.Finish, "");
}
/***************************************************************************
Flushes sending data buffers of consumer connections.
***************************************************************************/
public override void flush ( )
{
this.listeners.trigger(IListener.Code.Flush, "");
}
/***************************************************************************
Registers a listener with the channel. The dataReady() method of the
given listener will be called when data is put to the channel.
Params:
listener = listener to notify when data is ready
**************************************************************************/
public void registerListener ( IListener listener )
{
this.listeners.register(listener);
}
/***************************************************************************
Unregisters a listener from the channel.
Params:
listener = listener to stop notifying when data is ready
**************************************************************************/
public void unregisterListener ( IListener listener )
{
this.listeners.unregister(listener);
}
/***********************************************************************
Performs any actions needed to safely close a channel. In the case
of the memory database, nothing needs to be done.
(Called from IStorageChannels when removing a channel or shutting
down the node. In the former case, the channel is clear()ed then
close()d. In the latter case, the channel is only close()d.)
Returns:
this instance
***********************************************************************/
override public typeof(this) close ( )
{
return this;
}
/***********************************************************************
Removes all records from database. We also move the dump file for this
channel (if one has been written) to deleted/channel_name.tcm, in order
to ensure that if the node is restarted the deleted channel will not be
loaded again and restored!
(Called from IStorageChannels when removing a channel.)
Returns:
this instance
***********************************************************************/
override public typeof(this) clear ( )
{
tcmdbvanish(this.db);
this.delete_channel(this.id);
return this;
}
/***********************************************************************
Returns:
number of records stored
***********************************************************************/
public ulong num_records ( )
{
ulong num;
num = tcmdbrnum(this.db);
return num;
}
/***********************************************************************
Returns:
number of records stored
***********************************************************************/
public ulong num_bytes ( )
{
ulong size;
size = tcmdbmsiz(this.db);
return size;
}
/***********************************************************************
Gets the first key in the database.
Params:
key_buffer = buffer to receive record key output. The length of
this buffer is never decreased, only increased (if necessary).
This is an optimization, as this method is called extremely
frequently and array length resetting is not free (especially in
D2 builds, where assumeSafeAppend must be called).
key = record key output (slice of key_buffer)
Returns:
this instance
***********************************************************************/
public typeof(this) getFirstKey ( ref mstring key_buffer, out mstring key )
{
tcmdbiterinit(this.db);
this.iterateNextKey(key_buffer, key);
return this;
}
/***********************************************************************
Gets the key of the record following the specified key.
Notes:
* "following" means the next key in the TokyoCabinet storage, which
is *not* necessarily the next key in numerical order.
* If the last key has been removed, the iteration will be restarted
at the closest key. As above, the exact meaning of "closest" is
determined by TokyoCabinet.
Params:
last_key = key to iterate from
key_buffer = buffer to receive record key output. The length of
this buffer is never decreased, only increased (if necessary).
This is an optimization, as this method is called extremely
frequently and array length resetting is not free (especially in
D2 builds, where assumeSafeAppend must be called).
key = record key output (slice of key_buffer)
Returns:
this instance
***********************************************************************/
public typeof(this) getNextKey ( cstring last_key, ref mstring key_buffer,
out mstring key )
{
tcmdbiterinit2(this.db, last_key.ptr,
castFrom!(size_t).to!(int)(last_key.length));
if ( !this.iterateNextKey(key_buffer, key) )
return this;
this.iterateNextKey(key_buffer, key);
return this;
}
/**************************************************************************
Iterates from the current iteration position, getting the key of next
record in the database.
Params:
key_buffer = buffer to receive record key output. The length of
this buffer is never decreased, only increased (if necessary).
This is an optimization, as this method is called extremely
frequently and array length resetting is not free (especially in
D2 builds, where assumeSafeAppend must be called).
key = record key output (slice of key_buffer)
Returns
true on success or false if record not existing
***************************************************************************/
private bool iterateNextKey ( ref char[] key_buffer, out mstring key )
{
int len;
void* key_;
key_ = cast(void*)tcmdbiternext(this.db, &len);
bool found = !!key_;
if (found)
{
if ( key_buffer.length < len )
key_buffer.length = len;
key_buffer[0..len] = (cast(char*)key_)[0..len];
key = key_buffer[0..len];
free(key_);
}
return found;
}
}
| D |
// PERMUTE_ARGS:
// REQUIRED_ARGS: -D -Ddtest_results/compilable -o-
// POST_SCRIPT: compilable/extra-files/ddocAny-postscript.sh 648
module ddoc648;
/// Mixin declaration
mixin template Mixin1()
{
/// struct S
struct S { }
}
/// class A
class A
{
/// field x
int x;
/// no docs for mixin statement (only for expanded members)
mixin Mixin1!();
}
/// Mixin declaration2
mixin template Mixin2()
{
/// struct S2
struct S2 { }
}
/// Mixin declaration3
mixin template Mixin3()
{
/// another field
int f;
/// no docs for mixin statement (only for expanded members)
mixin Mixin2!();
}
/// class B
class B
{
/// no docs for mixin statement (only for expanded members)
mixin Mixin3!();
}
/// no docs for mixin statement (only for expanded members)
mixin Mixin3!();
| D |
//
// Written and provided by Benjamin Thaut
// Complications improved by Rainer Schuetze
//
// file access monitoring added by Rainer Schuetze, needs filemonitor.dll in the same
// directory as pipedmd.exe, or tracker.exe from the MSBuild tool chain
module pipedmd;
import std.stdio;
import core.sys.windows.windows;
import core.sys.windows.psapi;
import std.windows.charset;
import core.stdc.string;
import std.string;
import std.regex;
import core.demangle;
import std.array;
import std.algorithm;
import std.conv;
import std.path;
import std.process;
import std.utf;
static import std.file;
// version = pipeLink; // define to forward arguments to link.exe and demangle its output
version = MSLinkFormat;
enum canInjectDLL = false; // disable to rely on tracker.exe exclusively (keeps AV programs more happy)
alias core.stdc.stdio.stdout stdout;
alias core.stdc.stdio.stderr stderr;
static bool isIdentifierChar(char ch)
{
// include C++,Pascal,Windows mangling and UTF8 encoding and compression
return ch >= 0x80 || (ch >= '0' && ch <= '9') || (ch >= 'a' && ch <= 'z') || (ch >= 'A' && ch <= 'Z') || ch == '_';
}
static bool isDigit(char ch)
{
return (ch >= '0' && ch <= '9');
}
string quoteArg(string arg)
{
if(indexOf(arg, ' ') < arg.length)
return "\"" ~ replace(arg, "\"", "\\\"") ~ "\"";
else
return arg;
}
string eatArg(string cmd)
{
while (cmd.length && cmd[0] != ' ')
{
if (cmd[0] == '"')
{
cmd = cmd[1..$];
while (cmd.length && cmd[0] != '"')
cmd = cmd[1..$];
if (cmd.length)
cmd = cmd[1..$];
}
else
cmd = cmd[1..$];
}
return cmd;
}
version(pipeLink)
{
extern(C) int putenv(const char*);
int main(string[] argv)
{
string cmd = to!string(GetCommandLineW());
//printf("pipelink called with: %.*s\n", cast(int)cmd.length, cmd.ptr);
cmd = "link.exe" ~ eatArg(cmd);
putenv("VS_UNICODE_OUTPUT="); // disable unicode output for link.exe
int exitCode = runProcess(cmd, null, true, true, false, true, false);
return exitCode;
}
}
else
int main(string[] argv)
{
if(argv.length < 2)
{
printf("pipedmd V0.2, written 2012 by Benjamin Thaut, complications improved by Rainer Schuetze\n");
printf("decompresses and demangles names in OPTLINK and ld messages\n");
printf("\n");
printf("usage: %.*s [-nodemangle] [-gdcmode | -msmode] [-deps depfile] [executable] [arguments]\n",
argv[0].length, argv[0].ptr);
return -1;
}
int skipargs = 0;
string depsfile;
bool doDemangle = true;
bool demangleAll = false; //not just linker messages
bool gdcMode = false; //gcc linker
bool msMode = false; //microsoft linker
bool verbose = false;
bool memStats = false;
while (argv.length >= skipargs + 2)
{
if(argv[skipargs + 1] == "-nodemangle")
{
doDemangle = false;
skipargs++;
}
else if(argv[skipargs + 1] == "-demangleall")
{
demangleAll = true;
skipargs++;
}
else if(argv[skipargs + 1] == "-gdcmode")
{
gdcMode = true;
skipargs++;
}
else if(argv[skipargs + 1] == "-msmode")
{
msMode = true;
skipargs++;
}
else if(argv[skipargs + 1] == "-verbose")
{
verbose = true;
skipargs++;
}
else if(argv[skipargs + 1] == "-memStats")
{
memStats = true;
skipargs++;
}
else if(argv[skipargs + 1] == "-deps")
depsfile = argv[skipargs += 2];
else
break;
}
string exe = (argv.length > skipargs + 1 ? argv[skipargs + 1] : null);
string command;
string trackdir;
string trackfile;
string trackfilewr;
bool inject = false;
if (depsfile.length > 0)
{
string fullexe = findExeInPath(exe);
bool isX64 = isExe64bit(fullexe);
if (verbose)
if (fullexe.empty)
printf ("%.*s not found in PATH, assuming %d-bit application\n", exe.length, exe.ptr, isX64 ? 64 : 32);
else
printf ("%.*s is a %d-bit application\n", fullexe.length, fullexe.ptr, isX64 ? 64 : 32);
string trackerArgs;
string tracker = findTracker(isX64, trackerArgs);
if (tracker.length > 0)
{
command = quoteArg(tracker);
command ~= trackerArgs;
command ~= " /m"; // include temporary files removed, they might appear as input to sub processes
trackdir = dirName(depsfile);
if (trackdir != ".")
command ~= " /if " ~ quoteArg(trackdir);
trackfile = "*.read.*.tlog";
trackfilewr = "*.write.*.tlog";
foreach(f; std.file.dirEntries(trackdir, std.file.SpanMode.shallow))
if (globMatch(baseName(f), trackfile) || globMatch(baseName(f), trackfilewr))
std.file.remove(f.name);
command ~= " /c";
}
else if (isX64 || !canInjectDLL)
{
printf("cannot monitor %d-bit executable %.*s, no suitable tracker.exe found\n", isX64 ? 64 : 32, exe.length, exe.ptr);
return -1;
}
else
inject = true;
}
for(int i = skipargs + 1;i < argv.length; i++)
{
if(command.length > 0)
command ~= " ";
command ~= quoteArg(argv[i]);
}
if(verbose)
printf("Command: %.*s\n", command.length, command.ptr);
int exitCode = runProcess(command, inject ? depsfile : null, doDemangle, demangleAll, gdcMode, msMode, memStats);
if (exitCode == 0 && trackfile.length > 0)
{
// read read.*.tlog and remove all files found in write.*.log
string rdbuf;
string wrbuf;
foreach(f; std.file.dirEntries(trackdir, std.file.SpanMode.shallow))
{
bool rd = globMatch(baseName(f), trackfile);
bool wr = globMatch(baseName(f), trackfilewr);
if (rd || wr)
{
ubyte[] fbuf = cast(ubyte[])std.file.read(f.name);
string cbuf;
// strip BOM from all but the first file
if(fbuf.length > 1 && fbuf[0] == 0xFF && fbuf[1] == 0xFE)
cbuf = to!(string)(cast(wstring)(fbuf[2..$]));
else
cbuf = cast(string)fbuf;
if(rd)
rdbuf ~= cbuf;
else
wrbuf ~= cbuf;
}
}
string[] rdlines = splitLines(rdbuf, KeepTerminator.yes);
string[] wrlines = splitLines(wrbuf, KeepTerminator.yes);
bool[string] wrset;
foreach(w; wrlines)
if (!w.startsWith("#Command:"))
wrset[w] = true;
bool[string] rdset;
foreach(r; rdlines)
if (!r.startsWith("#Command:"))
if(r !in wrset)
rdset[r] = true;
string buf = rdset.keys.sort.join;
std.file.write(depsfile, buf);
}
return exitCode;
}
int runProcess(string command, string depsfile, bool doDemangle, bool demangleAll, bool gdcMode, bool msMode, bool memStats)
{
HANDLE hStdOutRead;
HANDLE hStdOutWrite;
HANDLE hStdInRead;
HANDLE hStdInWrite;
SECURITY_ATTRIBUTES saAttr;
// Set the bInheritHandle flag so pipe handles are inherited.
saAttr.nLength = SECURITY_ATTRIBUTES.sizeof;
saAttr.bInheritHandle = TRUE;
saAttr.lpSecurityDescriptor = null;
// Create a pipe for the child process's STDOUT.
if ( ! CreatePipe(&hStdOutRead, &hStdOutWrite, &saAttr, 0) )
assert(0);
// Ensure the read handle to the pipe for STDOUT is not inherited.
if ( ! SetHandleInformation(hStdOutRead, HANDLE_FLAG_INHERIT, 0) )
assert(0);
if ( ! CreatePipe(&hStdInRead, &hStdInWrite, &saAttr, 0) )
assert(0);
if ( ! SetHandleInformation(hStdInWrite, HANDLE_FLAG_INHERIT, 0) )
assert(0);
PROCESS_INFORMATION piProcInfo;
STARTUPINFOW siStartInfo;
BOOL bSuccess = FALSE;
// Set up members of the PROCESS_INFORMATION structure.
memset( &piProcInfo, 0, PROCESS_INFORMATION.sizeof );
// Set up members of the STARTUPINFO structure.
// This structure specifies the STDIN and STDOUT handles for redirection.
memset( &siStartInfo, 0, STARTUPINFOW.sizeof );
siStartInfo.cb = STARTUPINFOW.sizeof;
siStartInfo.hStdError = hStdOutWrite;
siStartInfo.hStdOutput = hStdOutWrite;
siStartInfo.hStdInput = hStdInRead;
siStartInfo.dwFlags |= STARTF_USESTDHANDLES;
int cp = GetKBCodePage();
auto szCommand = toUTF16z(command);
bSuccess = CreateProcessW(null,
cast(wchar*)szCommand, // command line
null, // process security attributes
null, // primary thread security attributes
TRUE, // handles are inherited
CREATE_SUSPENDED, // creation flags
null, // use parent's environment
null, // use parent's current directory
&siStartInfo, // STARTUPINFO pointer
&piProcInfo); // receives PROCESS_INFORMATION
if(!bSuccess)
{
printf("failed launching %s\n", szCommand);
return 1;
}
static if(canInjectDLL)
if(depsfile)
InjectDLL(piProcInfo.hProcess, depsfile);
ResumeThread(piProcInfo.hThread);
ubyte[] buffer = new ubyte[2048];
DWORD bytesFilled = 0;
DWORD bytesAvailable = 0;
DWORD bytesRead = 0;
DWORD exitCode = 0;
bool linkerFound = gdcMode || msMode || demangleAll;
L_loop:
while(true)
{
DWORD dwlen = cast(DWORD)buffer.length;
bSuccess = PeekNamedPipe(hStdOutRead, buffer.ptr + bytesFilled, dwlen - bytesFilled, &bytesRead, &bytesAvailable, null);
if (bSuccess && bytesRead > 0)
bSuccess = ReadFile(hStdOutRead, buffer.ptr + bytesFilled, dwlen - bytesFilled, &bytesRead, null);
if(bSuccess && bytesRead > 0)
{
DWORD lineLength = bytesFilled; // no need to search before previous end
bytesFilled += bytesRead;
for(; lineLength < buffer.length && lineLength < bytesFilled; lineLength++)
{
if (buffer[lineLength] == '\n')
{
size_t len = lineLength + 1;
demangleLine(buffer[0 .. len], doDemangle, demangleAll, msMode, gdcMode, cp, linkerFound);
memmove(buffer.ptr, buffer.ptr + len, bytesFilled - len);
bytesFilled -= len;
lineLength = 0;
}
}
// if no line end found, retry with larger buffer
if(bytesFilled >= buffer.length)
{
buffer.length = buffer.length * 2;
continue;
}
}
bSuccess = GetExitCodeProcess(piProcInfo.hProcess, &exitCode);
if(!bSuccess || exitCode != 259) //259 == STILL_ACTIVE
{
// process trailing text if not terminated by a newline
if (bytesFilled > 0)
demangleLine(buffer[0 .. bytesFilled], doDemangle, demangleAll, msMode, gdcMode, cp, linkerFound);
break;
}
Sleep(5);
}
if (memStats)
if (auto fun = getProcessMemoryInfoFunc())
{
string procName = getProcessName(piProcInfo.hProcess);
PROCESS_MEMORY_COUNTERS memCounters;
bSuccess = fun(piProcInfo.hProcess, &memCounters, memCounters.sizeof);
if (bSuccess)
printf("%s used %lld MB of private memory\n", procName.ptr,
cast(long)memCounters.PeakPagefileUsage >> 20);
}
//close the handles to the process
CloseHandle(hStdInWrite);
CloseHandle(hStdOutRead);
CloseHandle(piProcInfo.hProcess);
CloseHandle(piProcInfo.hThread);
return exitCode;
}
void demangleLine(ubyte[] output, bool doDemangle, bool demangleAll, bool msMode, bool gdcMode, int cp, ref bool linkerFound)
{
if (output.length && output[$-1] == '\n') //remove trailing \n
output = output[0 .. $-1];
while(output.length && output[$-1] == '\r') //remove trailing \r
output = output[0 .. $-1];
while(output.length && output[0] == '\r') // remove preceding \r
output = output[1 .. $];
if(msMode) //the microsoft linker outputs the error messages in the default ANSI codepage so we need to convert it to UTF-8
{
static WCHAR[] decodeBufferWide;
static ubyte[] decodeBuffer;
if(decodeBufferWide.length < output.length + 1)
{
decodeBufferWide.length = output.length + 1;
decodeBuffer.length = 2 * output.length + 1;
}
auto numDecoded = MultiByteToWideChar(CP_ACP, 0, cast(char*)output.ptr, cast(DWORD)output.length, decodeBufferWide.ptr, cast(DWORD)decodeBufferWide.length);
auto numEncoded = WideCharToMultiByte(CP_UTF8, 0, decodeBufferWide.ptr, numDecoded, cast(char*)decodeBuffer.ptr, cast(DWORD)decodeBuffer.length, null, null);
output = decodeBuffer[0..numEncoded];
}
size_t writepos = 0;
if(!linkerFound)
{
if (output.startsWith("OPTLINK (R)"))
linkerFound = true;
else if(output.countUntil("error LNK") >= 0 || output.countUntil("warning LNK") >= 0)
linkerFound = msMode = true;
}
if(doDemangle && linkerFound)
{
if(gdcMode)
{
if(demangleAll || output.countUntil("undefined reference to") >= 0 || output.countUntil("In function") >= 0)
{
processLine(output, writepos, false, cp);
}
}
else if(msMode)
{
if(demangleAll || output.countUntil("LNK") >= 0)
{
processLine(output, writepos, false, cp);
}
}
else
{
processLine(output, writepos, true, cp);
}
}
if(writepos < output.length)
fwrite(output.ptr + writepos, output.length - writepos, 1, stdout);
fputc('\n', stdout);
}
void processLine(ubyte[] output, ref size_t writepos, bool optlink, int cp)
{
for(int p = 0; p < output.length; p++)
{
if(isIdentifierChar(output[p]))
{
int q = p;
while(p < output.length && isIdentifierChar(output[p]))
p++;
auto symbolName = cast(const(char)[]) output[q..p];
const(char)[] realSymbolName = symbolName;
if(optlink)
{
size_t pos = 0;
realSymbolName = decodeDmdString(symbolName, pos);
if(pos != p - q)
{
// could not decode, might contain UTF8 elements, so try translating to the current code page
// (demangling will not work anyway)
try
{
auto szName = toMBSz(symbolName, cp);
auto plen = strlen(szName);
realSymbolName = szName[0..plen];
pos = p - q;
}
catch(Exception)
{
realSymbolName = null;
}
}
}
if(realSymbolName.length)
{
version(MSLinkFormat) {} else
if(realSymbolName != symbolName)
{
// not sure if output is UTF8 encoded, so avoid any translation
if(q > writepos)
fwrite(output.ptr + writepos, q - writepos, 1, stdout);
fwrite(realSymbolName.ptr, realSymbolName.length, 1, stdout);
writepos = p;
}
while(realSymbolName.length > 1 && realSymbolName[0] == '_')
realSymbolName = realSymbolName[1..$];
if(realSymbolName.length > 2 && realSymbolName[0] == 'D' && isDigit(realSymbolName[1]))
{
try
{
symbolName = demangle(realSymbolName);
}
catch(Exception)
{
}
if(realSymbolName != symbolName)
{
version(MSLinkFormat)
{
if(q > writepos)
fwrite(output.ptr + writepos, q - writepos, 1, stdout);
writepos = q;
fwrite("\"".ptr, 1, 1, stdout);
fwrite(symbolName.ptr, symbolName.length, 1, stdout);
fwrite("\" (".ptr, 3, 1, stdout);
if(p > writepos)
fwrite(output.ptr + writepos, p - writepos, 1, stdout);
writepos = p;
fwrite(")".ptr, 1, 1, stdout);
}
else
{
// skip a trailing quote
if(p + 1 < output.length && (output[p+1] == '\'' || output[p+1] == '\"'))
p++;
if(p > writepos)
fwrite(output.ptr + writepos, p - writepos, 1, stdout);
writepos = p;
fwrite(" (".ptr, 2, 1, stdout);
fwrite(symbolName.ptr, symbolName.length, 1, stdout);
fwrite(")".ptr, 1, 1, stdout);
}
}
}
}
}
}
}
///////////////////////////////////////////////////////////////////////////////
bool isExe64bit(string exe)
//out(res) { printf("isExe64bit: %.*s %d-bit\n", exe.length, exe.ptr, res ? 64 : 32); }
body
{
if (exe is null || !std.file.exists(exe))
return false;
try
{
File f = File(exe, "rb");
IMAGE_DOS_HEADER dosHdr;
f.rawRead((&dosHdr)[0..1]);
if (dosHdr.e_magic != IMAGE_DOS_SIGNATURE)
return false;
f.seek(dosHdr.e_lfanew);
IMAGE_NT_HEADERS ntHdr;
f.rawRead((&ntHdr)[0..1]);
return ntHdr.FileHeader.Machine == IMAGE_FILE_MACHINE_AMD64
|| ntHdr.FileHeader.Machine == IMAGE_FILE_MACHINE_IA64;
}
catch(Exception)
{
}
return false;
}
string findExeInPath(string exe)
{
if (std.path.baseName(exe) != exe)
return exe; // if the file has dir component, don't search path
string path = std.process.environment["PATH"];
string[] paths = split(path, ";");
string ext = extension(exe);
foreach(p; paths)
{
if (p.length > 0 && p[0] == '"' && p[$-1] == '"') // remove quotes
p = p[1 .. $-1];
p = std.path.buildPath(p, exe);
if(std.file.exists(p))
return p;
if (ext.empty)
{
if(std.file.exists(p ~ ".exe"))
return p ~ ".exe";
if(std.file.exists(p ~ ".com"))
return p ~ ".com";
if(std.file.exists(p ~ ".bat"))
return p ~ ".bat";
if(std.file.exists(p ~ ".cmd"))
return p ~ ".cmd";
}
}
return null;
}
enum SECURE_ACCESS = ~(WRITE_DAC | WRITE_OWNER | GENERIC_ALL | ACCESS_SYSTEM_SECURITY);
enum KEY_WOW64_32KEY = 0x200;
enum KEY_WOW64_64KEY = 0x100;
string findTracker(bool x64, ref string trackerArgs)
{
string exe = findExeInPath("tracker.exe");
if (!exe.empty && isExe64bit(exe) != x64)
exe = null;
if (exe.indexOf("14.0") >= 0)
trackerArgs = x64 ? " /d FileTracker64.dll" : " /d FileTracker32.dll";
if (exe.empty)
exe = findTrackerInVS2017();
if (exe.empty)
exe = findTrackerInMSBuild(r"SOFTWARE\Microsoft\MSBuild\ToolsVersions\14.0"w.ptr, x64, &trackerArgs);
if (exe.empty)
exe = findTrackerInMSBuild(r"SOFTWARE\Microsoft\MSBuild\ToolsVersions\12.0"w.ptr, x64, null);
if (exe.empty)
exe = findTrackerInMSBuild(r"SOFTWARE\Microsoft\MSBuild\ToolsVersions\11.0"w.ptr, x64, null);
if (exe.empty)
exe = findTrackerInMSBuild(r"SOFTWARE\Microsoft\MSBuild\ToolsVersions\10.0"w.ptr, x64, null);
if (exe.empty)
exe = findTrackerInSDK(x64);
return exe;
}
string trackerPath(string binpath, bool x64)
{
if (binpath.empty)
return null;
string exe = buildPath(binpath, "tracker.exe");
//printf("trying %.*s\n", exe.length, exe.ptr);
if (!std.file.exists(exe))
return null;
if (isExe64bit(exe) != x64)
return null;
return exe;
}
string findTrackerInMSBuild (const(wchar)* keyname, bool x64, string* trackerArgs)
{
string path = readRegistry(keyname, "MSBuildToolsPath"w.ptr, x64);
string exe = trackerPath(path, x64);
if (exe && trackerArgs)
*trackerArgs = x64 ? " /d FileTracker64.dll" : " /d FileTracker32.dll";
return exe;
}
string findTrackerInVS2017()
{
wstring key = r"SOFTWARE\Microsoft\VisualStudio\SxS\VS7";
string dir = readRegistry(key.ptr, "15.0"w.ptr, false); // always in Wow6432
if (dir.empty)
return null;
string exe = dir ~ r"MSBuild\15.0\Bin\Tracker.exe";
if (!std.file.exists(exe))
return null;
// can handle both x86 and x64
return exe;
}
string findTrackerInSDK (bool x64)
{
wstring suffix = x64 ? "-x64" : "-x86";
wstring sdk = r"SOFTWARE\Microsoft\Microsoft SDKs\Windows";
HKEY key;
LONG lRes = RegOpenKeyExW(HKEY_LOCAL_MACHINE, sdk.ptr, 0,
KEY_READ | KEY_WOW64_32KEY, &key); // always in Wow6432
if (lRes != ERROR_SUCCESS)
return null;
string exe;
DWORD idx = 0;
wchar[100] ver;
DWORD len = ver.length;
while (RegEnumKeyExW(key, idx, ver.ptr, &len, null, null, null, null) == ERROR_SUCCESS)
{
const(wchar)[] sdkver = sdk ~ r"\"w ~ ver[0..len];
const(wchar)* wsdkver = toUTF16z(sdkver);
HKEY verkey;
lRes = RegOpenKeyExW(HKEY_LOCAL_MACHINE, wsdkver, 0, KEY_READ | KEY_WOW64_32KEY, &verkey); // always in Wow6432
if (lRes == ERROR_SUCCESS)
{
DWORD veridx = 0;
wchar[100] sub;
len = sub.length;
while (RegEnumKeyExW(verkey, veridx, sub.ptr, &len, null, null, null, null) == ERROR_SUCCESS)
{
const(wchar)[] sdkversub = sdkver ~ r"\"w ~ sub[0..len];
string path = readRegistry(toUTF16z(sdkversub), "InstallationFolder"w.ptr, false);
exe = trackerPath(path, x64);
if (!exe.empty)
break;
veridx++;
}
RegCloseKey(verkey);
}
idx++;
if (!exe.empty)
break;
}
RegCloseKey(key);
return exe;
}
string readRegistry(const(wchar)* keyname, const(wchar)* valname, bool x64)
{
string path;
HKEY key;
LONG lRes = RegOpenKeyExW(HKEY_LOCAL_MACHINE, keyname, 0,
KEY_READ | (x64 ? KEY_WOW64_64KEY : KEY_WOW64_32KEY), &key);
//printf("RegOpenKeyExW = %d, key=%x\n", lRes, key);
if (lRes == ERROR_SUCCESS)
{
DWORD type;
DWORD cntBytes;
int hr = RegQueryValueExW(key, valname, null, &type, null, &cntBytes);
//printf("RegQueryValueW = %d, %d words\n", hr, cntBytes);
if (hr == ERROR_SUCCESS || hr == ERROR_MORE_DATA)
{
wchar[] wpath = new wchar[(cntBytes + 1) / 2];
hr = RegQueryValueExW(key, valname, null, &type, wpath.ptr, &cntBytes);
if (hr == ERROR_SUCCESS)
path = toUTF8(wpath[0..$-1]); // strip trailing 0
}
RegCloseKey(key);
}
return path;
}
///////////////////////////////////////////////////////////////////////////////
// inject DLL into linker process to monitor file reads
static if(canInjectDLL)
{
alias extern(Windows) DWORD function(LPVOID lpThreadParameter) LPTHREAD_START_ROUTINE;
extern(Windows) BOOL
WriteProcessMemory(HANDLE hProcess, LPVOID lpBaseAddress, LPCVOID lpBuffer, SIZE_T nSize, SIZE_T * lpNumberOfBytesWritten);
extern(Windows) HANDLE
CreateRemoteThread(HANDLE hProcess, LPSECURITY_ATTRIBUTES lpThreadAttributes, SIZE_T dwStackSize,
LPTHREAD_START_ROUTINE lpStartAddress, LPVOID lpParameter, DWORD dwCreationFlags, LPDWORD lpThreadId);
void InjectDLL(HANDLE hProcess, string depsfile)
{
HANDLE hThread, hRemoteModule;
HMODULE appmod = GetModuleHandleA(null);
wchar[] wmodname = new wchar[260];
DWORD len = GetModuleFileNameW(appmod, wmodname.ptr, wmodname.length);
if(len > wmodname.length)
{
wmodname = new wchar[len + 1];
GetModuleFileNameW(null, wmodname.ptr, len + 1);
}
string modpath = to!string(wmodname);
string dll = buildPath(std.path.dirName(modpath), "filemonitor.dll");
auto wdll = to!wstring(dll) ~ cast(wchar)0;
// detect offset of dumpFile
HMODULE fmod = LoadLibraryW(wdll.ptr);
if(!fmod)
return;
size_t addr = cast(size_t)GetProcAddress(fmod, "_D11filemonitor8dumpFileG260a");
FreeLibrary(fmod);
if(addr == 0)
return;
addr = addr - cast(size_t)fmod;
// copy path to other process
auto wdllRemote = VirtualAllocEx(hProcess, null, wdll.length * 2, MEM_COMMIT, PAGE_READWRITE);
auto procWrite = getWriteProcFunc();
procWrite(hProcess, wdllRemote, wdll.ptr, wdll.length * 2, null);
// load dll into other process, assuming LoadLibraryW is at the same address in all processes
HMODULE mod = GetModuleHandleA("Kernel32");
auto proc = GetProcAddress(mod, "LoadLibraryW");
hThread = getCreateRemoteThreadFunc()(hProcess, null, 0, cast(LPTHREAD_START_ROUTINE)proc, wdllRemote, 0, null);
WaitForSingleObject(hThread, INFINITE);
// Get handle of the loaded module
GetExitCodeThread(hThread, cast(DWORD*) &hRemoteModule);
// Clean up
CloseHandle(hThread);
VirtualFreeEx(hProcess, wdllRemote, wdll.length * 2, MEM_RELEASE);
void* pDumpFile = cast(char*)hRemoteModule + addr;
// printf("remotemod = %p, addr = %p\n", hRemoteModule, pDumpFile);
auto szDepsFile = toMBSz(depsfile);
procWrite(hProcess, pDumpFile, szDepsFile, strlen(szDepsFile) + 1, null);
}
typeof(WriteProcessMemory)* getWriteProcFunc ()
{
HMODULE mod = GetModuleHandleA("Kernel32");
auto proc = GetProcAddress(mod, "WriteProcessMemory");
return cast(typeof(WriteProcessMemory)*)proc;
}
typeof(CreateRemoteThread)* getCreateRemoteThreadFunc ()
{
HMODULE mod = GetModuleHandleA("Kernel32");
auto proc = GetProcAddress(mod, "CreateRemoteThread");
return cast(typeof(CreateRemoteThread)*)proc;
}
} // static if(canInjectDLL)
typeof(GetProcessMemoryInfo)* getProcessMemoryInfoFunc ()
{
HMODULE mod = GetModuleHandleA("psapi");
if (!mod)
mod = LoadLibraryA("psapi.dll");
auto proc = GetProcAddress(mod, "GetProcessMemoryInfo");
return cast(typeof(GetProcessMemoryInfo)*)proc;
}
string getProcessName(HANDLE process)
{
HMODULE mod = GetModuleHandleA("psapi");
if (!mod)
mod = LoadLibraryA("psapi.dll");
auto proc = GetProcAddress(mod, "GetProcessImageFileNameW");
if (!proc)
return "child process";
wchar[260] imageName;
auto fn = cast(typeof(GetProcessImageFileNameW)*)proc;
DWORD len = fn(process, imageName.ptr, imageName.length);
if (len == 0)
return "child process";
auto pos = lastIndexOf(imageName[0..len], '\\');
return to!string(imageName[pos+1..len]);
}
| D |
/*******************************************
* NSC liest Buch an Stehtisch *
*******************************************/
func void ZS_ReadBook_Xardas ()
//Buch auf Stehtisch,
{
//PrintDebugNpc (PD_TA_FRAME,"ZS_ReadBook");
// Wahrnehmungen aktiv
//Npc_PercEnable (self, PERC_ASSESSENEMY , B_AssessEnemy );
//Npc_PercEnable (self, PERC_ASSESSFIGHTER , B_AssessFighter );
Npc_PercEnable (self, PERC_ASSESSPLAYER , B_AssessSC );
//Npc_PercEnable (self, PERC_ASSESSITEM , B_AssessItem );
// * Wahrnehmungen passiv *
Npc_PercEnable (self, PERC_ASSESSDAMAGE , ZS_ReactToDamage );
Npc_PercEnable (self, PERC_ASSESSMAGIC , B_AssessMagic );
Npc_PercEnable (self, PERC_ASSESSCASTER , B_AssessCaster );
Npc_PercEnable (self, PERC_ASSESSTHREAT , B_AssessFighter );
//Npc_PercEnable (self, PERC_ASSESSWARN , B_AssessWarn );
Npc_PercEnable (self, PERC_ASSESSMURDER , ZS_AssessMurder );
Npc_PercEnable (self, PERC_ASSESSDEFEAT , ZS_AssessDefeat );
Npc_PercEnable (self, PERC_DRAWWEAPON , B_AssessFighter );
//Npc_PercEnable (self, PERC_ASSESSFIGHTSOUND , B_AssessFightSound );
Npc_PercEnable (self, PERC_ASSESSQUIETSOUND , B_AssessQuietSound );
Npc_PercEnable (self, PERC_CATCHTHIEF , ZS_CatchThief );
Npc_PercEnable (self, PERC_ASSESSTHEFT , B_AssessTheft );
Npc_PercEnable (self, PERC_ASSESSSURPRISE , ZS_AssessSurprise );
Npc_PercEnable (self, PERC_OBSERVESUSPECT , B_ObserveSuspect );
Npc_PercEnable (self, PERC_OBSERVEINTRUDER , B_ObserveIntruder );
Npc_PercEnable (self, PERC_ASSESSTALK , B_AssessTalk );
Npc_PercEnable (self, PERC_ASSESSCALL , ZS_ReactToCall );
Npc_PercEnable (self, PERC_ASSESSUSEMOB , B_AssessUseMob );
Npc_PercEnable (self, PERC_ASSESSENTERROOM , B_AssessEnterRoom );
Npc_PercEnable (self, PERC_MOVEMOB , B_MoveMob );
Npc_PercEnable (self, PERC_MOVENPC , B_MoveNpc );
Npc_SetPercTime (self, 1);
AI_SetWalkmode (self,NPC_WALK); // Walkmode für den Zustand
if (!C_BodyStateContains(self,BS_MOBINTERACT))
{
AI_GotoWP (self, self.wp);
AI_UseMob (self,"BOOK",1); // Benutze den Mob einmal bis zum angegebenen State
};
};
func void ZS_ReadBook_Xardas_Loop ()
{
//PrintDebugNpc (PD_TA_LOOP,"ZS_ReadBook_Loop");
var int randomizer;
randomizer = Hlp_Random (20);
if (Npc_GetStateTime ( self ) >= 100 + randomizer)
{
B_InterruptMob ("BOOK");
};
AI_Wait (self,1);
};
func void ZS_ReadBook_Xardas_End ()
{
//PrintDebugNpc (PD_TA_FRAME,"ZS_ReadBook_End");
AI_UseMob (self,"BOOK",-1); // Nimm den Verlassen State ein
};
| D |
instance MIL_303_TORWACHE(NPC_DEFAULT)
{
name[0] = "Стражник у двери";
guild = GIL_MIL;
id = 303;
voice = 7;
flags = 0;
npctype = NPCTYPE_MAIN;
b_setattributestochapter(self,3);
fight_tactic = FAI_HUMAN_STRONG;
EquipItem(self,itmw_1h_mil_sword);
b_createambientinv(self);
b_setnpcvisual(self,MALE,"Hum_Head_Bald",FACE_N_NORMAL_SLY,BODYTEX_N,itar_mil_l);
Mdl_SetModelFatness(self,1);
Mdl_ApplyOverlayMds(self,"Humans_Militia.mds");
b_givenpctalents(self);
b_setfightskills(self,50);
daily_routine = rtn_start_303;
};
func void rtn_start_303()
{
ta_guard_passage(8,0,23,0,"NW_CITY_GUARDOFFICE_GUARD_02");
ta_guard_passage(23,0,8,0,"NW_CITY_GUARDOFFICE_GUARD_02");
};
| D |
/Users/babaiholdings/Documents/AlchemintWalletiOS/AlchemintProject/Build/Intermediates.noindex/Pods.build/Debug-iphonesimulator/RxSwift.build/Objects-normal/x86_64/CompositeDisposable.o : /Users/babaiholdings/Documents/AlchemintWalletiOS/AlchemintProject/Pods/RxSwift/RxSwift/Observables/Amb.swift /Users/babaiholdings/Documents/AlchemintWalletiOS/AlchemintProject/Pods/RxSwift/RxSwift/Observables/SingleAsync.swift /Users/babaiholdings/Documents/AlchemintWalletiOS/AlchemintProject/Pods/RxSwift/RxSwift/Observables/DistinctUntilChanged.swift /Users/babaiholdings/Documents/AlchemintWalletiOS/AlchemintProject/Pods/RxSwift/RxSwift/Observables/Deferred.swift /Users/babaiholdings/Documents/AlchemintWalletiOS/AlchemintProject/Pods/RxSwift/RxSwift/Deprecated.swift /Users/babaiholdings/Documents/AlchemintWalletiOS/AlchemintProject/Pods/RxSwift/RxSwift/Observables/Enumerated.swift /Users/babaiholdings/Documents/AlchemintWalletiOS/AlchemintProject/Pods/RxSwift/RxSwift/Traits/Maybe.swift /Users/babaiholdings/Documents/AlchemintWalletiOS/AlchemintProject/Pods/RxSwift/RxSwift/Observables/AsMaybe.swift /Users/babaiholdings/Documents/AlchemintWalletiOS/AlchemintProject/Pods/RxSwift/RxSwift/Observables/Sequence.swift /Users/babaiholdings/Documents/AlchemintWalletiOS/AlchemintProject/Pods/RxSwift/Platform/DataStructures/InfiniteSequence.swift /Users/babaiholdings/Documents/AlchemintWalletiOS/AlchemintProject/Pods/RxSwift/RxSwift/Traits/ObservableType+PrimitiveSequence.swift /Users/babaiholdings/Documents/AlchemintWalletiOS/AlchemintProject/Pods/RxSwift/RxSwift/Traits/PrimitiveSequence.swift /Users/babaiholdings/Documents/AlchemintWalletiOS/AlchemintProject/Pods/RxSwift/RxSwift/Observables/Debounce.swift /Users/babaiholdings/Documents/AlchemintWalletiOS/AlchemintProject/Pods/RxSwift/RxSwift/Observables/Reduce.swift /Users/babaiholdings/Documents/AlchemintWalletiOS/AlchemintProject/Pods/RxSwift/RxSwift/Observables/Range.swift /Users/babaiholdings/Documents/AlchemintWalletiOS/AlchemintProject/Pods/RxSwift/RxSwift/Observables/Merge.swift /Users/babaiholdings/Documents/AlchemintWalletiOS/AlchemintProject/Pods/RxSwift/RxSwift/Observables/Take.swift /Users/babaiholdings/Documents/AlchemintWalletiOS/AlchemintProject/Pods/RxSwift/RxSwift/Cancelable.swift /Users/babaiholdings/Documents/AlchemintWalletiOS/AlchemintProject/Pods/RxSwift/RxSwift/Disposable.swift /Users/babaiholdings/Documents/AlchemintWalletiOS/AlchemintProject/Pods/RxSwift/RxSwift/Disposables/ScheduledDisposable.swift /Users/babaiholdings/Documents/AlchemintWalletiOS/AlchemintProject/Pods/RxSwift/RxSwift/Disposables/CompositeDisposable.swift /Users/babaiholdings/Documents/AlchemintWalletiOS/AlchemintProject/Pods/RxSwift/RxSwift/Disposables/SerialDisposable.swift /Users/babaiholdings/Documents/AlchemintWalletiOS/AlchemintProject/Pods/RxSwift/RxSwift/Disposables/BooleanDisposable.swift /Users/babaiholdings/Documents/AlchemintWalletiOS/AlchemintProject/Pods/RxSwift/RxSwift/Disposables/SubscriptionDisposable.swift /Users/babaiholdings/Documents/AlchemintWalletiOS/AlchemintProject/Pods/RxSwift/RxSwift/Disposables/NopDisposable.swift /Users/babaiholdings/Documents/AlchemintWalletiOS/AlchemintProject/Pods/RxSwift/RxSwift/Disposables/AnonymousDisposable.swift /Users/babaiholdings/Documents/AlchemintWalletiOS/AlchemintProject/Pods/RxSwift/RxSwift/Disposables/SingleAssignmentDisposable.swift /Users/babaiholdings/Documents/AlchemintWalletiOS/AlchemintProject/Pods/RxSwift/RxSwift/Disposables/RefCountDisposable.swift /Users/babaiholdings/Documents/AlchemintWalletiOS/AlchemintProject/Pods/RxSwift/RxSwift/Disposables/BinaryDisposable.swift /Users/babaiholdings/Documents/AlchemintWalletiOS/AlchemintProject/Pods/RxSwift/RxSwift/Traits/Completable.swift /Users/babaiholdings/Documents/AlchemintWalletiOS/AlchemintProject/Pods/RxSwift/RxSwift/Observable.swift /Users/babaiholdings/Documents/AlchemintWalletiOS/AlchemintProject/Pods/RxSwift/RxSwift/GroupedObservable.swift /Users/babaiholdings/Documents/AlchemintWalletiOS/AlchemintProject/Pods/RxSwift/RxSwift/Traits/Single.swift /Users/babaiholdings/Documents/AlchemintWalletiOS/AlchemintProject/Pods/RxSwift/RxSwift/Observables/AsSingle.swift /Users/babaiholdings/Documents/AlchemintWalletiOS/AlchemintProject/Pods/RxSwift/RxSwift/Observables/TakeWhile.swift /Users/babaiholdings/Documents/AlchemintWalletiOS/AlchemintProject/Pods/RxSwift/RxSwift/Observables/SkipWhile.swift /Users/babaiholdings/Documents/AlchemintWalletiOS/AlchemintProject/Pods/RxSwift/RxSwift/Observables/Sample.swift /Users/babaiholdings/Documents/AlchemintWalletiOS/AlchemintProject/Pods/RxSwift/RxSwift/Observables/Throttle.swift /Users/babaiholdings/Documents/AlchemintWalletiOS/AlchemintProject/Pods/RxSwift/RxSwift/Observables/ShareReplayScope.swift /Users/babaiholdings/Documents/AlchemintWalletiOS/AlchemintProject/Pods/RxSwift/RxSwift/Concurrency/SynchronizedUnsubscribeType.swift /Users/babaiholdings/Documents/AlchemintWalletiOS/AlchemintProject/Pods/RxSwift/RxSwift/Schedulers/Internal/InvocableType.swift /Users/babaiholdings/Documents/AlchemintWalletiOS/AlchemintProject/Pods/RxSwift/RxSwift/ObservableType.swift /Users/babaiholdings/Documents/AlchemintWalletiOS/AlchemintProject/Pods/RxSwift/RxSwift/ConnectableObservableType.swift /Users/babaiholdings/Documents/AlchemintWalletiOS/AlchemintProject/Pods/RxSwift/RxSwift/ObservableConvertibleType.swift /Users/babaiholdings/Documents/AlchemintWalletiOS/AlchemintProject/Pods/RxSwift/RxSwift/Concurrency/SynchronizedDisposeType.swift /Users/babaiholdings/Documents/AlchemintWalletiOS/AlchemintProject/Pods/RxSwift/RxSwift/Schedulers/Internal/ScheduledItemType.swift /Users/babaiholdings/Documents/AlchemintWalletiOS/AlchemintProject/Pods/RxSwift/RxSwift/Concurrency/SynchronizedOnType.swift /Users/babaiholdings/Documents/AlchemintWalletiOS/AlchemintProject/Pods/RxSwift/RxSwift/SchedulerType.swift /Users/babaiholdings/Documents/AlchemintWalletiOS/AlchemintProject/Pods/RxSwift/RxSwift/ImmediateSchedulerType.swift /Users/babaiholdings/Documents/AlchemintWalletiOS/AlchemintProject/Pods/RxSwift/RxSwift/Concurrency/LockOwnerType.swift /Users/babaiholdings/Documents/AlchemintWalletiOS/AlchemintProject/Pods/RxSwift/RxSwift/Schedulers/VirtualTimeConverterType.swift /Users/babaiholdings/Documents/AlchemintWalletiOS/AlchemintProject/Pods/RxSwift/RxSwift/ObserverType.swift /Users/babaiholdings/Documents/AlchemintWalletiOS/AlchemintProject/Pods/RxSwift/RxSwift/Subjects/SubjectType.swift /Users/babaiholdings/Documents/AlchemintWalletiOS/AlchemintProject/Pods/RxSwift/RxSwift/Disposables/DisposeBase.swift /Users/babaiholdings/Documents/AlchemintWalletiOS/AlchemintProject/Pods/RxSwift/RxSwift/Observers/ObserverBase.swift /Users/babaiholdings/Documents/AlchemintWalletiOS/AlchemintProject/Pods/RxSwift/RxSwift/Observables/Create.swift /Users/babaiholdings/Documents/AlchemintWalletiOS/AlchemintProject/Pods/RxSwift/RxSwift/Observables/Generate.swift /Users/babaiholdings/Documents/AlchemintWalletiOS/AlchemintProject/Pods/RxSwift/Platform/DataStructures/Queue.swift /Users/babaiholdings/Documents/AlchemintWalletiOS/AlchemintProject/Pods/RxSwift/Platform/DataStructures/PriorityQueue.swift /Users/babaiholdings/Documents/AlchemintWalletiOS/AlchemintProject/Pods/RxSwift/RxSwift/Reactive.swift /Users/babaiholdings/Documents/AlchemintWalletiOS/AlchemintProject/Pods/RxSwift/RxSwift/Observables/Materialize.swift /Users/babaiholdings/Documents/AlchemintWalletiOS/AlchemintProject/Pods/RxSwift/RxSwift/Observables/Dematerialize.swift /Users/babaiholdings/Documents/AlchemintWalletiOS/AlchemintProject/Pods/RxSwift/RxSwift/Observables/AddRef.swift /Users/babaiholdings/Documents/AlchemintWalletiOS/AlchemintProject/Pods/RxSwift/Platform/DataStructures/Bag.swift /Users/babaiholdings/Documents/AlchemintWalletiOS/AlchemintProject/Pods/RxSwift/RxSwift/Disposables/DisposeBag.swift /Users/babaiholdings/Documents/AlchemintWalletiOS/AlchemintProject/Pods/RxSwift/RxSwift/Observables/Using.swift /Users/babaiholdings/Documents/AlchemintWalletiOS/AlchemintProject/Pods/RxSwift/RxSwift/Observables/Debug.swift /Users/babaiholdings/Documents/AlchemintWalletiOS/AlchemintProject/Pods/RxSwift/RxSwift/Observables/Catch.swift /Users/babaiholdings/Documents/AlchemintWalletiOS/AlchemintProject/Pods/RxSwift/RxSwift/Observables/Switch.swift /Users/babaiholdings/Documents/AlchemintWalletiOS/AlchemintProject/Pods/RxSwift/RxSwift/Observables/StartWith.swift /Users/babaiholdings/Documents/AlchemintWalletiOS/AlchemintProject/Pods/RxSwift/RxSwift/Concurrency/Lock.swift /Users/babaiholdings/Documents/AlchemintWalletiOS/AlchemintProject/Pods/RxSwift/RxSwift/Concurrency/AsyncLock.swift /Users/babaiholdings/Documents/AlchemintWalletiOS/AlchemintProject/Pods/RxSwift/Platform/RecursiveLock.swift /Users/babaiholdings/Documents/AlchemintWalletiOS/AlchemintProject/Pods/RxSwift/RxSwift/Observables/Sink.swift /Users/babaiholdings/Documents/AlchemintWalletiOS/AlchemintProject/Pods/RxSwift/RxSwift/Observers/TailRecursiveSink.swift /Users/babaiholdings/Documents/AlchemintWalletiOS/AlchemintProject/Pods/RxSwift/RxSwift/Observables/Optional.swift /Users/babaiholdings/Documents/AlchemintWalletiOS/AlchemintProject/Pods/RxSwift/RxSwift/Observables/TakeUntil.swift /Users/babaiholdings/Documents/AlchemintWalletiOS/AlchemintProject/Pods/RxSwift/RxSwift/Observables/SkipUntil.swift /Users/babaiholdings/Documents/AlchemintWalletiOS/AlchemintProject/Pods/RxSwift/RxSwift/Schedulers/Internal/ScheduledItem.swift /Users/babaiholdings/Documents/AlchemintWalletiOS/AlchemintProject/Pods/RxSwift/RxSwift/Schedulers/Internal/InvocableScheduledItem.swift /Users/babaiholdings/Documents/AlchemintWalletiOS/AlchemintProject/Pods/RxSwift/RxSwift/Observables/WithLatestFrom.swift /Users/babaiholdings/Documents/AlchemintWalletiOS/AlchemintProject/Pods/RxSwift/RxSwift/Observables/SubscribeOn.swift /Users/babaiholdings/Documents/AlchemintWalletiOS/AlchemintProject/Pods/RxSwift/RxSwift/Observables/ObserveOn.swift /Users/babaiholdings/Documents/AlchemintWalletiOS/AlchemintProject/Pods/RxSwift/RxSwift/Observables/Scan.swift /Users/babaiholdings/Documents/AlchemintWalletiOS/AlchemintProject/Pods/RxSwift/RxSwift/Traits/Completable+AndThen.swift /Users/babaiholdings/Documents/AlchemintWalletiOS/AlchemintProject/Pods/RxSwift/RxSwift/Observables/RetryWhen.swift /Users/babaiholdings/Documents/AlchemintWalletiOS/AlchemintProject/Pods/RxSwift/Platform/Platform.Darwin.swift /Users/babaiholdings/Documents/AlchemintWalletiOS/AlchemintProject/Pods/RxSwift/RxSwift/Schedulers/SchedulerServices+Emulation.swift /Users/babaiholdings/Documents/AlchemintWalletiOS/AlchemintProject/Pods/RxSwift/RxSwift/Schedulers/Internal/DispatchQueueConfiguration.swift /Users/babaiholdings/Documents/AlchemintWalletiOS/AlchemintProject/Pods/RxSwift/RxSwift/Observables/Zip+Collection.swift /Users/babaiholdings/Documents/AlchemintWalletiOS/AlchemintProject/Pods/RxSwift/RxSwift/Observables/CombineLatest+Collection.swift /Users/babaiholdings/Documents/AlchemintWalletiOS/AlchemintProject/Pods/RxSwift/RxSwift/Observables/DelaySubscription.swift /Users/babaiholdings/Documents/AlchemintWalletiOS/AlchemintProject/Pods/RxSwift/RxSwift/Observables/Do.swift /Users/babaiholdings/Documents/AlchemintWalletiOS/AlchemintProject/Pods/RxSwift/RxSwift/Observables/Map.swift /Users/babaiholdings/Documents/AlchemintWalletiOS/AlchemintProject/Pods/RxSwift/RxSwift/Observables/Zip.swift /Users/babaiholdings/Documents/AlchemintWalletiOS/AlchemintProject/Pods/RxSwift/RxSwift/Observables/Skip.swift /Users/babaiholdings/Documents/AlchemintWalletiOS/AlchemintProject/Pods/RxSwift/RxSwift/Observables/Producer.swift /Users/babaiholdings/Documents/AlchemintWalletiOS/AlchemintProject/Pods/RxSwift/RxSwift/Observables/Buffer.swift /Users/babaiholdings/Documents/AlchemintWalletiOS/AlchemintProject/Pods/RxSwift/RxSwift/Schedulers/CurrentThreadScheduler.swift /Users/babaiholdings/Documents/AlchemintWalletiOS/AlchemintProject/Pods/RxSwift/RxSwift/Schedulers/VirtualTimeScheduler.swift /Users/babaiholdings/Documents/AlchemintWalletiOS/AlchemintProject/Pods/RxSwift/RxSwift/Schedulers/SerialDispatchQueueScheduler.swift /Users/babaiholdings/Documents/AlchemintWalletiOS/AlchemintProject/Pods/RxSwift/RxSwift/Schedulers/ConcurrentDispatchQueueScheduler.swift /Users/babaiholdings/Documents/AlchemintWalletiOS/AlchemintProject/Pods/RxSwift/RxSwift/Schedulers/OperationQueueScheduler.swift /Users/babaiholdings/Documents/AlchemintWalletiOS/AlchemintProject/Pods/RxSwift/RxSwift/Schedulers/RecursiveScheduler.swift /Users/babaiholdings/Documents/AlchemintWalletiOS/AlchemintProject/Pods/RxSwift/RxSwift/Schedulers/HistoricalScheduler.swift /Users/babaiholdings/Documents/AlchemintWalletiOS/AlchemintProject/Pods/RxSwift/RxSwift/Schedulers/MainScheduler.swift /Users/babaiholdings/Documents/AlchemintWalletiOS/AlchemintProject/Pods/RxSwift/RxSwift/Schedulers/ConcurrentMainScheduler.swift /Users/babaiholdings/Documents/AlchemintWalletiOS/AlchemintProject/Pods/RxSwift/RxSwift/Observables/Timer.swift /Users/babaiholdings/Documents/AlchemintWalletiOS/AlchemintProject/Pods/RxSwift/Platform/DeprecationWarner.swift /Users/babaiholdings/Documents/AlchemintWalletiOS/AlchemintProject/Pods/RxSwift/RxSwift/Observables/Filter.swift /Users/babaiholdings/Documents/AlchemintWalletiOS/AlchemintProject/Pods/RxSwift/RxSwift/Schedulers/HistoricalSchedulerTimeConverter.swift /Users/babaiholdings/Documents/AlchemintWalletiOS/AlchemintProject/Pods/RxSwift/RxSwift/Observables/Never.swift /Users/babaiholdings/Documents/AlchemintWalletiOS/AlchemintProject/Pods/RxSwift/RxSwift/Observers/AnonymousObserver.swift /Users/babaiholdings/Documents/AlchemintWalletiOS/AlchemintProject/Pods/RxSwift/RxSwift/AnyObserver.swift /Users/babaiholdings/Documents/AlchemintWalletiOS/AlchemintProject/Pods/RxSwift/RxSwift/Observables/Error.swift /Users/babaiholdings/Documents/AlchemintWalletiOS/AlchemintProject/Pods/RxSwift/RxSwift/Disposables/Disposables.swift /Users/babaiholdings/Documents/AlchemintWalletiOS/AlchemintProject/Pods/RxSwift/RxSwift/ObservableType+Extensions.swift /Users/babaiholdings/Documents/AlchemintWalletiOS/AlchemintProject/Pods/RxSwift/Platform/DispatchQueue+Extensions.swift /Users/babaiholdings/Documents/AlchemintWalletiOS/AlchemintProject/Pods/RxSwift/RxSwift/Errors.swift /Users/babaiholdings/Documents/AlchemintWalletiOS/AlchemintProject/Pods/RxSwift/RxSwift/Observables/ElementAt.swift /Users/babaiholdings/Documents/AlchemintWalletiOS/AlchemintProject/Pods/RxSwift/RxSwift/Observables/Concat.swift /Users/babaiholdings/Documents/AlchemintWalletiOS/AlchemintProject/Pods/RxSwift/RxSwift/Observables/Repeat.swift /Users/babaiholdings/Documents/AlchemintWalletiOS/AlchemintProject/Pods/RxSwift/RxSwift/Subjects/AsyncSubject.swift /Users/babaiholdings/Documents/AlchemintWalletiOS/AlchemintProject/Pods/RxSwift/RxSwift/Subjects/PublishSubject.swift /Users/babaiholdings/Documents/AlchemintWalletiOS/AlchemintProject/Pods/RxSwift/RxSwift/Subjects/BehaviorSubject.swift /Users/babaiholdings/Documents/AlchemintWalletiOS/AlchemintProject/Pods/RxSwift/RxSwift/Subjects/ReplaySubject.swift /Users/babaiholdings/Documents/AlchemintWalletiOS/AlchemintProject/Pods/RxSwift/RxSwift/Event.swift /Users/babaiholdings/Documents/AlchemintWalletiOS/AlchemintProject/Pods/RxSwift/RxSwift/SwiftSupport/SwiftSupport.swift /Users/babaiholdings/Documents/AlchemintWalletiOS/AlchemintProject/Pods/RxSwift/RxSwift/Observables/TakeLast.swift /Users/babaiholdings/Documents/AlchemintWalletiOS/AlchemintProject/Pods/RxSwift/RxSwift/Observables/Multicast.swift /Users/babaiholdings/Documents/AlchemintWalletiOS/AlchemintProject/Pods/RxSwift/RxSwift/Observables/CombineLatest.swift /Users/babaiholdings/Documents/AlchemintWalletiOS/AlchemintProject/Pods/RxSwift/RxSwift/Observables/First.swift /Users/babaiholdings/Documents/AlchemintWalletiOS/AlchemintProject/Pods/RxSwift/RxSwift/Observables/Just.swift /Users/babaiholdings/Documents/AlchemintWalletiOS/AlchemintProject/Pods/RxSwift/RxSwift/Observables/Timeout.swift /Users/babaiholdings/Documents/AlchemintWalletiOS/AlchemintProject/Pods/RxSwift/RxSwift/Observables/Window.swift /Users/babaiholdings/Documents/AlchemintWalletiOS/AlchemintProject/Pods/RxSwift/RxSwift/Extensions/Bag+Rx.swift /Users/babaiholdings/Documents/AlchemintWalletiOS/AlchemintProject/Pods/RxSwift/RxSwift/Extensions/String+Rx.swift /Users/babaiholdings/Documents/AlchemintWalletiOS/AlchemintProject/Pods/RxSwift/RxSwift/Rx.swift /Users/babaiholdings/Documents/AlchemintWalletiOS/AlchemintProject/Pods/RxSwift/RxSwift/RxMutableBox.swift /Users/babaiholdings/Documents/AlchemintWalletiOS/AlchemintProject/Pods/RxSwift/Platform/Platform.Linux.swift /Users/babaiholdings/Documents/AlchemintWalletiOS/AlchemintProject/Pods/RxSwift/RxSwift/Observables/GroupBy.swift /Users/babaiholdings/Documents/AlchemintWalletiOS/AlchemintProject/Pods/RxSwift/RxSwift/Observables/Delay.swift /Users/babaiholdings/Documents/AlchemintWalletiOS/AlchemintProject/Pods/RxSwift/RxSwift/Observables/ToArray.swift /Users/babaiholdings/Documents/AlchemintWalletiOS/AlchemintProject/Pods/RxSwift/RxSwift/Traits/PrimitiveSequence+Zip+arity.swift /Users/babaiholdings/Documents/AlchemintWalletiOS/AlchemintProject/Pods/RxSwift/RxSwift/Observables/Zip+arity.swift /Users/babaiholdings/Documents/AlchemintWalletiOS/AlchemintProject/Pods/RxSwift/RxSwift/Observables/CombineLatest+arity.swift /Users/babaiholdings/Documents/AlchemintWalletiOS/AlchemintProject/Pods/RxSwift/RxSwift/Observables/Empty.swift /Users/babaiholdings/Documents/AlchemintWalletiOS/AlchemintProject/Pods/RxSwift/RxSwift/Observables/SwitchIfEmpty.swift /Users/babaiholdings/Documents/AlchemintWalletiOS/AlchemintProject/Pods/RxSwift/RxSwift/Observables/DefaultIfEmpty.swift /Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/lib/swift/iphonesimulator/x86_64/Dispatch.apinotesc /Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/lib/swift/iphonesimulator/x86_64/ObjectiveC.swiftmodule /Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/lib/swift/iphonesimulator/x86_64/CoreImage.swiftmodule /Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/lib/swift/iphonesimulator/x86_64/QuartzCore.swiftmodule /Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/lib/swift/iphonesimulator/x86_64/Dispatch.swiftmodule /Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/lib/swift/iphonesimulator/x86_64/Metal.swiftmodule /Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/lib/swift/iphonesimulator/x86_64/Darwin.swiftmodule /Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/lib/swift/iphonesimulator/x86_64/Foundation.swiftmodule /Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/lib/swift/iphonesimulator/x86_64/CoreFoundation.swiftmodule /Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/lib/swift/iphonesimulator/x86_64/CoreGraphics.swiftmodule /Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/lib/swift/iphonesimulator/x86_64/Swift.swiftmodule /Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/lib/swift/iphonesimulator/x86_64/UIKit.swiftmodule /Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/lib/swift/iphonesimulator/x86_64/SwiftOnoneSupport.swiftmodule /Users/babaiholdings/Documents/AlchemintWalletiOS/AlchemintProject/Pods/Target\ Support\ Files/RxSwift/RxSwift-umbrella.h /Users/babaiholdings/Documents/AlchemintWalletiOS/AlchemintProject/Build/Intermediates.noindex/Pods.build/Debug-iphonesimulator/RxSwift.build/unextended-module.modulemap /Applications/Xcode.app/Contents/Developer/Platforms/iPhoneSimulator.platform/Developer/SDKs/iPhoneSimulator11.4.sdk/usr/include/objc/ObjectiveC.apinotes /Applications/Xcode.app/Contents/Developer/Platforms/iPhoneSimulator.platform/Developer/SDKs/iPhoneSimulator11.4.sdk/System/Library/Frameworks/OpenGLES.framework/Headers/OpenGLES.apinotes /Applications/Xcode.app/Contents/Developer/Platforms/iPhoneSimulator.platform/Developer/SDKs/iPhoneSimulator11.4.sdk/System/Library/Frameworks/CoreImage.framework/Headers/CoreImage.apinotes /Applications/Xcode.app/Contents/Developer/Platforms/iPhoneSimulator.platform/Developer/SDKs/iPhoneSimulator11.4.sdk/System/Library/Frameworks/QuartzCore.framework/Headers/QuartzCore.apinotes /Applications/Xcode.app/Contents/Developer/Platforms/iPhoneSimulator.platform/Developer/SDKs/iPhoneSimulator11.4.sdk/System/Library/Frameworks/Metal.framework/Headers/Metal.apinotes /Applications/Xcode.app/Contents/Developer/Platforms/iPhoneSimulator.platform/Developer/SDKs/iPhoneSimulator11.4.sdk/usr/include/Darwin.apinotes /Applications/Xcode.app/Contents/Developer/Platforms/iPhoneSimulator.platform/Developer/SDKs/iPhoneSimulator11.4.sdk/System/Library/Frameworks/Foundation.framework/Headers/Foundation.apinotes /Applications/Xcode.app/Contents/Developer/Platforms/iPhoneSimulator.platform/Developer/SDKs/iPhoneSimulator11.4.sdk/System/Library/Frameworks/CoreGraphics.framework/Headers/CoreGraphics.apinotes /Applications/Xcode.app/Contents/Developer/Platforms/iPhoneSimulator.platform/Developer/SDKs/iPhoneSimulator11.4.sdk/System/Library/Frameworks/UIKit.framework/Headers/UIKit.apinotes /Applications/Xcode.app/Contents/Developer/Platforms/iPhoneSimulator.platform/Developer/SDKs/iPhoneSimulator11.4.sdk/System/Library/Frameworks/CoreText.framework/Headers/CoreText.apinotes
/Users/babaiholdings/Documents/AlchemintWalletiOS/AlchemintProject/Build/Intermediates.noindex/Pods.build/Debug-iphonesimulator/RxSwift.build/Objects-normal/x86_64/CompositeDisposable~partial.swiftmodule : /Users/babaiholdings/Documents/AlchemintWalletiOS/AlchemintProject/Pods/RxSwift/RxSwift/Observables/Amb.swift /Users/babaiholdings/Documents/AlchemintWalletiOS/AlchemintProject/Pods/RxSwift/RxSwift/Observables/SingleAsync.swift /Users/babaiholdings/Documents/AlchemintWalletiOS/AlchemintProject/Pods/RxSwift/RxSwift/Observables/DistinctUntilChanged.swift /Users/babaiholdings/Documents/AlchemintWalletiOS/AlchemintProject/Pods/RxSwift/RxSwift/Observables/Deferred.swift /Users/babaiholdings/Documents/AlchemintWalletiOS/AlchemintProject/Pods/RxSwift/RxSwift/Deprecated.swift /Users/babaiholdings/Documents/AlchemintWalletiOS/AlchemintProject/Pods/RxSwift/RxSwift/Observables/Enumerated.swift /Users/babaiholdings/Documents/AlchemintWalletiOS/AlchemintProject/Pods/RxSwift/RxSwift/Traits/Maybe.swift /Users/babaiholdings/Documents/AlchemintWalletiOS/AlchemintProject/Pods/RxSwift/RxSwift/Observables/AsMaybe.swift /Users/babaiholdings/Documents/AlchemintWalletiOS/AlchemintProject/Pods/RxSwift/RxSwift/Observables/Sequence.swift /Users/babaiholdings/Documents/AlchemintWalletiOS/AlchemintProject/Pods/RxSwift/Platform/DataStructures/InfiniteSequence.swift /Users/babaiholdings/Documents/AlchemintWalletiOS/AlchemintProject/Pods/RxSwift/RxSwift/Traits/ObservableType+PrimitiveSequence.swift /Users/babaiholdings/Documents/AlchemintWalletiOS/AlchemintProject/Pods/RxSwift/RxSwift/Traits/PrimitiveSequence.swift /Users/babaiholdings/Documents/AlchemintWalletiOS/AlchemintProject/Pods/RxSwift/RxSwift/Observables/Debounce.swift /Users/babaiholdings/Documents/AlchemintWalletiOS/AlchemintProject/Pods/RxSwift/RxSwift/Observables/Reduce.swift /Users/babaiholdings/Documents/AlchemintWalletiOS/AlchemintProject/Pods/RxSwift/RxSwift/Observables/Range.swift /Users/babaiholdings/Documents/AlchemintWalletiOS/AlchemintProject/Pods/RxSwift/RxSwift/Observables/Merge.swift /Users/babaiholdings/Documents/AlchemintWalletiOS/AlchemintProject/Pods/RxSwift/RxSwift/Observables/Take.swift /Users/babaiholdings/Documents/AlchemintWalletiOS/AlchemintProject/Pods/RxSwift/RxSwift/Cancelable.swift /Users/babaiholdings/Documents/AlchemintWalletiOS/AlchemintProject/Pods/RxSwift/RxSwift/Disposable.swift /Users/babaiholdings/Documents/AlchemintWalletiOS/AlchemintProject/Pods/RxSwift/RxSwift/Disposables/ScheduledDisposable.swift /Users/babaiholdings/Documents/AlchemintWalletiOS/AlchemintProject/Pods/RxSwift/RxSwift/Disposables/CompositeDisposable.swift /Users/babaiholdings/Documents/AlchemintWalletiOS/AlchemintProject/Pods/RxSwift/RxSwift/Disposables/SerialDisposable.swift /Users/babaiholdings/Documents/AlchemintWalletiOS/AlchemintProject/Pods/RxSwift/RxSwift/Disposables/BooleanDisposable.swift /Users/babaiholdings/Documents/AlchemintWalletiOS/AlchemintProject/Pods/RxSwift/RxSwift/Disposables/SubscriptionDisposable.swift /Users/babaiholdings/Documents/AlchemintWalletiOS/AlchemintProject/Pods/RxSwift/RxSwift/Disposables/NopDisposable.swift /Users/babaiholdings/Documents/AlchemintWalletiOS/AlchemintProject/Pods/RxSwift/RxSwift/Disposables/AnonymousDisposable.swift /Users/babaiholdings/Documents/AlchemintWalletiOS/AlchemintProject/Pods/RxSwift/RxSwift/Disposables/SingleAssignmentDisposable.swift /Users/babaiholdings/Documents/AlchemintWalletiOS/AlchemintProject/Pods/RxSwift/RxSwift/Disposables/RefCountDisposable.swift /Users/babaiholdings/Documents/AlchemintWalletiOS/AlchemintProject/Pods/RxSwift/RxSwift/Disposables/BinaryDisposable.swift /Users/babaiholdings/Documents/AlchemintWalletiOS/AlchemintProject/Pods/RxSwift/RxSwift/Traits/Completable.swift /Users/babaiholdings/Documents/AlchemintWalletiOS/AlchemintProject/Pods/RxSwift/RxSwift/Observable.swift /Users/babaiholdings/Documents/AlchemintWalletiOS/AlchemintProject/Pods/RxSwift/RxSwift/GroupedObservable.swift /Users/babaiholdings/Documents/AlchemintWalletiOS/AlchemintProject/Pods/RxSwift/RxSwift/Traits/Single.swift /Users/babaiholdings/Documents/AlchemintWalletiOS/AlchemintProject/Pods/RxSwift/RxSwift/Observables/AsSingle.swift /Users/babaiholdings/Documents/AlchemintWalletiOS/AlchemintProject/Pods/RxSwift/RxSwift/Observables/TakeWhile.swift /Users/babaiholdings/Documents/AlchemintWalletiOS/AlchemintProject/Pods/RxSwift/RxSwift/Observables/SkipWhile.swift /Users/babaiholdings/Documents/AlchemintWalletiOS/AlchemintProject/Pods/RxSwift/RxSwift/Observables/Sample.swift /Users/babaiholdings/Documents/AlchemintWalletiOS/AlchemintProject/Pods/RxSwift/RxSwift/Observables/Throttle.swift /Users/babaiholdings/Documents/AlchemintWalletiOS/AlchemintProject/Pods/RxSwift/RxSwift/Observables/ShareReplayScope.swift /Users/babaiholdings/Documents/AlchemintWalletiOS/AlchemintProject/Pods/RxSwift/RxSwift/Concurrency/SynchronizedUnsubscribeType.swift /Users/babaiholdings/Documents/AlchemintWalletiOS/AlchemintProject/Pods/RxSwift/RxSwift/Schedulers/Internal/InvocableType.swift /Users/babaiholdings/Documents/AlchemintWalletiOS/AlchemintProject/Pods/RxSwift/RxSwift/ObservableType.swift /Users/babaiholdings/Documents/AlchemintWalletiOS/AlchemintProject/Pods/RxSwift/RxSwift/ConnectableObservableType.swift /Users/babaiholdings/Documents/AlchemintWalletiOS/AlchemintProject/Pods/RxSwift/RxSwift/ObservableConvertibleType.swift /Users/babaiholdings/Documents/AlchemintWalletiOS/AlchemintProject/Pods/RxSwift/RxSwift/Concurrency/SynchronizedDisposeType.swift /Users/babaiholdings/Documents/AlchemintWalletiOS/AlchemintProject/Pods/RxSwift/RxSwift/Schedulers/Internal/ScheduledItemType.swift /Users/babaiholdings/Documents/AlchemintWalletiOS/AlchemintProject/Pods/RxSwift/RxSwift/Concurrency/SynchronizedOnType.swift /Users/babaiholdings/Documents/AlchemintWalletiOS/AlchemintProject/Pods/RxSwift/RxSwift/SchedulerType.swift /Users/babaiholdings/Documents/AlchemintWalletiOS/AlchemintProject/Pods/RxSwift/RxSwift/ImmediateSchedulerType.swift /Users/babaiholdings/Documents/AlchemintWalletiOS/AlchemintProject/Pods/RxSwift/RxSwift/Concurrency/LockOwnerType.swift /Users/babaiholdings/Documents/AlchemintWalletiOS/AlchemintProject/Pods/RxSwift/RxSwift/Schedulers/VirtualTimeConverterType.swift /Users/babaiholdings/Documents/AlchemintWalletiOS/AlchemintProject/Pods/RxSwift/RxSwift/ObserverType.swift /Users/babaiholdings/Documents/AlchemintWalletiOS/AlchemintProject/Pods/RxSwift/RxSwift/Subjects/SubjectType.swift /Users/babaiholdings/Documents/AlchemintWalletiOS/AlchemintProject/Pods/RxSwift/RxSwift/Disposables/DisposeBase.swift /Users/babaiholdings/Documents/AlchemintWalletiOS/AlchemintProject/Pods/RxSwift/RxSwift/Observers/ObserverBase.swift /Users/babaiholdings/Documents/AlchemintWalletiOS/AlchemintProject/Pods/RxSwift/RxSwift/Observables/Create.swift /Users/babaiholdings/Documents/AlchemintWalletiOS/AlchemintProject/Pods/RxSwift/RxSwift/Observables/Generate.swift /Users/babaiholdings/Documents/AlchemintWalletiOS/AlchemintProject/Pods/RxSwift/Platform/DataStructures/Queue.swift /Users/babaiholdings/Documents/AlchemintWalletiOS/AlchemintProject/Pods/RxSwift/Platform/DataStructures/PriorityQueue.swift /Users/babaiholdings/Documents/AlchemintWalletiOS/AlchemintProject/Pods/RxSwift/RxSwift/Reactive.swift /Users/babaiholdings/Documents/AlchemintWalletiOS/AlchemintProject/Pods/RxSwift/RxSwift/Observables/Materialize.swift /Users/babaiholdings/Documents/AlchemintWalletiOS/AlchemintProject/Pods/RxSwift/RxSwift/Observables/Dematerialize.swift /Users/babaiholdings/Documents/AlchemintWalletiOS/AlchemintProject/Pods/RxSwift/RxSwift/Observables/AddRef.swift /Users/babaiholdings/Documents/AlchemintWalletiOS/AlchemintProject/Pods/RxSwift/Platform/DataStructures/Bag.swift /Users/babaiholdings/Documents/AlchemintWalletiOS/AlchemintProject/Pods/RxSwift/RxSwift/Disposables/DisposeBag.swift /Users/babaiholdings/Documents/AlchemintWalletiOS/AlchemintProject/Pods/RxSwift/RxSwift/Observables/Using.swift /Users/babaiholdings/Documents/AlchemintWalletiOS/AlchemintProject/Pods/RxSwift/RxSwift/Observables/Debug.swift /Users/babaiholdings/Documents/AlchemintWalletiOS/AlchemintProject/Pods/RxSwift/RxSwift/Observables/Catch.swift /Users/babaiholdings/Documents/AlchemintWalletiOS/AlchemintProject/Pods/RxSwift/RxSwift/Observables/Switch.swift /Users/babaiholdings/Documents/AlchemintWalletiOS/AlchemintProject/Pods/RxSwift/RxSwift/Observables/StartWith.swift /Users/babaiholdings/Documents/AlchemintWalletiOS/AlchemintProject/Pods/RxSwift/RxSwift/Concurrency/Lock.swift /Users/babaiholdings/Documents/AlchemintWalletiOS/AlchemintProject/Pods/RxSwift/RxSwift/Concurrency/AsyncLock.swift /Users/babaiholdings/Documents/AlchemintWalletiOS/AlchemintProject/Pods/RxSwift/Platform/RecursiveLock.swift /Users/babaiholdings/Documents/AlchemintWalletiOS/AlchemintProject/Pods/RxSwift/RxSwift/Observables/Sink.swift /Users/babaiholdings/Documents/AlchemintWalletiOS/AlchemintProject/Pods/RxSwift/RxSwift/Observers/TailRecursiveSink.swift /Users/babaiholdings/Documents/AlchemintWalletiOS/AlchemintProject/Pods/RxSwift/RxSwift/Observables/Optional.swift /Users/babaiholdings/Documents/AlchemintWalletiOS/AlchemintProject/Pods/RxSwift/RxSwift/Observables/TakeUntil.swift /Users/babaiholdings/Documents/AlchemintWalletiOS/AlchemintProject/Pods/RxSwift/RxSwift/Observables/SkipUntil.swift /Users/babaiholdings/Documents/AlchemintWalletiOS/AlchemintProject/Pods/RxSwift/RxSwift/Schedulers/Internal/ScheduledItem.swift /Users/babaiholdings/Documents/AlchemintWalletiOS/AlchemintProject/Pods/RxSwift/RxSwift/Schedulers/Internal/InvocableScheduledItem.swift /Users/babaiholdings/Documents/AlchemintWalletiOS/AlchemintProject/Pods/RxSwift/RxSwift/Observables/WithLatestFrom.swift /Users/babaiholdings/Documents/AlchemintWalletiOS/AlchemintProject/Pods/RxSwift/RxSwift/Observables/SubscribeOn.swift /Users/babaiholdings/Documents/AlchemintWalletiOS/AlchemintProject/Pods/RxSwift/RxSwift/Observables/ObserveOn.swift /Users/babaiholdings/Documents/AlchemintWalletiOS/AlchemintProject/Pods/RxSwift/RxSwift/Observables/Scan.swift /Users/babaiholdings/Documents/AlchemintWalletiOS/AlchemintProject/Pods/RxSwift/RxSwift/Traits/Completable+AndThen.swift /Users/babaiholdings/Documents/AlchemintWalletiOS/AlchemintProject/Pods/RxSwift/RxSwift/Observables/RetryWhen.swift /Users/babaiholdings/Documents/AlchemintWalletiOS/AlchemintProject/Pods/RxSwift/Platform/Platform.Darwin.swift /Users/babaiholdings/Documents/AlchemintWalletiOS/AlchemintProject/Pods/RxSwift/RxSwift/Schedulers/SchedulerServices+Emulation.swift /Users/babaiholdings/Documents/AlchemintWalletiOS/AlchemintProject/Pods/RxSwift/RxSwift/Schedulers/Internal/DispatchQueueConfiguration.swift /Users/babaiholdings/Documents/AlchemintWalletiOS/AlchemintProject/Pods/RxSwift/RxSwift/Observables/Zip+Collection.swift /Users/babaiholdings/Documents/AlchemintWalletiOS/AlchemintProject/Pods/RxSwift/RxSwift/Observables/CombineLatest+Collection.swift /Users/babaiholdings/Documents/AlchemintWalletiOS/AlchemintProject/Pods/RxSwift/RxSwift/Observables/DelaySubscription.swift /Users/babaiholdings/Documents/AlchemintWalletiOS/AlchemintProject/Pods/RxSwift/RxSwift/Observables/Do.swift /Users/babaiholdings/Documents/AlchemintWalletiOS/AlchemintProject/Pods/RxSwift/RxSwift/Observables/Map.swift /Users/babaiholdings/Documents/AlchemintWalletiOS/AlchemintProject/Pods/RxSwift/RxSwift/Observables/Zip.swift /Users/babaiholdings/Documents/AlchemintWalletiOS/AlchemintProject/Pods/RxSwift/RxSwift/Observables/Skip.swift /Users/babaiholdings/Documents/AlchemintWalletiOS/AlchemintProject/Pods/RxSwift/RxSwift/Observables/Producer.swift /Users/babaiholdings/Documents/AlchemintWalletiOS/AlchemintProject/Pods/RxSwift/RxSwift/Observables/Buffer.swift /Users/babaiholdings/Documents/AlchemintWalletiOS/AlchemintProject/Pods/RxSwift/RxSwift/Schedulers/CurrentThreadScheduler.swift /Users/babaiholdings/Documents/AlchemintWalletiOS/AlchemintProject/Pods/RxSwift/RxSwift/Schedulers/VirtualTimeScheduler.swift /Users/babaiholdings/Documents/AlchemintWalletiOS/AlchemintProject/Pods/RxSwift/RxSwift/Schedulers/SerialDispatchQueueScheduler.swift /Users/babaiholdings/Documents/AlchemintWalletiOS/AlchemintProject/Pods/RxSwift/RxSwift/Schedulers/ConcurrentDispatchQueueScheduler.swift /Users/babaiholdings/Documents/AlchemintWalletiOS/AlchemintProject/Pods/RxSwift/RxSwift/Schedulers/OperationQueueScheduler.swift /Users/babaiholdings/Documents/AlchemintWalletiOS/AlchemintProject/Pods/RxSwift/RxSwift/Schedulers/RecursiveScheduler.swift /Users/babaiholdings/Documents/AlchemintWalletiOS/AlchemintProject/Pods/RxSwift/RxSwift/Schedulers/HistoricalScheduler.swift /Users/babaiholdings/Documents/AlchemintWalletiOS/AlchemintProject/Pods/RxSwift/RxSwift/Schedulers/MainScheduler.swift /Users/babaiholdings/Documents/AlchemintWalletiOS/AlchemintProject/Pods/RxSwift/RxSwift/Schedulers/ConcurrentMainScheduler.swift /Users/babaiholdings/Documents/AlchemintWalletiOS/AlchemintProject/Pods/RxSwift/RxSwift/Observables/Timer.swift /Users/babaiholdings/Documents/AlchemintWalletiOS/AlchemintProject/Pods/RxSwift/Platform/DeprecationWarner.swift /Users/babaiholdings/Documents/AlchemintWalletiOS/AlchemintProject/Pods/RxSwift/RxSwift/Observables/Filter.swift /Users/babaiholdings/Documents/AlchemintWalletiOS/AlchemintProject/Pods/RxSwift/RxSwift/Schedulers/HistoricalSchedulerTimeConverter.swift /Users/babaiholdings/Documents/AlchemintWalletiOS/AlchemintProject/Pods/RxSwift/RxSwift/Observables/Never.swift /Users/babaiholdings/Documents/AlchemintWalletiOS/AlchemintProject/Pods/RxSwift/RxSwift/Observers/AnonymousObserver.swift /Users/babaiholdings/Documents/AlchemintWalletiOS/AlchemintProject/Pods/RxSwift/RxSwift/AnyObserver.swift /Users/babaiholdings/Documents/AlchemintWalletiOS/AlchemintProject/Pods/RxSwift/RxSwift/Observables/Error.swift /Users/babaiholdings/Documents/AlchemintWalletiOS/AlchemintProject/Pods/RxSwift/RxSwift/Disposables/Disposables.swift /Users/babaiholdings/Documents/AlchemintWalletiOS/AlchemintProject/Pods/RxSwift/RxSwift/ObservableType+Extensions.swift /Users/babaiholdings/Documents/AlchemintWalletiOS/AlchemintProject/Pods/RxSwift/Platform/DispatchQueue+Extensions.swift /Users/babaiholdings/Documents/AlchemintWalletiOS/AlchemintProject/Pods/RxSwift/RxSwift/Errors.swift /Users/babaiholdings/Documents/AlchemintWalletiOS/AlchemintProject/Pods/RxSwift/RxSwift/Observables/ElementAt.swift /Users/babaiholdings/Documents/AlchemintWalletiOS/AlchemintProject/Pods/RxSwift/RxSwift/Observables/Concat.swift /Users/babaiholdings/Documents/AlchemintWalletiOS/AlchemintProject/Pods/RxSwift/RxSwift/Observables/Repeat.swift /Users/babaiholdings/Documents/AlchemintWalletiOS/AlchemintProject/Pods/RxSwift/RxSwift/Subjects/AsyncSubject.swift /Users/babaiholdings/Documents/AlchemintWalletiOS/AlchemintProject/Pods/RxSwift/RxSwift/Subjects/PublishSubject.swift /Users/babaiholdings/Documents/AlchemintWalletiOS/AlchemintProject/Pods/RxSwift/RxSwift/Subjects/BehaviorSubject.swift /Users/babaiholdings/Documents/AlchemintWalletiOS/AlchemintProject/Pods/RxSwift/RxSwift/Subjects/ReplaySubject.swift /Users/babaiholdings/Documents/AlchemintWalletiOS/AlchemintProject/Pods/RxSwift/RxSwift/Event.swift /Users/babaiholdings/Documents/AlchemintWalletiOS/AlchemintProject/Pods/RxSwift/RxSwift/SwiftSupport/SwiftSupport.swift /Users/babaiholdings/Documents/AlchemintWalletiOS/AlchemintProject/Pods/RxSwift/RxSwift/Observables/TakeLast.swift /Users/babaiholdings/Documents/AlchemintWalletiOS/AlchemintProject/Pods/RxSwift/RxSwift/Observables/Multicast.swift /Users/babaiholdings/Documents/AlchemintWalletiOS/AlchemintProject/Pods/RxSwift/RxSwift/Observables/CombineLatest.swift /Users/babaiholdings/Documents/AlchemintWalletiOS/AlchemintProject/Pods/RxSwift/RxSwift/Observables/First.swift /Users/babaiholdings/Documents/AlchemintWalletiOS/AlchemintProject/Pods/RxSwift/RxSwift/Observables/Just.swift /Users/babaiholdings/Documents/AlchemintWalletiOS/AlchemintProject/Pods/RxSwift/RxSwift/Observables/Timeout.swift /Users/babaiholdings/Documents/AlchemintWalletiOS/AlchemintProject/Pods/RxSwift/RxSwift/Observables/Window.swift /Users/babaiholdings/Documents/AlchemintWalletiOS/AlchemintProject/Pods/RxSwift/RxSwift/Extensions/Bag+Rx.swift /Users/babaiholdings/Documents/AlchemintWalletiOS/AlchemintProject/Pods/RxSwift/RxSwift/Extensions/String+Rx.swift /Users/babaiholdings/Documents/AlchemintWalletiOS/AlchemintProject/Pods/RxSwift/RxSwift/Rx.swift /Users/babaiholdings/Documents/AlchemintWalletiOS/AlchemintProject/Pods/RxSwift/RxSwift/RxMutableBox.swift /Users/babaiholdings/Documents/AlchemintWalletiOS/AlchemintProject/Pods/RxSwift/Platform/Platform.Linux.swift /Users/babaiholdings/Documents/AlchemintWalletiOS/AlchemintProject/Pods/RxSwift/RxSwift/Observables/GroupBy.swift /Users/babaiholdings/Documents/AlchemintWalletiOS/AlchemintProject/Pods/RxSwift/RxSwift/Observables/Delay.swift /Users/babaiholdings/Documents/AlchemintWalletiOS/AlchemintProject/Pods/RxSwift/RxSwift/Observables/ToArray.swift /Users/babaiholdings/Documents/AlchemintWalletiOS/AlchemintProject/Pods/RxSwift/RxSwift/Traits/PrimitiveSequence+Zip+arity.swift /Users/babaiholdings/Documents/AlchemintWalletiOS/AlchemintProject/Pods/RxSwift/RxSwift/Observables/Zip+arity.swift /Users/babaiholdings/Documents/AlchemintWalletiOS/AlchemintProject/Pods/RxSwift/RxSwift/Observables/CombineLatest+arity.swift /Users/babaiholdings/Documents/AlchemintWalletiOS/AlchemintProject/Pods/RxSwift/RxSwift/Observables/Empty.swift /Users/babaiholdings/Documents/AlchemintWalletiOS/AlchemintProject/Pods/RxSwift/RxSwift/Observables/SwitchIfEmpty.swift /Users/babaiholdings/Documents/AlchemintWalletiOS/AlchemintProject/Pods/RxSwift/RxSwift/Observables/DefaultIfEmpty.swift /Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/lib/swift/iphonesimulator/x86_64/Dispatch.apinotesc /Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/lib/swift/iphonesimulator/x86_64/ObjectiveC.swiftmodule /Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/lib/swift/iphonesimulator/x86_64/CoreImage.swiftmodule /Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/lib/swift/iphonesimulator/x86_64/QuartzCore.swiftmodule /Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/lib/swift/iphonesimulator/x86_64/Dispatch.swiftmodule /Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/lib/swift/iphonesimulator/x86_64/Metal.swiftmodule /Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/lib/swift/iphonesimulator/x86_64/Darwin.swiftmodule /Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/lib/swift/iphonesimulator/x86_64/Foundation.swiftmodule /Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/lib/swift/iphonesimulator/x86_64/CoreFoundation.swiftmodule /Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/lib/swift/iphonesimulator/x86_64/CoreGraphics.swiftmodule /Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/lib/swift/iphonesimulator/x86_64/Swift.swiftmodule /Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/lib/swift/iphonesimulator/x86_64/UIKit.swiftmodule /Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/lib/swift/iphonesimulator/x86_64/SwiftOnoneSupport.swiftmodule /Users/babaiholdings/Documents/AlchemintWalletiOS/AlchemintProject/Pods/Target\ Support\ Files/RxSwift/RxSwift-umbrella.h /Users/babaiholdings/Documents/AlchemintWalletiOS/AlchemintProject/Build/Intermediates.noindex/Pods.build/Debug-iphonesimulator/RxSwift.build/unextended-module.modulemap /Applications/Xcode.app/Contents/Developer/Platforms/iPhoneSimulator.platform/Developer/SDKs/iPhoneSimulator11.4.sdk/usr/include/objc/ObjectiveC.apinotes /Applications/Xcode.app/Contents/Developer/Platforms/iPhoneSimulator.platform/Developer/SDKs/iPhoneSimulator11.4.sdk/System/Library/Frameworks/OpenGLES.framework/Headers/OpenGLES.apinotes /Applications/Xcode.app/Contents/Developer/Platforms/iPhoneSimulator.platform/Developer/SDKs/iPhoneSimulator11.4.sdk/System/Library/Frameworks/CoreImage.framework/Headers/CoreImage.apinotes /Applications/Xcode.app/Contents/Developer/Platforms/iPhoneSimulator.platform/Developer/SDKs/iPhoneSimulator11.4.sdk/System/Library/Frameworks/QuartzCore.framework/Headers/QuartzCore.apinotes /Applications/Xcode.app/Contents/Developer/Platforms/iPhoneSimulator.platform/Developer/SDKs/iPhoneSimulator11.4.sdk/System/Library/Frameworks/Metal.framework/Headers/Metal.apinotes /Applications/Xcode.app/Contents/Developer/Platforms/iPhoneSimulator.platform/Developer/SDKs/iPhoneSimulator11.4.sdk/usr/include/Darwin.apinotes /Applications/Xcode.app/Contents/Developer/Platforms/iPhoneSimulator.platform/Developer/SDKs/iPhoneSimulator11.4.sdk/System/Library/Frameworks/Foundation.framework/Headers/Foundation.apinotes /Applications/Xcode.app/Contents/Developer/Platforms/iPhoneSimulator.platform/Developer/SDKs/iPhoneSimulator11.4.sdk/System/Library/Frameworks/CoreGraphics.framework/Headers/CoreGraphics.apinotes /Applications/Xcode.app/Contents/Developer/Platforms/iPhoneSimulator.platform/Developer/SDKs/iPhoneSimulator11.4.sdk/System/Library/Frameworks/UIKit.framework/Headers/UIKit.apinotes /Applications/Xcode.app/Contents/Developer/Platforms/iPhoneSimulator.platform/Developer/SDKs/iPhoneSimulator11.4.sdk/System/Library/Frameworks/CoreText.framework/Headers/CoreText.apinotes
/Users/babaiholdings/Documents/AlchemintWalletiOS/AlchemintProject/Build/Intermediates.noindex/Pods.build/Debug-iphonesimulator/RxSwift.build/Objects-normal/x86_64/CompositeDisposable~partial.swiftdoc : /Users/babaiholdings/Documents/AlchemintWalletiOS/AlchemintProject/Pods/RxSwift/RxSwift/Observables/Amb.swift /Users/babaiholdings/Documents/AlchemintWalletiOS/AlchemintProject/Pods/RxSwift/RxSwift/Observables/SingleAsync.swift /Users/babaiholdings/Documents/AlchemintWalletiOS/AlchemintProject/Pods/RxSwift/RxSwift/Observables/DistinctUntilChanged.swift /Users/babaiholdings/Documents/AlchemintWalletiOS/AlchemintProject/Pods/RxSwift/RxSwift/Observables/Deferred.swift /Users/babaiholdings/Documents/AlchemintWalletiOS/AlchemintProject/Pods/RxSwift/RxSwift/Deprecated.swift /Users/babaiholdings/Documents/AlchemintWalletiOS/AlchemintProject/Pods/RxSwift/RxSwift/Observables/Enumerated.swift /Users/babaiholdings/Documents/AlchemintWalletiOS/AlchemintProject/Pods/RxSwift/RxSwift/Traits/Maybe.swift /Users/babaiholdings/Documents/AlchemintWalletiOS/AlchemintProject/Pods/RxSwift/RxSwift/Observables/AsMaybe.swift /Users/babaiholdings/Documents/AlchemintWalletiOS/AlchemintProject/Pods/RxSwift/RxSwift/Observables/Sequence.swift /Users/babaiholdings/Documents/AlchemintWalletiOS/AlchemintProject/Pods/RxSwift/Platform/DataStructures/InfiniteSequence.swift /Users/babaiholdings/Documents/AlchemintWalletiOS/AlchemintProject/Pods/RxSwift/RxSwift/Traits/ObservableType+PrimitiveSequence.swift /Users/babaiholdings/Documents/AlchemintWalletiOS/AlchemintProject/Pods/RxSwift/RxSwift/Traits/PrimitiveSequence.swift /Users/babaiholdings/Documents/AlchemintWalletiOS/AlchemintProject/Pods/RxSwift/RxSwift/Observables/Debounce.swift /Users/babaiholdings/Documents/AlchemintWalletiOS/AlchemintProject/Pods/RxSwift/RxSwift/Observables/Reduce.swift /Users/babaiholdings/Documents/AlchemintWalletiOS/AlchemintProject/Pods/RxSwift/RxSwift/Observables/Range.swift /Users/babaiholdings/Documents/AlchemintWalletiOS/AlchemintProject/Pods/RxSwift/RxSwift/Observables/Merge.swift /Users/babaiholdings/Documents/AlchemintWalletiOS/AlchemintProject/Pods/RxSwift/RxSwift/Observables/Take.swift /Users/babaiholdings/Documents/AlchemintWalletiOS/AlchemintProject/Pods/RxSwift/RxSwift/Cancelable.swift /Users/babaiholdings/Documents/AlchemintWalletiOS/AlchemintProject/Pods/RxSwift/RxSwift/Disposable.swift /Users/babaiholdings/Documents/AlchemintWalletiOS/AlchemintProject/Pods/RxSwift/RxSwift/Disposables/ScheduledDisposable.swift /Users/babaiholdings/Documents/AlchemintWalletiOS/AlchemintProject/Pods/RxSwift/RxSwift/Disposables/CompositeDisposable.swift /Users/babaiholdings/Documents/AlchemintWalletiOS/AlchemintProject/Pods/RxSwift/RxSwift/Disposables/SerialDisposable.swift /Users/babaiholdings/Documents/AlchemintWalletiOS/AlchemintProject/Pods/RxSwift/RxSwift/Disposables/BooleanDisposable.swift /Users/babaiholdings/Documents/AlchemintWalletiOS/AlchemintProject/Pods/RxSwift/RxSwift/Disposables/SubscriptionDisposable.swift /Users/babaiholdings/Documents/AlchemintWalletiOS/AlchemintProject/Pods/RxSwift/RxSwift/Disposables/NopDisposable.swift /Users/babaiholdings/Documents/AlchemintWalletiOS/AlchemintProject/Pods/RxSwift/RxSwift/Disposables/AnonymousDisposable.swift /Users/babaiholdings/Documents/AlchemintWalletiOS/AlchemintProject/Pods/RxSwift/RxSwift/Disposables/SingleAssignmentDisposable.swift /Users/babaiholdings/Documents/AlchemintWalletiOS/AlchemintProject/Pods/RxSwift/RxSwift/Disposables/RefCountDisposable.swift /Users/babaiholdings/Documents/AlchemintWalletiOS/AlchemintProject/Pods/RxSwift/RxSwift/Disposables/BinaryDisposable.swift /Users/babaiholdings/Documents/AlchemintWalletiOS/AlchemintProject/Pods/RxSwift/RxSwift/Traits/Completable.swift /Users/babaiholdings/Documents/AlchemintWalletiOS/AlchemintProject/Pods/RxSwift/RxSwift/Observable.swift /Users/babaiholdings/Documents/AlchemintWalletiOS/AlchemintProject/Pods/RxSwift/RxSwift/GroupedObservable.swift /Users/babaiholdings/Documents/AlchemintWalletiOS/AlchemintProject/Pods/RxSwift/RxSwift/Traits/Single.swift /Users/babaiholdings/Documents/AlchemintWalletiOS/AlchemintProject/Pods/RxSwift/RxSwift/Observables/AsSingle.swift /Users/babaiholdings/Documents/AlchemintWalletiOS/AlchemintProject/Pods/RxSwift/RxSwift/Observables/TakeWhile.swift /Users/babaiholdings/Documents/AlchemintWalletiOS/AlchemintProject/Pods/RxSwift/RxSwift/Observables/SkipWhile.swift /Users/babaiholdings/Documents/AlchemintWalletiOS/AlchemintProject/Pods/RxSwift/RxSwift/Observables/Sample.swift /Users/babaiholdings/Documents/AlchemintWalletiOS/AlchemintProject/Pods/RxSwift/RxSwift/Observables/Throttle.swift /Users/babaiholdings/Documents/AlchemintWalletiOS/AlchemintProject/Pods/RxSwift/RxSwift/Observables/ShareReplayScope.swift /Users/babaiholdings/Documents/AlchemintWalletiOS/AlchemintProject/Pods/RxSwift/RxSwift/Concurrency/SynchronizedUnsubscribeType.swift /Users/babaiholdings/Documents/AlchemintWalletiOS/AlchemintProject/Pods/RxSwift/RxSwift/Schedulers/Internal/InvocableType.swift /Users/babaiholdings/Documents/AlchemintWalletiOS/AlchemintProject/Pods/RxSwift/RxSwift/ObservableType.swift /Users/babaiholdings/Documents/AlchemintWalletiOS/AlchemintProject/Pods/RxSwift/RxSwift/ConnectableObservableType.swift /Users/babaiholdings/Documents/AlchemintWalletiOS/AlchemintProject/Pods/RxSwift/RxSwift/ObservableConvertibleType.swift /Users/babaiholdings/Documents/AlchemintWalletiOS/AlchemintProject/Pods/RxSwift/RxSwift/Concurrency/SynchronizedDisposeType.swift /Users/babaiholdings/Documents/AlchemintWalletiOS/AlchemintProject/Pods/RxSwift/RxSwift/Schedulers/Internal/ScheduledItemType.swift /Users/babaiholdings/Documents/AlchemintWalletiOS/AlchemintProject/Pods/RxSwift/RxSwift/Concurrency/SynchronizedOnType.swift /Users/babaiholdings/Documents/AlchemintWalletiOS/AlchemintProject/Pods/RxSwift/RxSwift/SchedulerType.swift /Users/babaiholdings/Documents/AlchemintWalletiOS/AlchemintProject/Pods/RxSwift/RxSwift/ImmediateSchedulerType.swift /Users/babaiholdings/Documents/AlchemintWalletiOS/AlchemintProject/Pods/RxSwift/RxSwift/Concurrency/LockOwnerType.swift /Users/babaiholdings/Documents/AlchemintWalletiOS/AlchemintProject/Pods/RxSwift/RxSwift/Schedulers/VirtualTimeConverterType.swift /Users/babaiholdings/Documents/AlchemintWalletiOS/AlchemintProject/Pods/RxSwift/RxSwift/ObserverType.swift /Users/babaiholdings/Documents/AlchemintWalletiOS/AlchemintProject/Pods/RxSwift/RxSwift/Subjects/SubjectType.swift /Users/babaiholdings/Documents/AlchemintWalletiOS/AlchemintProject/Pods/RxSwift/RxSwift/Disposables/DisposeBase.swift /Users/babaiholdings/Documents/AlchemintWalletiOS/AlchemintProject/Pods/RxSwift/RxSwift/Observers/ObserverBase.swift /Users/babaiholdings/Documents/AlchemintWalletiOS/AlchemintProject/Pods/RxSwift/RxSwift/Observables/Create.swift /Users/babaiholdings/Documents/AlchemintWalletiOS/AlchemintProject/Pods/RxSwift/RxSwift/Observables/Generate.swift /Users/babaiholdings/Documents/AlchemintWalletiOS/AlchemintProject/Pods/RxSwift/Platform/DataStructures/Queue.swift /Users/babaiholdings/Documents/AlchemintWalletiOS/AlchemintProject/Pods/RxSwift/Platform/DataStructures/PriorityQueue.swift /Users/babaiholdings/Documents/AlchemintWalletiOS/AlchemintProject/Pods/RxSwift/RxSwift/Reactive.swift /Users/babaiholdings/Documents/AlchemintWalletiOS/AlchemintProject/Pods/RxSwift/RxSwift/Observables/Materialize.swift /Users/babaiholdings/Documents/AlchemintWalletiOS/AlchemintProject/Pods/RxSwift/RxSwift/Observables/Dematerialize.swift /Users/babaiholdings/Documents/AlchemintWalletiOS/AlchemintProject/Pods/RxSwift/RxSwift/Observables/AddRef.swift /Users/babaiholdings/Documents/AlchemintWalletiOS/AlchemintProject/Pods/RxSwift/Platform/DataStructures/Bag.swift /Users/babaiholdings/Documents/AlchemintWalletiOS/AlchemintProject/Pods/RxSwift/RxSwift/Disposables/DisposeBag.swift /Users/babaiholdings/Documents/AlchemintWalletiOS/AlchemintProject/Pods/RxSwift/RxSwift/Observables/Using.swift /Users/babaiholdings/Documents/AlchemintWalletiOS/AlchemintProject/Pods/RxSwift/RxSwift/Observables/Debug.swift /Users/babaiholdings/Documents/AlchemintWalletiOS/AlchemintProject/Pods/RxSwift/RxSwift/Observables/Catch.swift /Users/babaiholdings/Documents/AlchemintWalletiOS/AlchemintProject/Pods/RxSwift/RxSwift/Observables/Switch.swift /Users/babaiholdings/Documents/AlchemintWalletiOS/AlchemintProject/Pods/RxSwift/RxSwift/Observables/StartWith.swift /Users/babaiholdings/Documents/AlchemintWalletiOS/AlchemintProject/Pods/RxSwift/RxSwift/Concurrency/Lock.swift /Users/babaiholdings/Documents/AlchemintWalletiOS/AlchemintProject/Pods/RxSwift/RxSwift/Concurrency/AsyncLock.swift /Users/babaiholdings/Documents/AlchemintWalletiOS/AlchemintProject/Pods/RxSwift/Platform/RecursiveLock.swift /Users/babaiholdings/Documents/AlchemintWalletiOS/AlchemintProject/Pods/RxSwift/RxSwift/Observables/Sink.swift /Users/babaiholdings/Documents/AlchemintWalletiOS/AlchemintProject/Pods/RxSwift/RxSwift/Observers/TailRecursiveSink.swift /Users/babaiholdings/Documents/AlchemintWalletiOS/AlchemintProject/Pods/RxSwift/RxSwift/Observables/Optional.swift /Users/babaiholdings/Documents/AlchemintWalletiOS/AlchemintProject/Pods/RxSwift/RxSwift/Observables/TakeUntil.swift /Users/babaiholdings/Documents/AlchemintWalletiOS/AlchemintProject/Pods/RxSwift/RxSwift/Observables/SkipUntil.swift /Users/babaiholdings/Documents/AlchemintWalletiOS/AlchemintProject/Pods/RxSwift/RxSwift/Schedulers/Internal/ScheduledItem.swift /Users/babaiholdings/Documents/AlchemintWalletiOS/AlchemintProject/Pods/RxSwift/RxSwift/Schedulers/Internal/InvocableScheduledItem.swift /Users/babaiholdings/Documents/AlchemintWalletiOS/AlchemintProject/Pods/RxSwift/RxSwift/Observables/WithLatestFrom.swift /Users/babaiholdings/Documents/AlchemintWalletiOS/AlchemintProject/Pods/RxSwift/RxSwift/Observables/SubscribeOn.swift /Users/babaiholdings/Documents/AlchemintWalletiOS/AlchemintProject/Pods/RxSwift/RxSwift/Observables/ObserveOn.swift /Users/babaiholdings/Documents/AlchemintWalletiOS/AlchemintProject/Pods/RxSwift/RxSwift/Observables/Scan.swift /Users/babaiholdings/Documents/AlchemintWalletiOS/AlchemintProject/Pods/RxSwift/RxSwift/Traits/Completable+AndThen.swift /Users/babaiholdings/Documents/AlchemintWalletiOS/AlchemintProject/Pods/RxSwift/RxSwift/Observables/RetryWhen.swift /Users/babaiholdings/Documents/AlchemintWalletiOS/AlchemintProject/Pods/RxSwift/Platform/Platform.Darwin.swift /Users/babaiholdings/Documents/AlchemintWalletiOS/AlchemintProject/Pods/RxSwift/RxSwift/Schedulers/SchedulerServices+Emulation.swift /Users/babaiholdings/Documents/AlchemintWalletiOS/AlchemintProject/Pods/RxSwift/RxSwift/Schedulers/Internal/DispatchQueueConfiguration.swift /Users/babaiholdings/Documents/AlchemintWalletiOS/AlchemintProject/Pods/RxSwift/RxSwift/Observables/Zip+Collection.swift /Users/babaiholdings/Documents/AlchemintWalletiOS/AlchemintProject/Pods/RxSwift/RxSwift/Observables/CombineLatest+Collection.swift /Users/babaiholdings/Documents/AlchemintWalletiOS/AlchemintProject/Pods/RxSwift/RxSwift/Observables/DelaySubscription.swift /Users/babaiholdings/Documents/AlchemintWalletiOS/AlchemintProject/Pods/RxSwift/RxSwift/Observables/Do.swift /Users/babaiholdings/Documents/AlchemintWalletiOS/AlchemintProject/Pods/RxSwift/RxSwift/Observables/Map.swift /Users/babaiholdings/Documents/AlchemintWalletiOS/AlchemintProject/Pods/RxSwift/RxSwift/Observables/Zip.swift /Users/babaiholdings/Documents/AlchemintWalletiOS/AlchemintProject/Pods/RxSwift/RxSwift/Observables/Skip.swift /Users/babaiholdings/Documents/AlchemintWalletiOS/AlchemintProject/Pods/RxSwift/RxSwift/Observables/Producer.swift /Users/babaiholdings/Documents/AlchemintWalletiOS/AlchemintProject/Pods/RxSwift/RxSwift/Observables/Buffer.swift /Users/babaiholdings/Documents/AlchemintWalletiOS/AlchemintProject/Pods/RxSwift/RxSwift/Schedulers/CurrentThreadScheduler.swift /Users/babaiholdings/Documents/AlchemintWalletiOS/AlchemintProject/Pods/RxSwift/RxSwift/Schedulers/VirtualTimeScheduler.swift /Users/babaiholdings/Documents/AlchemintWalletiOS/AlchemintProject/Pods/RxSwift/RxSwift/Schedulers/SerialDispatchQueueScheduler.swift /Users/babaiholdings/Documents/AlchemintWalletiOS/AlchemintProject/Pods/RxSwift/RxSwift/Schedulers/ConcurrentDispatchQueueScheduler.swift /Users/babaiholdings/Documents/AlchemintWalletiOS/AlchemintProject/Pods/RxSwift/RxSwift/Schedulers/OperationQueueScheduler.swift /Users/babaiholdings/Documents/AlchemintWalletiOS/AlchemintProject/Pods/RxSwift/RxSwift/Schedulers/RecursiveScheduler.swift /Users/babaiholdings/Documents/AlchemintWalletiOS/AlchemintProject/Pods/RxSwift/RxSwift/Schedulers/HistoricalScheduler.swift /Users/babaiholdings/Documents/AlchemintWalletiOS/AlchemintProject/Pods/RxSwift/RxSwift/Schedulers/MainScheduler.swift /Users/babaiholdings/Documents/AlchemintWalletiOS/AlchemintProject/Pods/RxSwift/RxSwift/Schedulers/ConcurrentMainScheduler.swift /Users/babaiholdings/Documents/AlchemintWalletiOS/AlchemintProject/Pods/RxSwift/RxSwift/Observables/Timer.swift /Users/babaiholdings/Documents/AlchemintWalletiOS/AlchemintProject/Pods/RxSwift/Platform/DeprecationWarner.swift /Users/babaiholdings/Documents/AlchemintWalletiOS/AlchemintProject/Pods/RxSwift/RxSwift/Observables/Filter.swift /Users/babaiholdings/Documents/AlchemintWalletiOS/AlchemintProject/Pods/RxSwift/RxSwift/Schedulers/HistoricalSchedulerTimeConverter.swift /Users/babaiholdings/Documents/AlchemintWalletiOS/AlchemintProject/Pods/RxSwift/RxSwift/Observables/Never.swift /Users/babaiholdings/Documents/AlchemintWalletiOS/AlchemintProject/Pods/RxSwift/RxSwift/Observers/AnonymousObserver.swift /Users/babaiholdings/Documents/AlchemintWalletiOS/AlchemintProject/Pods/RxSwift/RxSwift/AnyObserver.swift /Users/babaiholdings/Documents/AlchemintWalletiOS/AlchemintProject/Pods/RxSwift/RxSwift/Observables/Error.swift /Users/babaiholdings/Documents/AlchemintWalletiOS/AlchemintProject/Pods/RxSwift/RxSwift/Disposables/Disposables.swift /Users/babaiholdings/Documents/AlchemintWalletiOS/AlchemintProject/Pods/RxSwift/RxSwift/ObservableType+Extensions.swift /Users/babaiholdings/Documents/AlchemintWalletiOS/AlchemintProject/Pods/RxSwift/Platform/DispatchQueue+Extensions.swift /Users/babaiholdings/Documents/AlchemintWalletiOS/AlchemintProject/Pods/RxSwift/RxSwift/Errors.swift /Users/babaiholdings/Documents/AlchemintWalletiOS/AlchemintProject/Pods/RxSwift/RxSwift/Observables/ElementAt.swift /Users/babaiholdings/Documents/AlchemintWalletiOS/AlchemintProject/Pods/RxSwift/RxSwift/Observables/Concat.swift /Users/babaiholdings/Documents/AlchemintWalletiOS/AlchemintProject/Pods/RxSwift/RxSwift/Observables/Repeat.swift /Users/babaiholdings/Documents/AlchemintWalletiOS/AlchemintProject/Pods/RxSwift/RxSwift/Subjects/AsyncSubject.swift /Users/babaiholdings/Documents/AlchemintWalletiOS/AlchemintProject/Pods/RxSwift/RxSwift/Subjects/PublishSubject.swift /Users/babaiholdings/Documents/AlchemintWalletiOS/AlchemintProject/Pods/RxSwift/RxSwift/Subjects/BehaviorSubject.swift /Users/babaiholdings/Documents/AlchemintWalletiOS/AlchemintProject/Pods/RxSwift/RxSwift/Subjects/ReplaySubject.swift /Users/babaiholdings/Documents/AlchemintWalletiOS/AlchemintProject/Pods/RxSwift/RxSwift/Event.swift /Users/babaiholdings/Documents/AlchemintWalletiOS/AlchemintProject/Pods/RxSwift/RxSwift/SwiftSupport/SwiftSupport.swift /Users/babaiholdings/Documents/AlchemintWalletiOS/AlchemintProject/Pods/RxSwift/RxSwift/Observables/TakeLast.swift /Users/babaiholdings/Documents/AlchemintWalletiOS/AlchemintProject/Pods/RxSwift/RxSwift/Observables/Multicast.swift /Users/babaiholdings/Documents/AlchemintWalletiOS/AlchemintProject/Pods/RxSwift/RxSwift/Observables/CombineLatest.swift /Users/babaiholdings/Documents/AlchemintWalletiOS/AlchemintProject/Pods/RxSwift/RxSwift/Observables/First.swift /Users/babaiholdings/Documents/AlchemintWalletiOS/AlchemintProject/Pods/RxSwift/RxSwift/Observables/Just.swift /Users/babaiholdings/Documents/AlchemintWalletiOS/AlchemintProject/Pods/RxSwift/RxSwift/Observables/Timeout.swift /Users/babaiholdings/Documents/AlchemintWalletiOS/AlchemintProject/Pods/RxSwift/RxSwift/Observables/Window.swift /Users/babaiholdings/Documents/AlchemintWalletiOS/AlchemintProject/Pods/RxSwift/RxSwift/Extensions/Bag+Rx.swift /Users/babaiholdings/Documents/AlchemintWalletiOS/AlchemintProject/Pods/RxSwift/RxSwift/Extensions/String+Rx.swift /Users/babaiholdings/Documents/AlchemintWalletiOS/AlchemintProject/Pods/RxSwift/RxSwift/Rx.swift /Users/babaiholdings/Documents/AlchemintWalletiOS/AlchemintProject/Pods/RxSwift/RxSwift/RxMutableBox.swift /Users/babaiholdings/Documents/AlchemintWalletiOS/AlchemintProject/Pods/RxSwift/Platform/Platform.Linux.swift /Users/babaiholdings/Documents/AlchemintWalletiOS/AlchemintProject/Pods/RxSwift/RxSwift/Observables/GroupBy.swift /Users/babaiholdings/Documents/AlchemintWalletiOS/AlchemintProject/Pods/RxSwift/RxSwift/Observables/Delay.swift /Users/babaiholdings/Documents/AlchemintWalletiOS/AlchemintProject/Pods/RxSwift/RxSwift/Observables/ToArray.swift /Users/babaiholdings/Documents/AlchemintWalletiOS/AlchemintProject/Pods/RxSwift/RxSwift/Traits/PrimitiveSequence+Zip+arity.swift /Users/babaiholdings/Documents/AlchemintWalletiOS/AlchemintProject/Pods/RxSwift/RxSwift/Observables/Zip+arity.swift /Users/babaiholdings/Documents/AlchemintWalletiOS/AlchemintProject/Pods/RxSwift/RxSwift/Observables/CombineLatest+arity.swift /Users/babaiholdings/Documents/AlchemintWalletiOS/AlchemintProject/Pods/RxSwift/RxSwift/Observables/Empty.swift /Users/babaiholdings/Documents/AlchemintWalletiOS/AlchemintProject/Pods/RxSwift/RxSwift/Observables/SwitchIfEmpty.swift /Users/babaiholdings/Documents/AlchemintWalletiOS/AlchemintProject/Pods/RxSwift/RxSwift/Observables/DefaultIfEmpty.swift /Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/lib/swift/iphonesimulator/x86_64/Dispatch.apinotesc /Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/lib/swift/iphonesimulator/x86_64/ObjectiveC.swiftmodule /Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/lib/swift/iphonesimulator/x86_64/CoreImage.swiftmodule /Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/lib/swift/iphonesimulator/x86_64/QuartzCore.swiftmodule /Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/lib/swift/iphonesimulator/x86_64/Dispatch.swiftmodule /Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/lib/swift/iphonesimulator/x86_64/Metal.swiftmodule /Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/lib/swift/iphonesimulator/x86_64/Darwin.swiftmodule /Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/lib/swift/iphonesimulator/x86_64/Foundation.swiftmodule /Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/lib/swift/iphonesimulator/x86_64/CoreFoundation.swiftmodule /Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/lib/swift/iphonesimulator/x86_64/CoreGraphics.swiftmodule /Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/lib/swift/iphonesimulator/x86_64/Swift.swiftmodule /Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/lib/swift/iphonesimulator/x86_64/UIKit.swiftmodule /Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/lib/swift/iphonesimulator/x86_64/SwiftOnoneSupport.swiftmodule /Users/babaiholdings/Documents/AlchemintWalletiOS/AlchemintProject/Pods/Target\ Support\ Files/RxSwift/RxSwift-umbrella.h /Users/babaiholdings/Documents/AlchemintWalletiOS/AlchemintProject/Build/Intermediates.noindex/Pods.build/Debug-iphonesimulator/RxSwift.build/unextended-module.modulemap /Applications/Xcode.app/Contents/Developer/Platforms/iPhoneSimulator.platform/Developer/SDKs/iPhoneSimulator11.4.sdk/usr/include/objc/ObjectiveC.apinotes /Applications/Xcode.app/Contents/Developer/Platforms/iPhoneSimulator.platform/Developer/SDKs/iPhoneSimulator11.4.sdk/System/Library/Frameworks/OpenGLES.framework/Headers/OpenGLES.apinotes /Applications/Xcode.app/Contents/Developer/Platforms/iPhoneSimulator.platform/Developer/SDKs/iPhoneSimulator11.4.sdk/System/Library/Frameworks/CoreImage.framework/Headers/CoreImage.apinotes /Applications/Xcode.app/Contents/Developer/Platforms/iPhoneSimulator.platform/Developer/SDKs/iPhoneSimulator11.4.sdk/System/Library/Frameworks/QuartzCore.framework/Headers/QuartzCore.apinotes /Applications/Xcode.app/Contents/Developer/Platforms/iPhoneSimulator.platform/Developer/SDKs/iPhoneSimulator11.4.sdk/System/Library/Frameworks/Metal.framework/Headers/Metal.apinotes /Applications/Xcode.app/Contents/Developer/Platforms/iPhoneSimulator.platform/Developer/SDKs/iPhoneSimulator11.4.sdk/usr/include/Darwin.apinotes /Applications/Xcode.app/Contents/Developer/Platforms/iPhoneSimulator.platform/Developer/SDKs/iPhoneSimulator11.4.sdk/System/Library/Frameworks/Foundation.framework/Headers/Foundation.apinotes /Applications/Xcode.app/Contents/Developer/Platforms/iPhoneSimulator.platform/Developer/SDKs/iPhoneSimulator11.4.sdk/System/Library/Frameworks/CoreGraphics.framework/Headers/CoreGraphics.apinotes /Applications/Xcode.app/Contents/Developer/Platforms/iPhoneSimulator.platform/Developer/SDKs/iPhoneSimulator11.4.sdk/System/Library/Frameworks/UIKit.framework/Headers/UIKit.apinotes /Applications/Xcode.app/Contents/Developer/Platforms/iPhoneSimulator.platform/Developer/SDKs/iPhoneSimulator11.4.sdk/System/Library/Frameworks/CoreText.framework/Headers/CoreText.apinotes
| D |
the quality of being near to the true value
(mathematics) the number of significant figures given in a number
| D |
/root/pkg/portex_pkg/simulation/service/target/release/build/memchr-3ec4b1707c908337/build_script_build-3ec4b1707c908337: /root/.cargo/registry/src/github.com-1ecc6299db9ec823/memchr-2.3.0/build.rs
/root/pkg/portex_pkg/simulation/service/target/release/build/memchr-3ec4b1707c908337/build_script_build-3ec4b1707c908337.d: /root/.cargo/registry/src/github.com-1ecc6299db9ec823/memchr-2.3.0/build.rs
/root/.cargo/registry/src/github.com-1ecc6299db9ec823/memchr-2.3.0/build.rs:
| D |
FUNC VOID CHECKPOINT ()
{
if (hero.aivar[AIV_Loadgame] == FALSE)
{
Snd_Play ("JIBOTELEPORT");
};
if (Lore == TRUE)
&& (CurrentLevel == LEVEL01_ZEN)
{
Lore = FALSE;
Wld_SendTrigger ("LORE01");
};
if (Lore_R == TRUE)
&& (CurrentLevel == LEVEL03_ZEN)
{
Lore_R = FALSE;
Wld_SendTrigger ("LORE01");
};
if (Check07 == TRUE)
{
AI_Teleport (hero, "CHECK07");
if (hero.aivar[AIV_Loadgame] == TRUE)
&& (CurrentLevel != START_ZEN)
{
TimeCounter_Real += 10;
TimeCounter_Sek += 10;
PrintScreen ("10 Sekunden Lade-Malus!", -1, YPOS_LevelUp, FONT_Screen, 1);
};
}
else if (Check06 == TRUE)
{
AI_Teleport (hero, "CHECK06");
if (hero.aivar[AIV_Loadgame] == TRUE)
&& (CurrentLevel != START_ZEN)
{
TimeCounter_Real += 10;
TimeCounter_Sek += 10;
PrintScreen ("10 Sekunden Lade-Malus!", -1, YPOS_LevelUp, FONT_Screen, 1);
};
}
else if (Check05 == TRUE)
{
AI_Teleport (hero, "CHECK05");
if (hero.aivar[AIV_Loadgame] == TRUE)
&& (CurrentLevel != START_ZEN)
{
TimeCounter_Real += 10;
TimeCounter_Sek += 10;
PrintScreen ("10 Sekunden Lade-Malus!", -1, YPOS_LevelUp, FONT_Screen, 1);
};
}
else if (Check04 == TRUE)
{
AI_Teleport (hero, "CHECK04");
if (hero.aivar[AIV_Loadgame] == TRUE)
&& (CurrentLevel != START_ZEN)
{
TimeCounter_Real += 10;
TimeCounter_Sek += 10;
PrintScreen ("10 Sekunden Lade-Malus!", -1, YPOS_LevelUp, FONT_Screen, 1);
};
}
else if (Check03 == TRUE)
{
AI_Teleport (hero, "CHECK03");
if (hero.aivar[AIV_Loadgame] == TRUE)
&& (CurrentLevel != START_ZEN)
{
TimeCounter_Real += 10;
TimeCounter_Sek += 10;
PrintScreen ("10 Sekunden Lade-Malus!", -1, YPOS_LevelUp, FONT_Screen, 1);
};
}
else if (Check02 == TRUE)
{
AI_Teleport (hero, "CHECK02");
if (hero.aivar[AIV_Loadgame] == TRUE)
&& (CurrentLevel != START_ZEN)
{
TimeCounter_Real += 10;
TimeCounter_Sek += 10;
PrintScreen ("10 Sekunden Lade-Malus!", -1, YPOS_LevelUp, FONT_Screen, 1);
};
}
else if (Check01 == TRUE)
{
AI_Teleport (hero, "CHECK01");
if (hero.aivar[AIV_Loadgame] == TRUE)
&& (CurrentLevel != START_ZEN)
{
TimeCounter_Real += 10;
TimeCounter_Sek += 10;
PrintScreen ("10 Sekunden Lade-Malus!", -1, YPOS_LevelUp, FONT_Screen, 1);
};
}
else
{
AI_Teleport (hero, "START");
};
if (CurrentLevel == LEVEL06_ZEN)
{
Mdl_ApplyOverlayMDS (hero, "HUMANS_ACROBATIC.MDS");
Acrobat = 1;
};
if (CurrentLevel == LEVEL08_ZEN)
{
Mdl_ApplyOverlayMDS (hero, "HUMANS_ACROBATIC.MDS");
Acrobat = 1;
};
}; | D |
instance BDT_1024_MALETHSBANDIT(NPC_DEFAULT)
{
name[0] = "Главарь разбойников";
guild = GIL_BDT;
id = 1024;
voice = 13;
flags = 0;
npctype = NPCTYPE_AMBIENT;
b_setattributestochapter(self,5);
fight_tactic = FAI_HUMAN_STRONG;
EquipItem(self,itmw_1h_sld_axe);
EquipItem(self,itrw_mil_crossbow);
b_createambientinv(self);
b_setnpcvisual(self,MALE,"Hum_Head_FatBald",FACE_P_TOUGHBALD_NEK,BODYTEX_P,itar_bdt_h);
Mdl_SetModelFatness(self,2);
Mdl_ApplyOverlayMds(self,"Humans_Relaxed.mds");
b_givenpctalents(self);
b_setfightskills(self,50);
start_aistate = zs_bandit;
};
| D |
an unknown and unpredictable phenomenon that causes an event to result one way rather than another
a large amount of wealth or prosperity
an unknown and unpredictable phenomenon that leads to a favorable outcome
your overall circumstances or condition in life (including everything that happens to you
| D |
/**
<script type="text/javascript">inhibitQuickIndex = 1</script>
$(BOOKTABLE ,
$(TR $(TH Category) $(TH Functions)
)
$(TR $(TDNW Template API) $(TD $(MYREF MD5)
)
)
$(TR $(TDNW OOP API) $(TD $(MYREF MD5Digest))
)
$(TR $(TDNW Helpers) $(TD $(MYREF md5Of))
)
)
* Computes MD5 hashes of arbitrary data. MD5 hashes are 16 byte quantities that are like a
* checksum or CRC, but are more robust.
*
* This module conforms to the APIs defined in $(D std.digest.digest). To understand the
* differences between the template and the OOP API, see $(D std.digest.digest).
*
* This module publicly imports $(D std.digest.digest) and can be used as a stand-alone
* module.
*
* License: <a href="http://www.boost.org/LICENSE_1_0.txt">Boost License 1.0</a>
*
* CTFE:
* Digests do not work in CTFE
*
* Authors:
* Piotr Szturmaj, Kai Nacke, Johannes Pfau $(BR)
* The routines and algorithms are derived from the $(I RSA Data Security, Inc. MD5 Message-Digest Algorithm).
*
* References:
* $(LINK2 http://en.wikipedia.org/wiki/Md5, Wikipedia on MD5)
*
* Source: $(PHOBOSSRC std/digest/_md.d)
*
* Macros:
* WIKI = Phobos/StdMd5
* MYREF = <font face='Consolas, "Bitstream Vera Sans Mono", "Andale Mono", Monaco, "DejaVu Sans Mono", "Lucida Console", monospace'><a href="#$1">$1</a> </font>
*/
/* md5.d - RSA Data Security, Inc., MD5 message-digest algorithm
* Derived from the RSA Data Security, Inc. MD5 Message-Digest Algorithm.
*/
module std.digest.md;
import std.bitmanip, std.exception, std.string;
public import std.digest.digest;
///
unittest
{
//Template API
import std.digest.md;
//Feeding data
ubyte[1024] data;
MD5 md5;
md5.start();
md5.put(data[]);
md5.start(); //Start again
md5.put(data[]);
auto hash = md5.finish();
}
///
unittest
{
//OOP API
import std.digest.md;
auto md5 = new MD5Digest();
ubyte[] hash = md5.digest("abc");
assert(toHexString(hash) == "900150983CD24FB0D6963F7D28E17F72");
//Feeding data
ubyte[1024] data;
md5.put(data[]);
md5.reset(); //Start again
md5.put(data[]);
hash = md5.finish();
}
//rotateLeft rotates x left n bits
private nothrow pure uint rotateLeft(uint x, uint n)
{
// With recently added optimization to DMD (commit 32ea0206 at 07/28/11), this is translated to rol.
// No assembler required.
return (x << n) | (x >> (32-n));
}
/**
* Template API MD5 implementation.
* See $(D std.digest.digest) for differences between template and OOP API.
*/
struct MD5
{
private:
// magic initialization constants
uint[4] _state = [0x67452301,0xefcdab89,0x98badcfe,0x10325476]; // state (ABCD)
ulong _count; //number of bits, modulo 2^64
ubyte[64] _buffer; // input buffer
static immutable ubyte[64] _padding =
[
0x80, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0
];
// F, G, H and I are basic MD5 functions
static nothrow pure
{
uint F(uint x, uint y, uint z) { return (x & y) | (~x & z); }
uint G(uint x, uint y, uint z) { return (x & z) | (y & ~z); }
uint H(uint x, uint y, uint z) { return x ^ y ^ z; }
uint I(uint x, uint y, uint z) { return y ^ (x | ~z); }
}
/*
* FF, GG, HH, and II transformations for rounds 1, 2, 3, and 4.
* Rotation is separate from addition to prevent recomputation.
*/
static nothrow pure void FF(ref uint a, uint b, uint c, uint d, uint x, uint s, uint ac)
{
a += F (b, c, d) + x + ac;
a = rotateLeft(a, s);
a += b;
}
static nothrow pure void GG(ref uint a, uint b, uint c, uint d, uint x, uint s, uint ac)
{
a += G (b, c, d) + x + ac;
a = rotateLeft(a, s);
a += b;
}
static nothrow pure void HH(ref uint a, uint b, uint c, uint d, uint x, uint s, uint ac)
{
a += H (b, c, d) + x + ac;
a = rotateLeft(a, s);
a += b;
}
static nothrow pure void II(ref uint a, uint b, uint c, uint d, uint x, uint s, uint ac)
{
a += I (b, c, d) + x + ac;
a = rotateLeft(a, s);
a += b;
}
/*
* MD5 basic transformation. Transforms state based on block.
*/
//Constants for MD5Transform routine.
enum
{
S11 = 7,
S12 = 12,
S13 = 17,
S14 = 22,
S21 = 5,
S22 = 9,
S23 = 14,
S24 = 20,
S31 = 4,
S32 = 11,
S33 = 16,
S34 = 23,
S41 = 6,
S42 = 10,
S43 = 15,
S44 = 21,
}
private nothrow pure void transform(const(ubyte[64])* block)
{
uint a = _state[0],
b = _state[1],
c = _state[2],
d = _state[3];
uint[16] x = void;
version(BigEndian)
{
for(size_t i = 0; i < 16; i++)
{
x[i] = littleEndianToNative!uint(*cast(ubyte[4]*)&(*block)[i*4]);
}
}
else
{
(cast(ubyte*)x.ptr)[0 .. 64] = (cast(ubyte*)block)[0 .. 64];
}
//Round 1
FF (a, b, c, d, x[ 0], S11, 0xd76aa478); /* 1 */
FF (d, a, b, c, x[ 1], S12, 0xe8c7b756); /* 2 */
FF (c, d, a, b, x[ 2], S13, 0x242070db); /* 3 */
FF (b, c, d, a, x[ 3], S14, 0xc1bdceee); /* 4 */
FF (a, b, c, d, x[ 4], S11, 0xf57c0faf); /* 5 */
FF (d, a, b, c, x[ 5], S12, 0x4787c62a); /* 6 */
FF (c, d, a, b, x[ 6], S13, 0xa8304613); /* 7 */
FF (b, c, d, a, x[ 7], S14, 0xfd469501); /* 8 */
FF (a, b, c, d, x[ 8], S11, 0x698098d8); /* 9 */
FF (d, a, b, c, x[ 9], S12, 0x8b44f7af); /* 10 */
FF (c, d, a, b, x[10], S13, 0xffff5bb1); /* 11 */
FF (b, c, d, a, x[11], S14, 0x895cd7be); /* 12 */
FF (a, b, c, d, x[12], S11, 0x6b901122); /* 13 */
FF (d, a, b, c, x[13], S12, 0xfd987193); /* 14 */
FF (c, d, a, b, x[14], S13, 0xa679438e); /* 15 */
FF (b, c, d, a, x[15], S14, 0x49b40821); /* 16 */
//Round 2
GG (a, b, c, d, x[ 1], S21, 0xf61e2562); /* 17 */
GG (d, a, b, c, x[ 6], S22, 0xc040b340); /* 18 */
GG (c, d, a, b, x[11], S23, 0x265e5a51); /* 19 */
GG (b, c, d, a, x[ 0], S24, 0xe9b6c7aa); /* 20 */
GG (a, b, c, d, x[ 5], S21, 0xd62f105d); /* 21 */
GG (d, a, b, c, x[10], S22, 0x2441453); /* 22 */
GG (c, d, a, b, x[15], S23, 0xd8a1e681); /* 23 */
GG (b, c, d, a, x[ 4], S24, 0xe7d3fbc8); /* 24 */
GG (a, b, c, d, x[ 9], S21, 0x21e1cde6); /* 25 */
GG (d, a, b, c, x[14], S22, 0xc33707d6); /* 26 */
GG (c, d, a, b, x[ 3], S23, 0xf4d50d87); /* 27 */
GG (b, c, d, a, x[ 8], S24, 0x455a14ed); /* 28 */
GG (a, b, c, d, x[13], S21, 0xa9e3e905); /* 29 */
GG (d, a, b, c, x[ 2], S22, 0xfcefa3f8); /* 30 */
GG (c, d, a, b, x[ 7], S23, 0x676f02d9); /* 31 */
GG (b, c, d, a, x[12], S24, 0x8d2a4c8a); /* 32 */
//Round 3
HH (a, b, c, d, x[ 5], S31, 0xfffa3942); /* 33 */
HH (d, a, b, c, x[ 8], S32, 0x8771f681); /* 34 */
HH (c, d, a, b, x[11], S33, 0x6d9d6122); /* 35 */
HH (b, c, d, a, x[14], S34, 0xfde5380c); /* 36 */
HH (a, b, c, d, x[ 1], S31, 0xa4beea44); /* 37 */
HH (d, a, b, c, x[ 4], S32, 0x4bdecfa9); /* 38 */
HH (c, d, a, b, x[ 7], S33, 0xf6bb4b60); /* 39 */
HH (b, c, d, a, x[10], S34, 0xbebfbc70); /* 40 */
HH (a, b, c, d, x[13], S31, 0x289b7ec6); /* 41 */
HH (d, a, b, c, x[ 0], S32, 0xeaa127fa); /* 42 */
HH (c, d, a, b, x[ 3], S33, 0xd4ef3085); /* 43 */
HH (b, c, d, a, x[ 6], S34, 0x4881d05); /* 44 */
HH (a, b, c, d, x[ 9], S31, 0xd9d4d039); /* 45 */
HH (d, a, b, c, x[12], S32, 0xe6db99e5); /* 46 */
HH (c, d, a, b, x[15], S33, 0x1fa27cf8); /* 47 */
HH (b, c, d, a, x[ 2], S34, 0xc4ac5665); /* 48 */
//Round 4
II (a, b, c, d, x[ 0], S41, 0xf4292244); /* 49 */
II (d, a, b, c, x[ 7], S42, 0x432aff97); /* 50 */
II (c, d, a, b, x[14], S43, 0xab9423a7); /* 51 */
II (b, c, d, a, x[ 5], S44, 0xfc93a039); /* 52 */
II (a, b, c, d, x[12], S41, 0x655b59c3); /* 53 */
II (d, a, b, c, x[ 3], S42, 0x8f0ccc92); /* 54 */
II (c, d, a, b, x[10], S43, 0xffeff47d); /* 55 */
II (b, c, d, a, x[ 1], S44, 0x85845dd1); /* 56 */
II (a, b, c, d, x[ 8], S41, 0x6fa87e4f); /* 57 */
II (d, a, b, c, x[15], S42, 0xfe2ce6e0); /* 58 */
II (c, d, a, b, x[ 6], S43, 0xa3014314); /* 59 */
II (b, c, d, a, x[13], S44, 0x4e0811a1); /* 60 */
II (a, b, c, d, x[ 4], S41, 0xf7537e82); /* 61 */
II (d, a, b, c, x[11], S42, 0xbd3af235); /* 62 */
II (c, d, a, b, x[ 2], S43, 0x2ad7d2bb); /* 63 */
II (b, c, d, a, x[ 9], S44, 0xeb86d391); /* 64 */
_state[0] += a;
_state[1] += b;
_state[2] += c;
_state[3] += d;
//Zeroize sensitive information.
x[] = 0;
}
public:
/**
* Use this to feed the digest with data.
* Also implements the $(XREF range, OutputRange) interface for $(D ubyte) and
* $(D const(ubyte)[]).
*
* Examples:
* ----
* MD5 dig;
* dig.put(cast(ubyte)0); //single ubyte
* dig.put(cast(ubyte)0, cast(ubyte)0); //variadic
* ubyte[10] buf;
* dig.put(buf); //buffer
* ----
*/
@trusted nothrow pure void put(scope const(ubyte)[] data...)
{
uint i, index, partLen;
auto inputLen = data.length;
//Compute number of bytes mod 64
index = (cast(uint)_count >> 3) & (64 - 1);
//Update number of bits
_count += inputLen * 8;
partLen = 64 - index;
//Transform as many times as possible
if (inputLen >= partLen)
{
(&_buffer[index])[0 .. partLen] = data.ptr[0 .. partLen];
transform(&_buffer);
for(i = partLen; i + 63 < inputLen; i += 64)
{
transform(cast(const(ubyte[64])*)(data[i .. i + 64].ptr));
}
index = 0;
}
else
{
i = 0;
}
/* Buffer remaining input */
if (inputLen - i)
(&_buffer[index])[0 .. inputLen-i] = (&data[i])[0 .. inputLen-i];
}
/**
* Used to (re)initialize the MD5 digest.
*
* Note:
* For this MD5 Digest implementation calling start after default construction
* is not necessary. Calling start is only necessary to reset the Digest.
*
* Generic code which deals with different Digest types should always call start though.
*
* Examples:
* --------
* MD5 digest;
* //digest.start(); //Not necessary
* digest.put(0);
* --------
*/
@trusted nothrow pure void start()
{
this = MD5.init;
}
/**
* Returns the finished MD5 hash. This also calls $(LREF start) to
* reset the internal state.
*/
@trusted nothrow pure ubyte[16] finish()
{
ubyte[16] data = void;
ubyte[8] bits = void;
uint index, padLen;
//Save number of bits
bits[0 .. 8] = nativeToLittleEndian(_count)[];
//Pad out to 56 mod 64
index = (cast(uint)_count >> 3) & (64 - 1);
padLen = (index < 56) ? (56 - index) : (120 - index);
put(_padding[0 .. padLen]);
//Append length (before padding)
put(bits);
//Store state in digest
data[0 .. 4] = nativeToLittleEndian(_state[0])[];
data[4 .. 8] = nativeToLittleEndian(_state[1])[];
data[8 .. 12] = nativeToLittleEndian(_state[2])[];
data[12 .. 16] = nativeToLittleEndian(_state[3])[];
/* Zeroize sensitive information. */
start();
return data;
}
///
unittest
{
//Simple example
MD5 hash;
hash.start();
hash.put(cast(ubyte)0);
ubyte[16] result = hash.finish();
}
}
///
unittest
{
//Simple example, hashing a string using md5Of helper function
ubyte[16] hash = md5Of("abc");
//Let's get a hash string
assert(toHexString(hash) == "900150983CD24FB0D6963F7D28E17F72");
}
///
unittest
{
//Using the basic API
MD5 hash;
hash.start();
ubyte[1024] data;
//Initialize data here...
hash.put(data);
ubyte[16] result = hash.finish();
}
///
unittest
{
//Let's use the template features:
void doSomething(T)(ref T hash) if(isDigest!T)
{
hash.put(cast(ubyte)0);
}
MD5 md5;
md5.start();
doSomething(md5);
assert(toHexString(md5.finish()) == "93B885ADFE0DA089CDF634904FD59F71");
}
unittest
{
assert(isDigest!MD5);
}
unittest
{
import std.range;
ubyte[16] digest;
MD5 md5;
md5.put(cast(ubyte[])"abcdef");
md5.start();
md5.put(cast(ubyte[])"");
assert(md5.finish() == cast(ubyte[])x"d41d8cd98f00b204e9800998ecf8427e");
digest = md5Of("");
assert(digest == cast(ubyte[])x"d41d8cd98f00b204e9800998ecf8427e");
digest = md5Of("a");
assert(digest == cast(ubyte[])x"0cc175b9c0f1b6a831c399e269772661");
digest = md5Of("abc");
assert(digest == cast(ubyte[])x"900150983cd24fb0d6963f7d28e17f72");
digest = md5Of("abcdbcdecdefdefgefghfghighijhijkijkljklmklmnlmnomnopnopq");
assert(digest == cast(ubyte[])x"8215ef0796a20bcaaae116d3876c664a");
digest = md5Of("message digest");
assert(digest == cast(ubyte[])x"f96b697d7cb7938d525a2f31aaf161d0");
digest = md5Of("abcdefghijklmnopqrstuvwxyz");
assert(digest == cast(ubyte[])x"c3fcd3d76192e4007dfb496cca67e13b");
digest = md5Of("ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789");
assert(digest == cast(ubyte[])x"d174ab98d277d9f5a5611c2c9f419d9f");
digest = md5Of("1234567890123456789012345678901234567890"~
"1234567890123456789012345678901234567890");
assert(digest == cast(ubyte[])x"57edf4a22be3c955ac49da2e2107b67a");
assert(toHexString(cast(ubyte[16])x"c3fcd3d76192e4007dfb496cca67e13b")
== "C3FCD3D76192E4007DFB496CCA67E13B");
ubyte[] onemilliona = new ubyte[1000000];
onemilliona[] = 'a';
digest = md5Of(onemilliona);
assert(digest == cast(ubyte[])x"7707D6AE4E027C70EEA2A935C2296F21");
auto oneMillionRange = repeat!ubyte(cast(ubyte)'a', 1000000);
digest = md5Of(oneMillionRange);
assert(digest == cast(ubyte[])x"7707D6AE4E027C70EEA2A935C2296F21");
}
/**
* This is a convenience alias for $(XREF digest.digest, digest) using the
* MD5 implementation.
*/
//simple alias doesn't work here, hope this gets inlined...
auto md5Of(T...)(T data)
{
return digest!(MD5, T)(data);
}
///
unittest
{
ubyte[16] hash = md5Of("abc");
assert(hash == digest!MD5("abc"));
}
/**
* OOP API MD5 implementation.
* See $(D std.digest.digest) for differences between template and OOP API.
*
* This is an alias for $(XREF digest.digest, WrapperDigest)!MD5, see
* $(XREF digest.digest, WrapperDigest) for more information.
*/
alias WrapperDigest!MD5 MD5Digest;
///
unittest
{
//Simple example, hashing a string using Digest.digest helper function
auto md5 = new MD5Digest();
ubyte[] hash = md5.digest("abc");
//Let's get a hash string
assert(toHexString(hash) == "900150983CD24FB0D6963F7D28E17F72");
}
///
unittest
{
//Let's use the OOP features:
void test(Digest dig)
{
dig.put(cast(ubyte)0);
}
auto md5 = new MD5Digest();
test(md5);
//Let's use a custom buffer:
ubyte[16] buf;
ubyte[] result = md5.finish(buf[]);
assert(toHexString(result) == "93B885ADFE0DA089CDF634904FD59F71");
}
unittest
{
auto md5 = new MD5Digest();
md5.put(cast(ubyte[])"abcdef");
md5.reset();
md5.put(cast(ubyte[])"");
assert(md5.finish() == cast(ubyte[])x"d41d8cd98f00b204e9800998ecf8427e");
md5.put(cast(ubyte[])"abcdefghijklmnopqrstuvwxyz");
ubyte[20] result;
auto result2 = md5.finish(result[]);
assert(result[0 .. 16] == result2 && result2 == cast(ubyte[])x"c3fcd3d76192e4007dfb496cca67e13b");
debug
assertThrown!Error(md5.finish(result[0 .. 15]));
assert(md5.length == 16);
assert(md5.digest("") == cast(ubyte[])x"d41d8cd98f00b204e9800998ecf8427e");
assert(md5.digest("a") == cast(ubyte[])x"0cc175b9c0f1b6a831c399e269772661");
assert(md5.digest("abc") == cast(ubyte[])x"900150983cd24fb0d6963f7d28e17f72");
assert(md5.digest("abcdbcdecdefdefgefghfghighijhijkijkljklmklmnlmnomnopnopq")
== cast(ubyte[])x"8215ef0796a20bcaaae116d3876c664a");
assert(md5.digest("message digest") == cast(ubyte[])x"f96b697d7cb7938d525a2f31aaf161d0");
assert(md5.digest("abcdefghijklmnopqrstuvwxyz")
== cast(ubyte[])x"c3fcd3d76192e4007dfb496cca67e13b");
assert(md5.digest("ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789")
== cast(ubyte[])x"d174ab98d277d9f5a5611c2c9f419d9f");
assert(md5.digest("1234567890123456789012345678901234567890",
"1234567890123456789012345678901234567890")
== cast(ubyte[])x"57edf4a22be3c955ac49da2e2107b67a");
}
| D |
module hunt.http.codec.websocket.frame.TextFrame;
import hunt.http.codec.websocket.frame.DataFrame;
import hunt.http.codec.websocket.frame.AbstractWebSocketFrame;
import hunt.http.WebSocketCommon;
import hunt.http.WebSocketFrame;
import hunt.io.ByteBuffer;
import hunt.io.BufferUtils;
import hunt.text.Common;
class TextFrame : DataFrame {
this() {
super(OpCode.TEXT);
}
override
WebSocketFrameType getType() {
return getOpCode() == OpCode.CONTINUATION ? WebSocketFrameType.CONTINUATION : WebSocketFrameType.TEXT;
}
TextFrame setPayload(string str) {
// FIXME: Needing refactor or cleanup -@zhangxueping at 2019-10-19T13:14:09+08:00
// copy or not?
setPayload(BufferUtils.toBuffer(cast(byte[])(str.dup)));
return this;
}
alias setPayload = AbstractWebSocketFrame.setPayload;
override string getPayloadAsUTF8() {
if (data is null) {
return null;
}
return BufferUtils.toString(data);
}
}
| D |
a twelve-sided polygon
| D |
import std.stdio;
class Resource {
this(string name) {
writefln("open %s", name);
this.name = name;
}
void close() {
writefln("close %s", name);
}
string name;
}
Resource prepOut(string outName, string[] prepNames) {
auto writer = new Resource(outName);
scope(failure) writer.close();
foreach (name; prepNames) {
auto reader = new Resource(name);
scope(exit) reader.close();
// scope(success) writeln("Hi!");
// throw new Error("WELCOME TO YOUR DOOM!!");
writefln("use %s", name);
}
return writer;
}
void main() {
auto writer = prepOut("out", ["a", "b"]);
scope(exit) writer.close();
writeln("use out");
}
| D |
/Users/memo/Desktop/MiraclePill/DerivedData/MiraclePill/Build/Intermediates/MiraclePill.build/Debug-iphonesimulator/MiraclePill.build/Objects-normal/x86_64/AppDelegate.o : /Users/memo/Desktop/MiraclePill/MiraclePill/ViewController.swift /Users/memo/Desktop/MiraclePill/MiraclePill/AppDelegate.swift /Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/lib/swift/iphonesimulator/x86_64/Swift.swiftmodule /Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/lib/swift/iphonesimulator/x86_64/SwiftOnoneSupport.swiftmodule /Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/lib/swift/iphonesimulator/x86_64/UIKit.swiftmodule /Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/lib/swift/iphonesimulator/x86_64/Foundation.swiftmodule /Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/lib/swift/iphonesimulator/x86_64/Darwin.swiftmodule /Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/lib/swift/iphonesimulator/x86_64/Dispatch.swiftmodule /Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/lib/swift/iphonesimulator/x86_64/ObjectiveC.swiftmodule /Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/lib/swift/iphonesimulator/x86_64/CoreGraphics.swiftmodule /Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/lib/swift/iphonesimulator/x86_64/QuartzCore.swiftmodule /Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/lib/swift/iphonesimulator/x86_64/CoreImage.swiftmodule
/Users/memo/Desktop/MiraclePill/DerivedData/MiraclePill/Build/Intermediates/MiraclePill.build/Debug-iphonesimulator/MiraclePill.build/Objects-normal/x86_64/AppDelegate~partial.swiftmodule : /Users/memo/Desktop/MiraclePill/MiraclePill/ViewController.swift /Users/memo/Desktop/MiraclePill/MiraclePill/AppDelegate.swift /Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/lib/swift/iphonesimulator/x86_64/Swift.swiftmodule /Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/lib/swift/iphonesimulator/x86_64/SwiftOnoneSupport.swiftmodule /Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/lib/swift/iphonesimulator/x86_64/UIKit.swiftmodule /Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/lib/swift/iphonesimulator/x86_64/Foundation.swiftmodule /Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/lib/swift/iphonesimulator/x86_64/Darwin.swiftmodule /Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/lib/swift/iphonesimulator/x86_64/Dispatch.swiftmodule /Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/lib/swift/iphonesimulator/x86_64/ObjectiveC.swiftmodule /Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/lib/swift/iphonesimulator/x86_64/CoreGraphics.swiftmodule /Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/lib/swift/iphonesimulator/x86_64/QuartzCore.swiftmodule /Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/lib/swift/iphonesimulator/x86_64/CoreImage.swiftmodule
/Users/memo/Desktop/MiraclePill/DerivedData/MiraclePill/Build/Intermediates/MiraclePill.build/Debug-iphonesimulator/MiraclePill.build/Objects-normal/x86_64/AppDelegate~partial.swiftdoc : /Users/memo/Desktop/MiraclePill/MiraclePill/ViewController.swift /Users/memo/Desktop/MiraclePill/MiraclePill/AppDelegate.swift /Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/lib/swift/iphonesimulator/x86_64/Swift.swiftmodule /Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/lib/swift/iphonesimulator/x86_64/SwiftOnoneSupport.swiftmodule /Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/lib/swift/iphonesimulator/x86_64/UIKit.swiftmodule /Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/lib/swift/iphonesimulator/x86_64/Foundation.swiftmodule /Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/lib/swift/iphonesimulator/x86_64/Darwin.swiftmodule /Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/lib/swift/iphonesimulator/x86_64/Dispatch.swiftmodule /Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/lib/swift/iphonesimulator/x86_64/ObjectiveC.swiftmodule /Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/lib/swift/iphonesimulator/x86_64/CoreGraphics.swiftmodule /Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/lib/swift/iphonesimulator/x86_64/QuartzCore.swiftmodule /Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/lib/swift/iphonesimulator/x86_64/CoreImage.swiftmodule
| D |
// ************************************************************
// EXIT
// ************************************************************
instance DIA_DiegoOw_EXIT(C_INFO)
{
npc = PC_ThiefOw;
nr = 999;
condition = DIA_DiegoOw_EXIT_Condition;
information = DIA_DiegoOw_EXIT_Info;
permanent = TRUE;
description = DIALOG_ENDE;
};
func INT DIA_DiegoOw_EXIT_Condition()
{
return TRUE;
};
func VOID DIA_DiegoOw_EXIT_Info()
{
AI_StopProcessInfos (self);
};
//******************************************************************
// Begrüssung
//******************************************************************
INSTANCE DIA_DiegoOw_Hallo(C_INFO)
{
npc = PC_ThiefOW;
nr = 1;
condition = DIA_DiegoOw_Hallo_Condition;
information = DIA_DiegoOw_Hallo_Info;
Important = TRUE;
};
FUNC INT DIA_DiegoOw_Hallo_Condition()
{
return TRUE;
};
FUNC VOID DIA_DiegoOw_Hallo_Info()
{
AI_Output (self ,other,"DIA_DiegoOw_Hallo_11_00");//Hey, ich dachte, du wärst tot.
AI_Output (other ,self,"DIA_DiegoOw_Hallo_15_01");//Ja ... war ich auch.
AI_Output (other ,self,"DIA_DiegoOw_Hallo_15_02");//Jetzt bin ich wieder hier und suche nach Beweisen für die Ankunft der Drachen.
AI_Output (self ,other,"DIA_DiegoOw_Hallo_11_03");//Für wen machst du das?
AI_Output (other ,self,"DIA_DiegoOw_Hallo_15_04");//Ich arbeite für Lord Hagen. Mit Hilfe der Paladine können die Drachen aufgehalten werden.
AI_Output (self ,other,"DIA_DiegoOw_Hallo_11_05");//Die Paladine? Jetzt sage ich dir mal was. Nachdem ich von hier fliehen konnte, war ich in Khorinis.
AI_Output (self ,other,"DIA_DiegoOw_Hallo_11_06");//Ich wollte die Paladine vor den Drachen warnen. Weiß der Henker, warum ich das überhaupt versucht habe.
AI_Output (self ,other,"DIA_DiegoOw_Hallo_11_07");//Denn dieser aufgeblasene Lothar hat mir nicht mal zugehört - geschweige denn, mich zu Lord Hagen vorgelassen.
AI_Output (self ,other,"DIA_DiegoOw_Hallo_11_08");//Stattdessen haben sie mich mit der Expedition wieder her geschickt. Also erzähle mir nichts von den Paladinen ...
AI_Output (other ,self,"DIA_DiegoOw_Hallo_15_09");//Mit wessen Hilfe auch immer, wichtig ist nur, dass wir die Drachen aufhalten - solange wir noch Zeit dafür haben.
AI_Output (self ,other,"DIA_DiegoOw_Hallo_11_10");//Aufhalten? Wir sollten unsere Ärsche aus dem Tal schaffen, solange wir noch Zeit DAFÜR haben.
AI_Output (self ,other,"DIA_DiegoOw_Silvestro_11_03");//Sag mal - wie bist du eigentlich über den Pass gekommen? Ich denke, da sitzen die Orks rum.
AI_Output (other ,self,"DIA_DiegoOw_Silvestro_15_04");//Es gibt einen Weg durch die verlassene Mine, der nicht von Orks besetzt ist.
AI_Output (self ,other,"DIA_DiegoOw_Silvestro_11_05");//Gut zu wissen. Dann werde ich mich wohl bald nach Khorinis aufmachen - hab da noch ein paar alte Rechnungen zu begleichen.
};
//******************************************************************
// Beweise
//******************************************************************
INSTANCE DIA_DiegoOw_Beweise(C_INFO)
{
npc = PC_ThiefOW;
nr = 2;
condition = DIA_DiegoOw_Beweise_Condition;
information = DIA_DiegoOw_Beweise_Info;
description = "Hör zu, ich brauche diese Beweise.";
};
FUNC INT DIA_DiegoOw_Beweise_Condition()
{
return TRUE;
};
FUNC VOID DIA_DiegoOw_Beweise_Info()
{
//AI_Output (other ,self,"DIA_DiegoOw_Silvestro_15_00");//Was weißt du von Silvestros Erz?
AI_Output (other ,self,"DIA_DiegoOw_Hallo_15_11"); //Hör zu, ich brauche diese Beweise.
if (MIS_ScoutMine == LOG_RUNNING)
{
AI_Output (self ,other,"DIA_DiegoOw_Hallo_11_14");//Okay, wenn ich dir helfen kann, werde ich das tun. Aber ich werde meinen Kopf für niemanden in die Schlinge legen.
}
else
{
AI_Output (self ,other,"DIA_DiegoOw_Hallo_11_12");//Na schön, wenn das deine Mission ist - sprich mal mit Kommandant Garond.
AI_Output (self ,other,"DIA_DiegoOw_Hallo_11_13");//Wenn jemand was über die Drachenangriffe weiß, dann sind es die Jungs in der Burg.
};
if (MIS_ScoutMine == LOG_RUNNING)
{
AI_Output (other ,self,"DIA_DiegoOw_Garond_15_00");//Ich bin im Auftrag von Garond unterwegs. Er muss wissen, wie viel Erz bisher geschürft wurde.
AI_Output (self ,other,"DIA_DiegoOw_Garond_11_01");//Und dann gibt er dir die Beweise, die du haben willst?
AI_Output (other ,self,"DIA_DiegoOw_Garond_15_02");//So sieht's aus. Also - kannst du mir was darüber erzählen?
}
else
{
AI_Output (self ,other,"DIA_Addon_DiegoOw_Garond_11_01"); //Und wenn du schonmal in der Burg bist, kannst du Garond direkt etwas erzählen, was ihn sehr interessieren dürfte:
};
if (Npc_GetDistToWP (self, "LOCATION_02_05") <= 1000)
{
AI_Output (self ,other,"DIA_DiegoOw_Silvestro_11_01"); //Hier hinten in der Höhle sind die VIER Kisten Erz, die Silvestros Männer geschürft haben.
AI_Output (self ,other,"DIA_DiegoOw_Silvestro_11_02"); //Die kann sich Garond gerne abholen - aber dann werde ich nicht mehr da sein.
}
else
{
AI_Output (self ,other,"DIA_Addon_DiegoOw_Silvestro_11_01"); //In der Höhle, bei der ich mich versteckt hatte, sind die VIER Kisten Erz. Die hatten Silvestros Männer geschürft.
AI_Output (self ,other,"DIA_Addon_DiegoOw_Silvestro_11_02"); //Die kann sich Garond gerne abholen - ich habe sowieso keine Verwendung dafür...
};
Silvestro_Ore = TRUE;
B_LogEntry (TOPIC_ScoutMine,"Diego hat VIER Kisten Erz von Silvestro's Schürfern in Sicherheit gebracht.");
};
//******************************************************************
// Mine
//******************************************************************
INSTANCE DIA_DiegoOw_Mine(C_INFO)
{
npc = PC_ThiefOW;
nr = 3;
condition = DIA_DiegoOw_Mine_Condition;
information = DIA_DiegoOw_Mine_Info;
permanent = FALSE;
description = "Wie bist du an das Erz gekommen?";
};
FUNC INT DIA_DiegoOw_Mine_Condition()
{
if (Npc_KnowsInfo (other,DIA_DiegoOw_Beweise))
{
return TRUE;
};
};
FUNC VOID DIA_DiegoOw_Mine_Info()
{
AI_Output (other ,self,"DIA_DiegoOw_Mine_15_00");//Wie bist du an das Erz gekommen?
AI_Output (self ,other,"DIA_DiegoOw_Mine_11_01");//Ich war bei Silvestros Truppe. Wir schürfen da also schon ein paar Tage, da wird Silvestro auf einmal unruhig.
AI_Output (self ,other,"DIA_DiegoOw_Mine_11_02");//Er meinte, wir müssen das Erz unbedingt an einen sicheren Ort bringen.
AI_Output (self ,other,"DIA_DiegoOw_Mine_11_03");//Na ja, da ich eh vor hatte, mich abzusetzen, habe ich dann die Sicherstellung des Erzes übernommen.
AI_Output (self ,other,"DIA_DiegoOw_Mine_11_04");//Und das war mein Glück. Denn die Schürfer sind auf einige Minecrawler gestoßen. Und das hat keiner überlebt.
};
//******************************************************************
// Ritter
//******************************************************************
INSTANCE DIA_DiegoOw_Ritter(C_INFO)
{
npc = PC_ThiefOW;
nr = 4;
condition = DIA_DiegoOw_Ritter_Condition;
information = DIA_DiegoOw_Ritter_Info;
permanent = FALSE;
description = "Was ist mit den beiden toten Rittern...";
};
FUNC INT DIA_DiegoOw_Ritter_Condition()
{
if (Npc_HasItems (PAL_Leiche4,ItMI_OldCoin) == 0)
|| (Npc_HasItems (PAL_Leiche5,ItMI_OldCoin) == 0)
{
return TRUE;
};
};
FUNC VOID DIA_DiegoOw_Ritter_Info()
{
AI_Output (other ,self,"DIA_DiegoOw_Ritter_15_00");//Was ist mit den beiden toten Rittern vor deinem Versteck?
AI_Output (self ,other,"DIA_DiegoOw_Ritter_11_01");//Der Kampf gegen eine Gruppe von Snappern wurde ihnen zum Verhängnis.
AI_Output (self ,other,"DIA_DiegoOw_Ritter_11_02");//Das Minental hat halt seine eigenen Regeln. Ich hab's ihnen gesagt. Aber sie wollten nicht auf mich hören.
};
//******************************************************************
// Perm
//******************************************************************
INSTANCE DIA_DiegoOw_Perm(C_INFO)
{
npc = PC_ThiefOW;
nr = 5;
condition = DIA_DiegoOw_Perm_Condition;
information = DIA_DiegoOw_Perm_Info;
permanent = FALSE;
description = "Was muss ich über das Tal wissen?";
};
FUNC INT DIA_DiegoOw_Perm_Condition()
{
return TRUE;
};
FUNC VOID DIA_DiegoOw_Perm_Info()
{
AI_Output (other ,self,"DIA_DiegoOw_Perm_15_00");//Was muss ich über das Tal wissen?
AI_Output (self ,other,"DIA_DiegoOw_Perm_11_01");//Mit dem Fall der Barriere hat sich hier einiges verändert. Die Orks haben hier das Sagen.
AI_Output (self ,other,"DIA_DiegoOw_Perm_11_02");//Wir Menschen sind nur noch Futter für die wahren Herrscher des Tals: die Drachen.
AI_Output (self ,other,"DIA_DiegoOw_Perm_11_03");//Weiche allem aus, was stärker ist als du - und halte dich von allem fern, was nach Drache aussieht.
};
//******************************************************************
// Gorn Freikaufen
//******************************************************************
INSTANCE DIA_DiegoOw_Gorn(C_INFO)
{
npc = PC_ThiefOW;
nr = 6;
condition = DIA_DiegoOw_Gorn_Condition;
information = DIA_DiegoOw_Gorn_Info;
permanent = FALSE;
description = "Ich will Gorn freikaufen...";
};
FUNC INT DIA_DiegoOw_Gorn_Condition()
{
if (MIS_RescueGorn == LOG_RUNNING)
{
return TRUE;
};
};
FUNC VOID DIA_DiegoOw_Gorn_Info()
{
AI_Output (other ,self,"DIA_DiegoOw_Gorn_15_00");//Ich will Gorn freikaufen, aber Garond verlangt 1000 Goldstücke.
AI_Output (self ,other,"DIA_DiegoOw_Gorn_11_01");//Ein schöner Batzen Gold. Ich habe 300 Goldstücke dabei, die kannst du mitnehmen. Der Rest liegt an dir.
B_GiveInvItems (self, other, ItmI_Gold, 300);
B_LogEntry (TOPIC_RescueGorn,"Diego hat 300 Goldstücke zur Befreiung von Gorn beigetragen.");
};
//******************************************************************
// Kannst du mir was beibringen?
//******************************************************************
var int Diego_MerkeDEX;
var int Diego_MerkeSTR;
// -----------------------------------------------------------------
instance DIA_DiegoOw_Teach(C_INFO)
{
npc = PC_ThiefOW;
nr = 100;
condition = DIA_DiegoOw_Teach_Condition;
information = DIA_DiegoOw_Teach_Info;
permanent = TRUE;
description = "Kannst du mir was beibringen?";
};
func INT DIA_DiegoOw_Teach_Condition()
{
return TRUE;
};
FUNC VOID DIA_DiegoOw_Teach_info ()
{
AI_Output (other ,self,"DIA_DiegoOw_Teach_15_00");//Kannst du mir was beibringen?
AI_Output (self, other,"DIA_Addon_DiegoOw_Teach_11_01");//Klar, was willst du wissen?
Diego_MerkeDEX = other.attribute[ATR_DEXTERITY];
Diego_MerkeSTR = other.attribute[ATR_STRENGTH];
Info_ClearChoices (DIA_DiegoOw_TEACH);
Info_AddChoice (DIA_DiegoOw_Teach, DIALOG_BACK, DIA_DiegoOw_TEACH_BACK);
Info_AddChoice (DIA_DiegoOw_Teach, B_BuildLearnString(PRINT_LearnDEX1 , B_GetLearnCostAttribute(other, ATR_DEXTERITY)),DIA_DiegoOw_TEACHDEX_1);
Info_AddChoice (DIA_DiegoOw_Teach, B_BuildLearnString(PRINT_LearnDEX5 , B_GetLearnCostAttribute(other, ATR_DEXTERITY)*5) ,DIA_DiegoOw_TEACHDEX_5);
Info_AddChoice (DIA_DiegoOw_Teach, B_BuildLearnString(PRINT_LearnSTR1 , B_GetLearnCostAttribute(other, ATR_STRENGTH)),DIA_DiegoOw_TEACHSTR_1);
Info_AddChoice (DIA_DiegoOw_Teach, B_BuildLearnString(PRINT_LearnSTR5 , B_GetLearnCostAttribute(other, ATR_STRENGTH)*5) ,DIA_DiegoOw_TEACHSTR_5);
};
func void DIA_DiegoOw_TEACH_BACK()
{
if (other.attribute[ATR_DEXTERITY] > Diego_MerkeDEX)
{
AI_Output (self, other, "DIA_Addon_DiegoOw_Teach_11_02"); //Du hast schon etwas an Geschicklichkeit gewonnen.
};
if (other.attribute[ATR_STRENGTH] > Diego_MerkeSTR)
{
AI_Output (self, other, "DIA_Addon_DiegoOw_Teach_11_03"); //(abschätzend) Gut. Deine Stärke hat zugenommen.
};
Info_ClearChoices (DIA_DiegoOw_TEACH);
};
func void DIA_DiegoOw_TEACHDEX_1()
{
B_TeachAttributePoints (self, other, ATR_DEXTERITY, 1, T_MAX);
Info_ClearChoices (DIA_DiegoOw_TEACH);
Info_AddChoice (DIA_DiegoOw_TEACH, DIALOG_BACK, DIA_DiegoOw_TEACH_BACK);
Info_AddChoice (DIA_DiegoOw_TEACH, B_BuildLearnString(PRINT_LearnDEX1 , B_GetLearnCostAttribute(other, ATR_DEXTERITY)),DIA_DiegoOw_TEACHDEX_1);
Info_AddChoice (DIA_DiegoOw_TEACH, B_BuildLearnString(PRINT_LearnDEX5 , B_GetLearnCostAttribute(other, ATR_DEXTERITY)*5) ,DIA_DiegoOw_TEACHDEX_5);
Info_AddChoice (DIA_DiegoOw_TEACH, B_BuildLearnString(PRINT_LearnSTR1 , B_GetLearnCostAttribute(other, ATR_STRENGTH)),DIA_DiegoOw_TEACHSTR_1);
Info_AddChoice (DIA_DiegoOw_TEACH, B_BuildLearnString(PRINT_LearnSTR5 , B_GetLearnCostAttribute(other, ATR_STRENGTH)*5) ,DIA_DiegoOw_TEACHSTR_5);
};
func void DIA_DiegoOw_TEACHDEX_5()
{
B_TeachAttributePoints (self, other, ATR_DEXTERITY, 5, T_MAX);
Info_ClearChoices (DIA_DiegoOw_TEACH);
Info_AddChoice (DIA_DiegoOw_TEACH, DIALOG_BACK, DIA_DiegoOw_TEACH_BACK);
Info_AddChoice (DIA_DiegoOw_TEACH, B_BuildLearnString(PRINT_LearnDEX1 , B_GetLearnCostAttribute(other, ATR_DEXTERITY)),DIA_DiegoOw_TEACHDEX_1);
Info_AddChoice (DIA_DiegoOw_TEACH, B_BuildLearnString(PRINT_LearnDEX5 , B_GetLearnCostAttribute(other, ATR_DEXTERITY)*5) ,DIA_DiegoOw_TEACHDEX_5);
Info_AddChoice (DIA_DiegoOw_TEACH, B_BuildLearnString(PRINT_LearnSTR1 , B_GetLearnCostAttribute(other, ATR_STRENGTH)),DIA_DiegoOw_TEACHSTR_1);
Info_AddChoice (DIA_DiegoOw_TEACH, B_BuildLearnString(PRINT_LearnSTR5 , B_GetLearnCostAttribute(other, ATR_STRENGTH)*5) ,DIA_DiegoOw_TEACHSTR_5);
};
func void DIA_DiegoOw_TEACHSTR_1()
{
B_TeachAttributePoints (self, other, ATR_STRENGTH, 1, T_MED);
Info_ClearChoices (DIA_DiegoOw_TEACH);
Info_AddChoice (DIA_DiegoOw_TEACH, DIALOG_BACK, DIA_DiegoOw_TEACH_BACK);
Info_AddChoice (DIA_DiegoOw_TEACH, B_BuildLearnString(PRINT_LearnDEX1 , B_GetLearnCostAttribute(other, ATR_DEXTERITY)),DIA_DiegoOw_TEACHDEX_1);
Info_AddChoice (DIA_DiegoOw_TEACH, B_BuildLearnString(PRINT_LearnDEX5 , B_GetLearnCostAttribute(other, ATR_DEXTERITY)*5) ,DIA_DiegoOw_TEACHDEX_5);
Info_AddChoice (DIA_DiegoOw_TEACH, B_BuildLearnString(PRINT_LearnSTR1 , B_GetLearnCostAttribute(other, ATR_STRENGTH)),DIA_DiegoOw_TEACHSTR_1);
Info_AddChoice (DIA_DiegoOw_TEACH, B_BuildLearnString(PRINT_LearnSTR5 , B_GetLearnCostAttribute(other, ATR_STRENGTH)*5) ,DIA_DiegoOw_TEACHSTR_5);
};
func void DIA_DiegoOw_TEACHSTR_5()
{
B_TeachAttributePoints (self, other, ATR_STRENGTH, 5, T_MED);
Info_ClearChoices (DIA_DiegoOw_TEACH);
Info_AddChoice (DIA_DiegoOw_TEACH, DIALOG_BACK, DIA_DiegoOw_TEACH_BACK);
Info_AddChoice (DIA_DiegoOw_TEACH, B_BuildLearnString(PRINT_LearnDEX1 , B_GetLearnCostAttribute(other, ATR_DEXTERITY)),DIA_DiegoOw_TEACHDEX_1);
Info_AddChoice (DIA_DiegoOw_TEACH, B_BuildLearnString(PRINT_LearnDEX5 , B_GetLearnCostAttribute(other, ATR_DEXTERITY)*5) ,DIA_DiegoOw_TEACHDEX_5);
Info_AddChoice (DIA_DiegoOw_TEACH, B_BuildLearnString(PRINT_LearnSTR1 , B_GetLearnCostAttribute(other, ATR_STRENGTH)),DIA_DiegoOw_TEACHSTR_1);
Info_AddChoice (DIA_DiegoOw_TEACH, B_BuildLearnString(PRINT_LearnSTR5 , B_GetLearnCostAttribute(other, ATR_STRENGTH)*5) ,DIA_DiegoOw_TEACHSTR_5);
};
// ************************************************************
// PICK POCKET
// ************************************************************
INSTANCE DIA_ThiefOW_PICKPOCKET (C_INFO)
{
npc = PC_ThiefOW;
nr = 900;
condition = DIA_ThiefOW_PICKPOCKET_Condition;
information = DIA_ThiefOW_PICKPOCKET_Info;
permanent = TRUE;
description = Pickpocket_120;
};
FUNC INT DIA_ThiefOW_PICKPOCKET_Condition()
{
C_Beklauen (120, 600);
};
FUNC VOID DIA_ThiefOW_PICKPOCKET_Info()
{
Info_ClearChoices (DIA_ThiefOW_PICKPOCKET);
Info_AddChoice (DIA_ThiefOW_PICKPOCKET, DIALOG_BACK ,DIA_ThiefOW_PICKPOCKET_BACK);
Info_AddChoice (DIA_ThiefOW_PICKPOCKET, DIALOG_PICKPOCKET ,DIA_ThiefOW_PICKPOCKET_DoIt);
};
func void DIA_ThiefOW_PICKPOCKET_DoIt()
{
B_Beklauen ();
Info_ClearChoices (DIA_ThiefOW_PICKPOCKET);
};
func void DIA_ThiefOW_PICKPOCKET_BACK()
{
Info_ClearChoices (DIA_ThiefOW_PICKPOCKET);
};
// ************************************************************
// *** ***
// Mit Diego Durch die Gegend
// *** ***
// ************************************************************
// ------------------------------------------------------------
// Lass uns zusammen gehen!
// ------------------------------------------------------------
instance DIA_Addon_ThiefOW_Together(C_INFO)
{
npc = PC_ThiefOW;
nr = 11;
condition = DIA_Addon_ThiefOW_Together_Condition;
information = DIA_Addon_ThiefOW_Together_Info;
description = "Lass uns zusammen gehen.";
};
func int DIA_Addon_ThiefOW_Together_Condition ()
{
return TRUE;
};
func void DIA_Addon_ThiefOW_Together_Info ()
{
AI_Output (other, self, "DIA_Addon_Diego_Together_15_00"); //Lass uns zusammen gehen.
AI_Output (self, other, "DIA_Addon_Diego_Together_11_01"); //Zum Pass? Warum nicht...
AI_Output (self, other, "DIA_Addon_Diego_Together_11_02"); //Geh du voran. Du kommst ja gerade von dort.
AI_Output (self, other, "DIA_Addon_Diego_Together_11_03"); //Aber lass dir nicht einfallen, zu nahe an die Burg oder den Orkwall zu gehen.
AI_Output (self, other, "DIA_Addon_Diego_Together_11_04"); //Außerdem sollen wir alle befestigten Lager der Paladine meiden.
AI_Output (self, other, "DIA_Addon_Diego_Together_11_05"); //Ich bin gerade aus einem entkommen und habe keine Lust, wieder in einer der Minen schuften zu müssen.
AI_Output (self, other, "DIA_Addon_Diego_Together_11_06"); //Und daß wir nicht in die Nähe eines Drachen gehen, versteht sich wohl von selbst.
AI_Output (self, other, "DIA_Addon_Diego_Together_11_07"); //Wenn du bereit bist, sag es mir.
};
// ------------------------------------------------------------
// Komm (wieder) mit!
// ------------------------------------------------------------
instance DIA_Addon_ThiefOW_ComeOn(C_INFO)
{
npc = PC_ThiefOW;
nr = 12;
condition = DIA_Addon_ThiefOW_ComeOn_Condition;
information = DIA_Addon_ThiefOW_ComeOn_Info;
permanent = TRUE;
description = "Komm mit.";
};
func int DIA_Addon_ThiefOW_ComeOn_Condition ()
{
if (self.aivar[AIV_PARTYMEMBER] == FALSE)
&& (Npc_KnowsInfo (other, DIA_Addon_ThiefOW_Together))
&& (Diego_angekommen == FALSE)
{
return TRUE;
};
};
func void DIA_Addon_ThiefOW_ComeOn_Info ()
{
AI_Output (other, self, "DIA_Addon_Diego_ComeOn_15_00"); //Komm mit.
if (C_DiegoTooFar(0))
{
AI_Output (self, other, "DIA_Addon_Diego_ComeOn_11_01"); //Das ist die falsche Richtung!
AI_StopProcessInfos (self);
}
else
{
AI_Output (self, other, "DIA_Addon_Diego_ComeOn_11_02"); //Alles klar.
AI_StopProcessInfos (self);
Npc_ExchangeRoutine (self,"FOLLOW");
self.aivar[AIV_PARTYMEMBER] = TRUE;
};
};
// ------------------------------------------------------------
// Go Home!
// ------------------------------------------------------------
INSTANCE DIA_Addon_ThiefOW_GoHome(C_INFO)
{
npc = PC_ThiefOW;
nr = 13;
condition = DIA_Addon_ThiefOW_GoHome_Condition;
information = DIA_Addon_ThiefOW_GoHome_Info;
permanent = TRUE;
description = "Warte hier.";
};
FUNC INT DIA_Addon_ThiefOW_GoHome_Condition()
{
if (self.aivar[AIV_PARTYMEMBER] == TRUE)
{
return TRUE;
};
};
FUNC VOID DIA_Addon_ThiefOW_GoHome_Info()
{
AI_Output (other, self,"DIA_Addon_Diego_WarteHier_15_00"); //Warte hier!
if (Npc_GetDistToWP (self, "LOCATION_02_05") < 2000)
{
AI_Output (self, other, "DIA_Addon_Diego_GoHome_11_01"); //Okay.
AI_StopProcessInfos (self);
self.aivar[AIV_PARTYMEMBER] = FALSE;
Npc_ExchangeRoutine (self,"START");
}
else if (Npc_GetDistToWP (self, "DT_E1_04") < (1500+1000)) //XARDAS
{
AI_Output (self, other, "DIA_Addon_Diego_GoHome_11_02"); //Ich warte draussen am Turm.
AI_StopProcessInfos (self);
self.aivar[AIV_PARTYMEMBER] = FALSE;
Npc_ExchangeRoutine (self,"XARDAS");
}
else if (Npc_GetDistToWP (self, "OW_NEWMINE_11") < (4000+1000)) //FAJETHMINE
{
AI_Output (self, other, "DIA_Addon_Diego_GoHome_11_03"); //Ich warte in der Nähe der Mine.
AI_StopProcessInfos (self);
self.aivar[AIV_PARTYMEMBER] = FALSE;
Npc_ExchangeRoutine (self,"FAJETH");
}
else if (Npc_GetDistToWP (self, "OW_MINE3_OUT") < (1200+1000)) //SILVESTROMINE
{
AI_Output (self, other, "DIA_Addon_Diego_GoHome_11_04"); //Ich warte vor der Mine.
AI_StopProcessInfos (self);
self.aivar[AIV_PARTYMEMBER] = FALSE;
Npc_ExchangeRoutine (self,"SILVESTRO");
}
else if (Npc_GetDistToWP (self, "OW_PATH_266") < (3000+1000)) //GRIMESMINE
{
AI_Output (self, other, "DIA_Addon_Diego_GoHome_11_05"); //Ich warte hier in der Nähe.
AI_StopProcessInfos (self);
self.aivar[AIV_PARTYMEMBER] = FALSE;
Npc_ExchangeRoutine (self,"GRIMES");
}
else if (Npc_GetDistToWP (self, "LOCATION_02_05") < 15000) //Orcbarrier FIRE ANGAR LAKE
{
AI_Output (self, other, "DIA_Addon_Diego_GoHome_11_06"); //Nein. Ich geh wieder zurück zur Höhle.
AI_Output (self, other, "DIA_Addon_Diego_GoHome_11_07"); //Wenn du mit deinem Kram fertig bist, kannst du ja wieder vorbeischauen.
AI_Output (self, other, "DIA_Addon_Diego_GoHome_11_08"); //Aber warte nicht zu lange. Sonst mache ich mich alleine auf den Weg.
AI_StopProcessInfos (self);
self.aivar[AIV_PARTYMEMBER] = FALSE;
Npc_ExchangeRoutine (self,"START");
}
else //zu weit weg
{
AI_Output (self, other, "DIA_Addon_Diego_GoHome_11_09"); //Das ist doch nicht dein Ernst? Wir sollen uns trennen? Hier?
AI_Output (self, other, "DIA_Addon_Diego_GoHome_11_10"); //Das kommt nicht in Frage!
AI_Output (self, other, "DIA_Addon_Diego_GoHome_11_11"); //Wir gehen jetzt schön zusammen zum Pass.
};
};
// ------------------------------------------------------------
// Zu weit gegangen
// ------------------------------------------------------------
func void B_Addon_Diego_WillWaitOutside()
{
AI_Output (self, other, "DIA_Addon_Diego_TooFar_11_00"); //Wenn du dich umsehen willst - ich warte draussen.
};
// ------------------------------------------------------------
func void B_Addon_Diego_PassOtherDirection()
{
AI_Output (self, other, "DIA_Addon_Diego_TooFar_11_01"); //Wenn wir zum Pass wollen, müssen wir in die andere Richtung.
};
// ------------------------------------------------------------
var int Diego_TooFarComment;
var int Diego_BurgVariation;
var int Diego_FajethVariation;
var int Diego_SilvestroVariation;
var int Diego_GrimesVariation;
var int Diego_XardasVariation;
var int Diego_IceVariation;
// ------------------------------------------------------------
INSTANCE DIA_Addon_ThiefOW_TooFar(C_INFO)
{
npc = PC_ThiefOW;
nr = 14;
condition = DIA_Addon_ThiefOW_TooFar_Condition;
information = DIA_Addon_ThiefOW_TooFar_Info;
permanent = TRUE;
important = TRUE;
};
FUNC INT DIA_Addon_ThiefOW_TooFar_Condition()
{
if (self.aivar[AIV_PARTYMEMBER] == TRUE)
{
if (C_DiegoTooFar(0))
{
if (Diego_TooFarComment == FALSE)
{
return TRUE;
};
}
else
{
Diego_TooFarComment = FALSE;
};
};
};
FUNC VOID DIA_Addon_ThiefOW_TooFar_Info()
{
if (C_DiegoTooFar(1000) == LOC_ANGAR)
{
AI_Output (self, other, "DIA_Addon_Diego_TooFar_11_02"); //Diese alte Grabstätte ist mir nicht geheuer.
AI_Output (self, other, "DIA_Addon_Diego_TooFar_11_03"); //Lass uns lieber drum herum gehen.
}
else if (C_DiegoTooFar(1000) == LOC_ICE)
{
if (Diego_IceVariation == 0)
{
AI_Output (self, other, "DIA_Addon_Diego_TooFar_11_04"); //Das ist der Eingang zum ehemaligen Neue Lager.
AI_Output (self, other, "DIA_Addon_Diego_TooFar_11_05"); //Ich bin mir sicher, da drinnen hat sich ein Drache breitgemacht.
B_Addon_Diego_PassOtherDirection();
Diego_IceVariation = 1;
}
else //1
{
B_Addon_Diego_PassOtherDirection();
};
}
else if (C_DiegoTooFar(1000) == LOC_SWAMP)
{
AI_Output (self, other, "DIA_Addon_Diego_TooFar_11_06"); //Dieser Sumpf ist eine Sackgasse.
AI_Output (self, other, "DIA_Addon_Diego_TooFar_11_07"); //Würde ich nicht wundern, wenn da drinnen sogar ein Drache auf uns lauert.
AI_Output (self, other, "DIA_Addon_Diego_TooFar_11_08"); //Lass uns nicht da reingehen.
}
else if (C_DiegoTooFar(1000) == LOC_FIRE)
{
AI_Output (self, other, "DIA_Addon_Diego_TooFar_11_09"); //Wenn wir den Berg weiter hochgehen, kommen wir garantiert zu einem Drachen.
AI_Output (self, other, "DIA_Addon_Diego_TooFar_11_10"); //Und ich würde gerne LEBEND in Khorinis ankommen.
AI_Output (self, other, "DIA_Addon_Diego_TooFar_11_11"); //Lass uns einen anderen Weg nehmen.
}
else if (C_DiegoTooFar(1000) == LOC_LAKE)
{
AI_Output (self, other, "DIA_Addon_Diego_TooFar_11_12"); //Dieser See führt uns nirgendwohin.
AI_Output (self, other, "DIA_Addon_Diego_TooFar_11_13"); //Wenn wir zum Pass wollen, müssen wir in die andere Richtung!
}
else if (C_DiegoTooFar(1000) == LOC_XARDAS)
{
if (Diego_XardasVariation == 0)
{
AI_Output (self, other, "DIA_Addon_Diego_TooFar_11_14"); //Das ist der alte Turm von Xardas. Er hat sich natürlich längst aus dem Staub gemacht.
AI_Output (self, other, "DIA_Addon_Diego_TooFar_11_15"); //Bin mir sicher, da drinnen warten einige unangenehme Überraschungen.
B_Addon_Diego_WillWaitOutside();
Diego_XardasVariation = 1;
}
else //1
{
B_Addon_Diego_WillWaitOutside();
AI_StopProcessInfos (self);
self.aivar[AIV_PARTYMEMBER] = FALSE;
Npc_ExchangeRoutine (self,"XARDAS");
};
}
else if (C_DiegoTooFar(1000) == LOC_FAJETHMINE)
{
if (Diego_FajethVariation == 0)
{
AI_Output (self, other, "DIA_Addon_Diego_TooFar_11_16"); //Das da hinten ist Fajeths Mine.
AI_Output (self, other, "DIA_Addon_Diego_TooFar_11_17"); //Wenn du da hin willst, dann ohne mich!
Diego_FajethVariation = 1;
}
else //1
{
AI_Output (self, other, "DIA_Addon_Diego_TooFar_11_18"); //Ich werde einen großen Bogen um diese Mine machen!
};
}
else if (C_DiegoTooFar(1000) == LOC_SILVESTROMINE)
{
if (Diego_SilvestroVariation == 0)
{
AI_Output (self, other, "DIA_Addon_Diego_TooFar_11_19"); //Das ist die Mine, in die sie mich gebracht haben, als ich mit dem Strafkonvoi zurückgekommen bin.
AI_Output (self, other, "DIA_Addon_Diego_TooFar_11_20"); //Ich bin mir sicher, da drinnen lebt KEINER mehr.
B_Addon_Diego_WillWaitOutside();
AI_Output (self, other, "DIA_Addon_Diego_TooFar_Add_11_20"); //Aber wenn du zu lange brauchst, geh ich wieder zurück zu meinem Lager.
AI_Output (self, other, "DIA_Addon_Diego_TooFar_Add_11_21"); //Es sei denn, du willst, daß ich hier solange warte.
Diego_SilvestroVariation = 1;
}
else //1
{
B_Addon_Diego_WillWaitOutside();
AI_StopProcessInfos (self);
self.aivar[AIV_PARTYMEMBER] = FALSE;
Npc_ExchangeRoutine (self,"SILVESTRO");
};
}
else if (C_DiegoTooFar(1000) == LOC_GRIMESMINE)
{
if (Diego_GrimesVariation == 0)
{
AI_Output (self, other, "DIA_Addon_Diego_TooFar_11_21"); //Das ist eine der neuen Minen der Paladine.
AI_Output (self, other, "DIA_Addon_Diego_TooFar_11_22"); //Ich war noch nie dort - und werde auch nicht hingehen.
Diego_GrimesVariation = 1;
}
else //1
{
AI_Output (self, other, "DIA_Addon_Diego_TooFar_11_23"); //Machen wir einen Bogen um die Mine.
};
}
else if (C_DiegoTooFar(1000) == LOC_BURG)
{
if (Diego_BurgVariation == 0)
{
AI_Output (self, other, "DIA_Addon_Diego_TooFar_11_24"); //Bist du lebensmüde? Geh bloß nicht zu nahe an die Burg!
Diego_BurgVariation = 1;
}
else if (Diego_BurgVariation == 1)
{
AI_Output (self, other, "DIA_Addon_Diego_TooFar_11_25"); //Sag mal, hörst du mir nicht zu?! Nicht zu nahe an die Burg!
Diego_BurgVariation = 2;
}
else //2
{
AI_Output (self, other, "DIA_Addon_Diego_TooFar_11_26"); //Was ist an 'Nicht zu nahe an die Burg' nicht zu verstehen?
Diego_BurgVariation = 1;
};
}
else if (C_DiegoTooFar(1000) == LOC_ORCBARRIER)
{
AI_Output (self, other, "DIA_Addon_Diego_TooFar_11_27"); //Hier können wir nicht weitergehen. Die Orkbarriere ist zu gefährlich.
AI_Output (self, other, "DIA_Addon_Diego_TooFar_11_28"); //Ich denke, es wäre besser, wenn wir wieder Richtung Westen gehen und einen Bogen zur anderen Seite machen.
}
else if (C_DiegoTooFar(1000) == LOC_ORCBARRIER_FAR)
{
AI_Output (self, other, "DIA_Addon_Diego_TooFar_11_29"); //Wenn wir hier weitergehen, kommen wir nur wieder zur Orkbarriere.
AI_Output (self, other, "DIA_Addon_Diego_TooFar_11_30"); //Lass uns zum Pass gehen!
};
Diego_TooFarComment = TRUE;
};
// ------------------------------------------------------------
// Angekommen
// ------------------------------------------------------------
func void B_Diego_WirSindDa()
{
AI_Output (self, other, "DIA_Addon_Diego_Angekommen_11_02"); //Den Rest des Weges werde ich alleine zurücklegen.
AI_Output (self, other, "DIA_Addon_Diego_Angekommen_11_03"); //Ich habe da noch einige Dinge zu erledigen, bevor ich nach Khorinis zurückgehen kann.
AI_Output (self, other, "DIA_Addon_Diego_Angekommen_11_04"); //Ich danke dir, mein Freund. Wir sehen uns in der Stadt.
AI_StopProcessInfos (self);
self.aivar[AIV_PARTYMEMBER] = FALSE;
Npc_ExchangeRoutine (self,"PASS");
Diego_angekommen = TRUE;
};
// ------------------------------------------------------------
INSTANCE DIA_Addon_ThiefOW_Angekommen (C_INFO)
{
npc = PC_ThiefOW;
nr = 1;
condition = DIA_Addon_ThiefOW_Angekommen_Condition;
information = DIA_Addon_ThiefOW_Angekommen_Info;
important = TRUE;
};
FUNC INT DIA_Addon_ThiefOW_Angekommen_Condition()
{
if (Npc_GetDistToWP (self, "OW_VM_ENTRANCE") < 800)
{
return TRUE;
};
};
func VOID DIA_Addon_ThiefOW_Angekommen_Info()
{
AI_Output (self, other, "DIA_Addon_Diego_Angekommen_11_01"); //So, wir sind da.
B_GivePlayerXP (500);
B_Diego_WirSindDa();
};
// ------------------------------------------------------------
// Nostalgie
// ------------------------------------------------------------
instance DIA_Addon_ThiefOW_Nostalgie (C_INFO)
{
npc = PC_ThiefOW;
nr = 1;
condition = DIA_Addon_ThiefOW_Nostalgie_Condition;
information = DIA_Addon_ThiefOW_Nostalgie_Info;
important = TRUE;
};
FUNC INT DIA_Addon_ThiefOW_Nostalgie_Condition()
{
if (Npc_GetDistToWP (self, "WP_INTRO14") < 2000)
{
return TRUE;
};
};
func VOID DIA_Addon_ThiefOW_Nostalgie_Info()
{
AI_Output (self, other, "DIA_Addon_Diego_Nostalgie_11_01"); //Weißt du noch, damals?
AI_Output (self, other, "DIA_Addon_Diego_Nostalgie_11_02"); //Als wir uns hier das erste Mal trafen?
AI_Output (self, other, "DIA_Addon_Diego_Nostalgie_11_03"); //Ist ne lange Zeit her...
AI_Output (self, other, "DIA_Addon_Diego_Nostalgie_11_04"); //Irgendendwas war NOCH an diesem Ort - hmm - verdammt! Ich kann mich nicht mehr erinnern.
AI_Output (self, other, "DIA_Addon_Diego_Nostalgie_11_05"); //Wie auch immer...
B_GivePlayerXP (500);
hero.exp = hero.exp + 500;
PrintScreen (ConcatStrings(NAME_Addon_NostalgieBonus, IntToString(500)), -1, 60, FONT_Screen, 2);
if (other.guild == GIL_NONE)
{
CreateInvItems (self, itar_shadow, 1);
B_GiveInvItems (self, other, itar_shadow, 1);
AI_EquipArmor (other, itar_shadow);
};
B_Diego_WirSindDa();
};
// ------------------------------------------------------------
// PERM
// ------------------------------------------------------------
instance DIA_Addon_ThiefOW_PERM (C_INFO)
{
npc = PC_ThiefOW;
nr = 10;
condition = DIA_Addon_ThiefOW_PERM_Condition;
information = DIA_Addon_ThiefOW_PERM_Info;
permanent = TRUE;
description = "Alles klar?";
};
FUNC INT DIA_Addon_ThiefOW_PERM_Condition()
{
if (Npc_KnowsInfo(other, DIA_DiegoOw_Perm))
&& (Npc_KnowsInfo(other, DIA_Addon_ThiefOW_Together))
{
return TRUE;
};
};
func VOID DIA_Addon_ThiefOW_PERM_Info()
{
AI_Output (other ,self,"DIA_Addon_Diego_PERM_15_00"); //Alles klar?
if (self.attribute[ATR_HITPOINTS] <= (self.attribute[ATR_HITPOINTS_MAX] / 2))
{
AI_Output (self, other, "DIA_Addon_Diego_PERM_11_01"); //Ich könnte einen Heiltrank gebrauchen. Du hast nicht zufällig einen dabei?
}
else if (DiegoOW.aivar[AIV_PARTYMEMBER] == FALSE)
&& (Diego_angekommen == FALSE)
{
AI_Output (self, other, "DIA_Addon_Diego_PERM_11_02"); //Wenn du losgehen willst, sag Bescheid.
}
else if (Diego_angekommen == TRUE)
{
AI_Output (self, other, "DIA_Addon_Diego_PERM_11_03"); //Alles bestens. Ich ruhe mich nur kurz aus.
}
else
{
AI_Output (self, other, "DIA_Addon_Diego_PERM_11_04"); //Alles bestens.
};
};
| D |
module org.serviio.library.local.metadata.extractor.video.FileNameParser;
import java.io.File;
import java.util.regex.Matcher;
import java.util.regex.Pattern;
import org.serviio.library.entities.Repository;
import org.serviio.util.FileUtils;
import org.serviio.util.StringUtils;
public class FileNameParser
{
private static Pattern[] EPISODIC_PATTERNS = { Pattern.compile("[s]([\\d]+)[e]([\\d]+).*", 2), Pattern.compile("[s]([\\d]+)\\.[e]([\\d]+).*", 2), Pattern.compile("([\\d]+)[x]([\\d]+)", 2), Pattern.compile("[s]([\\d]+)_[e]([\\d]+).*", 2), Pattern.compile("\\b([0][0-9]|[1][0-8])([\\d]{2,2})\\b.*", 2), Pattern.compile("^([\\d])[\\s]([\\d]{2,2})", 2), Pattern.compile("^([\\d]{1,2})[\\s]([\\d]{2,2})", 2), Pattern.compile("([\\d]{1,2})[\\s]{0,1}-[\\s]{0,1}([\\d]{1,2})[\\s]*-", 2), Pattern.compile("season\\s([\\d]+)\\sepisode\\s([\\d]+).*", 2) };
private static Pattern[] SPECIAL_PATTERNS = { Pattern.compile(".*trailer.*", 2), Pattern.compile(".*sample.*", 2) };
private static Pattern MOVIE_YEAR_PATTERN = Pattern.compile("(?<!^)(\\[|\\()?(\\b\\d{4}\\b)(\\]|\\)?)");
private static Pattern SERIES_YEAR_PATTERN = Pattern.compile("(\\[|\\()(\\d{4})(\\]|\\))");
public static VideoDescription parse(File videoFile, Repository repository)
{
if (isSpecialContent(videoFile)) {
return new VideoDescription(VideoDescription.VideoType.SPECIAL, false);
}
Pattern descriptionPattern = getEpisodeMatch(videoFile);
if (descriptionPattern !is null)
{
return getEpisodeDescription(videoFile, descriptionPattern, repository);
}
return getMovieDescription(videoFile, repository);
}
protected static bool isSpecialContent(File videoFile)
{
String file = FileUtils.getFileNameWithoutExtension(videoFile).trim();
foreach (Pattern pattern ; SPECIAL_PATTERNS) {
Matcher m = pattern.matcher(file);
if (m.matches()) {
return true;
}
}
return false;
}
protected static Pattern getEpisodeMatch(File videoFile)
{
String file = FileUtils.getFileNameWithoutExtension(videoFile).trim();
foreach (Pattern pattern ; EPISODIC_PATTERNS) {
Matcher m = pattern.matcher(file);
if (m.find()) {
return pattern;
}
}
return null;
}
protected static VideoDescription getEpisodeDescription(File videoFile, Pattern pattern, Repository repository)
{
Integer year = getYearFromFileName(SERIES_YEAR_PATTERN, videoFile);
Matcher m = pattern.matcher(videoFile.getName());
if (m.find()) {
int seasonNumber = Integer.parseInt(m.group(1));
int episodeNumber = Integer.parseInt(m.group(2));
String fileBasedName = getVideoName(videoFile, pattern, SERIES_YEAR_PATTERN.pattern(), true, false);
String folderBasedName = getParentFolderBasedName(videoFile, repository);
return new VideoDescription(VideoDescription.VideoType.EPISODE, true, cast(String[])[ fileBasedName, folderBasedName ], Integer.valueOf(seasonNumber), Integer.valueOf(episodeNumber), year);
}
return new VideoDescription(VideoDescription.VideoType.EPISODE, false);
}
protected static VideoDescription getMovieDescription(File videoFile, Repository repository)
{
Integer year = getYearFromFileName(MOVIE_YEAR_PATTERN, videoFile);
String fileBasedName = getVideoName(videoFile, null, MOVIE_YEAR_PATTERN.pattern(), false, false);
String folderBasedName = getParentFolderBasedName(videoFile, repository);
return new VideoDescription(VideoDescription.VideoType.FILM, true, cast(String[])[ fileBasedName, folderBasedName ], year);
}
private static Integer getYearFromFileName(Pattern pattern, File videoFile)
{
Matcher m = pattern.matcher(videoFile.getName());
Integer year = null;
if (m.find()) {
year = Integer.valueOf(Integer.parseInt(m.group(2)));
}
else {
File folder = getSuitableParentFolder(videoFile.getParentFile());
m = pattern.matcher(folder.getName());
if (m.find()) {
year = Integer.valueOf(Integer.parseInt(m.group(2)));
}
}
return year;
}
protected static String getVideoName(File videoFile, Pattern patternToDelete, String yearPattern, bool episodic, bool folder)
{
if (isFileNameNondescriptive(videoFile.getPath())) {
return null;
}
String file = videoFile.getName().trim();
if (!folder) {
file = FileUtils.getFileNameWithoutExtension(videoFile).trim();
}
if (patternToDelete !is null) {
file = patternToDelete.matcher(file).replaceAll("");
}
if ((episodic) && (!folder))
{
if (file.indexOf("-") > -1) {
file = file.substring(0, file.indexOf("-"));
}
}
file = file.replaceAll("[\\.|_|]", " ").trim();
if (!folder)
{
file = file.replaceAll("-", " ").trim();
}
if (StringUtils.localeSafeToLowercase(file).endsWith("the"))
{
file = "the " + file.substring(0, file.length() - 3).trim();
if (file.endsWith(",")) {
file = file.substring(0, file.length() - 1);
}
}
file = file.replaceAll(yearPattern + ".*", "");
file = file.replaceAll("(\\[).*(\\])", "");
file = file.replaceAll("(?<!^)(\\b[A-Z]{4,}\\b).*", "");
file = StringUtils.localeSafeToLowercase(file);
file = file.replaceAll("(dvdrip|dvd-rip|bdrip|bd-rip|dvd|xvid|divx|xv|xvi|hd|hdtv|1080|720).*", "");
file = file.replaceAll("\\s{2,}", " ");
return file.trim();
}
protected static String getParentFolderBasedName(File videoFile, Repository repository)
{
File repositoryFolder = repository.getFolder();
if ((videoFile.getParentFile() !is null) && (!videoFile.getParentFile().equals(repositoryFolder)))
{
File folder = getSuitableParentFolder(videoFile.getParentFile());
String folderBasedMovieName = getVideoName(folder, null, MOVIE_YEAR_PATTERN.pattern(), false, true);
return folderBasedMovieName;
}
return null;
}
protected static File getSuitableParentFolder(File videoFolder) {
if (videoFolder !is null) {
String folderName = StringUtils.localeSafeToLowercase(videoFolder.getName());
if ((folderName.startsWith("season")) || (folderName.startsWith("series")) || (folderName.startsWith("cd")) || (folderName.startsWith("video_ts")))
{
return getSuitableParentFolder(videoFolder.getParentFile());
}
}
return videoFolder;
}
protected static bool isFileNameNondescriptive(String filePath) {
String filePathFixed = StringUtils.localeSafeToUppercase(filePath);
if ((filePathFixed.indexOf("VIDEO_TS") > -1) || (filePathFixed.indexOf("VTS_") > -1))
{
return true;
}
return false;
}
}
/* Location: D:\Program Files\Serviio\lib\serviio.jar
* Qualified Name: org.serviio.library.local.metadata.extractor.video.FileNameParser
* JD-Core Version: 0.6.2
*/ | D |
import std.stdio, std.algorithm, std.conv, std.array, std.string, std.math, std.typecons;
void main()
{
auto hw = readln.split.to!(int[]);
auto H = hw[0];
auto W = hw[1];
wchar[][] ss;
ss.length = H;
foreach (i; 0..H) ss[i] = readln.chomp.to!(wchar[]);
int[][] ns;
ns.length = H;
foreach (ref n; ns) n.length = W;
foreach (y, s; ss) {
foreach (x, e; s) {
if (e == '#') {
ns[y][x] = -100;
if (x > 0) {
if (y > 0) ++ns[y-1][x-1];
++ns[y][x-1];
if (y+1 < H) ++ns[y+1][x-1];
}
if (y > 0) ++ns[y-1][x];
if (y+1 < H) ++ns[y+1][x];
if (x+1 < W) {
if (y > 0) ++ns[y-1][x+1];
++ns[y][x+1];
if (y+1 < H) ++ns[y+1][x+1];
}
}
}
}
foreach (n; ns) {
foreach (e; n) {
write(e < 0 ? "#" : e.to!string);
}
writeln("");
}
} | D |
import std.stdio, std.array, std.string, std.conv, std.algorithm;
import std.typecons, std.range, std.random, std.math, std.container;
import std.numeric, std.bigint, core.bitop, core.stdc.stdio;
int N, M;
int[] f, overlap, mem;
immutable int MOD = 10^^9+7;
void main() {
auto s = readln.split.map!(to!int);
N = s[0];
M = s[1];
f = N.iota.map!(_ => readln.chomp.to!int).array;
overlap = new int[](N);
foreach (i; 0..N) overlap[i] = N;
auto used = new bool[](M+1);
used[f[0]] = true;
int L = 0, R = 1;
while (R < N) {
while (used[f[R]]) {
overlap[L] = R;
used[f[L]] = false;
L++;
}
used[f[R]] = true;
R++;
}
auto acm = new int[](N+1);
auto dp = new int[](N+1);
dp[N] = acm[N] = 0;
dp[N-1] = acm[N-1] = 1;
for (int i = N-2; i >= 0; i--) {
if (overlap[i] == N)
dp[i] = 1;
dp[i] = (dp[i] + acm[i+1] - acm[min(overlap[i]+1, N)]) % MOD;
if (dp[i] < 0) dp[i] += MOD;
acm[i] = (dp[i] + acm[i+1]) % MOD;
}
dp[0].writeln;
}
| D |
/Users/mickaeljordan/Desktop/Citizen/DerivedData/Citizen/Build/Intermediates/Citizen.build/Debug-iphonesimulator/CitizenTests.build/Objects-normal/x86_64/CitizenTests.o : /Users/mickaeljordan/Desktop/Citizen/CitizenTests/CitizenTests.swift /Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/lib/swift/iphonesimulator/Swift.swiftmodule /Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/lib/swift/iphonesimulator/UIKit.swiftmodule /Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/lib/swift/iphonesimulator/Foundation.swiftmodule /Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/lib/swift/iphonesimulator/Darwin.swiftmodule /Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/lib/swift/iphonesimulator/Dispatch.swiftmodule /Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/lib/swift/iphonesimulator/ObjectiveC.swiftmodule /Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/lib/swift/iphonesimulator/CoreGraphics.swiftmodule /Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/lib/swift/iphonesimulator/Security.swiftmodule /Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/lib/swift/iphonesimulator/CoreImage.swiftmodule /Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/lib/swift/iphonesimulator/XCTest.swiftmodule /Applications/Xcode.app/Contents/Developer/Platforms/iPhoneSimulator.platform/Developer/Library/Frameworks/XCTest.framework/Headers/XCTestSuiteRun.h /Applications/Xcode.app/Contents/Developer/Platforms/iPhoneSimulator.platform/Developer/Library/Frameworks/XCTest.framework/Headers/XCTestSuite.h /Applications/Xcode.app/Contents/Developer/Platforms/iPhoneSimulator.platform/Developer/Library/Frameworks/XCTest.framework/Headers/XCTestProbe.h /Applications/Xcode.app/Contents/Developer/Platforms/iPhoneSimulator.platform/Developer/Library/Frameworks/XCTest.framework/Headers/XCTestObserver.h /Applications/Xcode.app/Contents/Developer/Platforms/iPhoneSimulator.platform/Developer/Library/Frameworks/XCTest.framework/Headers/XCTestLog.h /Applications/Xcode.app/Contents/Developer/Platforms/iPhoneSimulator.platform/Developer/Library/Frameworks/XCTest.framework/Headers/XCTestErrors.h /Applications/Xcode.app/Contents/Developer/Platforms/iPhoneSimulator.platform/Developer/Library/Frameworks/XCTest.framework/Headers/XCTestRun.h /Applications/Xcode.app/Contents/Developer/Platforms/iPhoneSimulator.platform/Developer/Library/Frameworks/XCTest.framework/Headers/XCTestCaseRun.h /Applications/Xcode.app/Contents/Developer/Platforms/iPhoneSimulator.platform/Developer/Library/Frameworks/XCTest.framework/Headers/XCTestCase+AsynchronousTesting.h /Applications/Xcode.app/Contents/Developer/Platforms/iPhoneSimulator.platform/Developer/Library/Frameworks/XCTest.framework/Headers/XCTestDefines.h /Applications/Xcode.app/Contents/Developer/Platforms/iPhoneSimulator.platform/Developer/Library/Frameworks/XCTest.framework/Headers/XCTestCase.h /Applications/Xcode.app/Contents/Developer/Platforms/iPhoneSimulator.platform/Developer/Library/Frameworks/XCTest.framework/Headers/XCTestAssertionsImpl.h /Applications/Xcode.app/Contents/Developer/Platforms/iPhoneSimulator.platform/Developer/Library/Frameworks/XCTest.framework/Headers/XCTestAssertions.h /Applications/Xcode.app/Contents/Developer/Platforms/iPhoneSimulator.platform/Developer/Library/Frameworks/XCTest.framework/Headers/XCAbstractTest.h /Applications/Xcode.app/Contents/Developer/Platforms/iPhoneSimulator.platform/Developer/Library/Frameworks/XCTest.framework/Headers/XCTest.h /Applications/Xcode.app/Contents/Developer/Platforms/iPhoneSimulator.platform/Developer/Library/Frameworks/XCTest.framework/module.map
/Users/mickaeljordan/Desktop/Citizen/DerivedData/Citizen/Build/Intermediates/Citizen.build/Debug-iphonesimulator/CitizenTests.build/Objects-normal/x86_64/CitizenTests~partial.swiftmodule : /Users/mickaeljordan/Desktop/Citizen/CitizenTests/CitizenTests.swift /Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/lib/swift/iphonesimulator/Swift.swiftmodule /Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/lib/swift/iphonesimulator/UIKit.swiftmodule /Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/lib/swift/iphonesimulator/Foundation.swiftmodule /Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/lib/swift/iphonesimulator/Darwin.swiftmodule /Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/lib/swift/iphonesimulator/Dispatch.swiftmodule /Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/lib/swift/iphonesimulator/ObjectiveC.swiftmodule /Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/lib/swift/iphonesimulator/CoreGraphics.swiftmodule /Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/lib/swift/iphonesimulator/Security.swiftmodule /Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/lib/swift/iphonesimulator/CoreImage.swiftmodule /Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/lib/swift/iphonesimulator/XCTest.swiftmodule /Applications/Xcode.app/Contents/Developer/Platforms/iPhoneSimulator.platform/Developer/Library/Frameworks/XCTest.framework/Headers/XCTestSuiteRun.h /Applications/Xcode.app/Contents/Developer/Platforms/iPhoneSimulator.platform/Developer/Library/Frameworks/XCTest.framework/Headers/XCTestSuite.h /Applications/Xcode.app/Contents/Developer/Platforms/iPhoneSimulator.platform/Developer/Library/Frameworks/XCTest.framework/Headers/XCTestProbe.h /Applications/Xcode.app/Contents/Developer/Platforms/iPhoneSimulator.platform/Developer/Library/Frameworks/XCTest.framework/Headers/XCTestObserver.h /Applications/Xcode.app/Contents/Developer/Platforms/iPhoneSimulator.platform/Developer/Library/Frameworks/XCTest.framework/Headers/XCTestLog.h /Applications/Xcode.app/Contents/Developer/Platforms/iPhoneSimulator.platform/Developer/Library/Frameworks/XCTest.framework/Headers/XCTestErrors.h /Applications/Xcode.app/Contents/Developer/Platforms/iPhoneSimulator.platform/Developer/Library/Frameworks/XCTest.framework/Headers/XCTestRun.h /Applications/Xcode.app/Contents/Developer/Platforms/iPhoneSimulator.platform/Developer/Library/Frameworks/XCTest.framework/Headers/XCTestCaseRun.h /Applications/Xcode.app/Contents/Developer/Platforms/iPhoneSimulator.platform/Developer/Library/Frameworks/XCTest.framework/Headers/XCTestCase+AsynchronousTesting.h /Applications/Xcode.app/Contents/Developer/Platforms/iPhoneSimulator.platform/Developer/Library/Frameworks/XCTest.framework/Headers/XCTestDefines.h /Applications/Xcode.app/Contents/Developer/Platforms/iPhoneSimulator.platform/Developer/Library/Frameworks/XCTest.framework/Headers/XCTestCase.h /Applications/Xcode.app/Contents/Developer/Platforms/iPhoneSimulator.platform/Developer/Library/Frameworks/XCTest.framework/Headers/XCTestAssertionsImpl.h /Applications/Xcode.app/Contents/Developer/Platforms/iPhoneSimulator.platform/Developer/Library/Frameworks/XCTest.framework/Headers/XCTestAssertions.h /Applications/Xcode.app/Contents/Developer/Platforms/iPhoneSimulator.platform/Developer/Library/Frameworks/XCTest.framework/Headers/XCAbstractTest.h /Applications/Xcode.app/Contents/Developer/Platforms/iPhoneSimulator.platform/Developer/Library/Frameworks/XCTest.framework/Headers/XCTest.h /Applications/Xcode.app/Contents/Developer/Platforms/iPhoneSimulator.platform/Developer/Library/Frameworks/XCTest.framework/module.map
/Users/mickaeljordan/Desktop/Citizen/DerivedData/Citizen/Build/Intermediates/Citizen.build/Debug-iphonesimulator/CitizenTests.build/Objects-normal/x86_64/CitizenTests~partial.swiftdoc : /Users/mickaeljordan/Desktop/Citizen/CitizenTests/CitizenTests.swift /Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/lib/swift/iphonesimulator/Swift.swiftmodule /Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/lib/swift/iphonesimulator/UIKit.swiftmodule /Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/lib/swift/iphonesimulator/Foundation.swiftmodule /Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/lib/swift/iphonesimulator/Darwin.swiftmodule /Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/lib/swift/iphonesimulator/Dispatch.swiftmodule /Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/lib/swift/iphonesimulator/ObjectiveC.swiftmodule /Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/lib/swift/iphonesimulator/CoreGraphics.swiftmodule /Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/lib/swift/iphonesimulator/Security.swiftmodule /Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/lib/swift/iphonesimulator/CoreImage.swiftmodule /Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/lib/swift/iphonesimulator/XCTest.swiftmodule /Applications/Xcode.app/Contents/Developer/Platforms/iPhoneSimulator.platform/Developer/Library/Frameworks/XCTest.framework/Headers/XCTestSuiteRun.h /Applications/Xcode.app/Contents/Developer/Platforms/iPhoneSimulator.platform/Developer/Library/Frameworks/XCTest.framework/Headers/XCTestSuite.h /Applications/Xcode.app/Contents/Developer/Platforms/iPhoneSimulator.platform/Developer/Library/Frameworks/XCTest.framework/Headers/XCTestProbe.h /Applications/Xcode.app/Contents/Developer/Platforms/iPhoneSimulator.platform/Developer/Library/Frameworks/XCTest.framework/Headers/XCTestObserver.h /Applications/Xcode.app/Contents/Developer/Platforms/iPhoneSimulator.platform/Developer/Library/Frameworks/XCTest.framework/Headers/XCTestLog.h /Applications/Xcode.app/Contents/Developer/Platforms/iPhoneSimulator.platform/Developer/Library/Frameworks/XCTest.framework/Headers/XCTestErrors.h /Applications/Xcode.app/Contents/Developer/Platforms/iPhoneSimulator.platform/Developer/Library/Frameworks/XCTest.framework/Headers/XCTestRun.h /Applications/Xcode.app/Contents/Developer/Platforms/iPhoneSimulator.platform/Developer/Library/Frameworks/XCTest.framework/Headers/XCTestCaseRun.h /Applications/Xcode.app/Contents/Developer/Platforms/iPhoneSimulator.platform/Developer/Library/Frameworks/XCTest.framework/Headers/XCTestCase+AsynchronousTesting.h /Applications/Xcode.app/Contents/Developer/Platforms/iPhoneSimulator.platform/Developer/Library/Frameworks/XCTest.framework/Headers/XCTestDefines.h /Applications/Xcode.app/Contents/Developer/Platforms/iPhoneSimulator.platform/Developer/Library/Frameworks/XCTest.framework/Headers/XCTestCase.h /Applications/Xcode.app/Contents/Developer/Platforms/iPhoneSimulator.platform/Developer/Library/Frameworks/XCTest.framework/Headers/XCTestAssertionsImpl.h /Applications/Xcode.app/Contents/Developer/Platforms/iPhoneSimulator.platform/Developer/Library/Frameworks/XCTest.framework/Headers/XCTestAssertions.h /Applications/Xcode.app/Contents/Developer/Platforms/iPhoneSimulator.platform/Developer/Library/Frameworks/XCTest.framework/Headers/XCAbstractTest.h /Applications/Xcode.app/Contents/Developer/Platforms/iPhoneSimulator.platform/Developer/Library/Frameworks/XCTest.framework/Headers/XCTest.h /Applications/Xcode.app/Contents/Developer/Platforms/iPhoneSimulator.platform/Developer/Library/Frameworks/XCTest.framework/module.map
| D |
/**
BSON serialization and value handling.
Copyright: © 2012-2015 Sönke Ludwig
License: Subject to the terms of the MIT license, as written in the included LICENSE.txt file.
Authors: Sönke Ludwig
*/
module vibe.data.bson;
///
unittest {
void manipulateBson(Bson b)
{
import std.stdio;
// retrieving the values is done using get()
assert(b["name"].get!string == "Example");
assert(b["id"].get!int == 1);
// semantic conversions can be done using to()
assert(b["id"].to!string == "1");
// prints:
// name: "Example"
// id: 1
foreach (string key, value; b)
writefln("%s: %s", key, value);
// print out with JSON syntax: {"name": "Example", "id": 1}
writefln("BSON: %s", b.toString());
// DEPRECATED: object members can be accessed using member syntax, just like in JavaScript
//j = Bson.emptyObject;
//j.name = "Example";
//j.id = 1;
}
}
/// Constructing `Bson` objects
unittest {
// construct a BSON object {"field1": "foo", "field2": 42, "field3": true}
// using the constructor
Bson b1 = Bson(["field1": Bson("foo"), "field2": Bson(42), "field3": Bson(true)]);
// using piecewise construction
Bson b2 = Bson.emptyObject;
b2["field1"] = "foo";
b2["field2"] = 42;
b2["field3"] = true;
// using serialization
struct S {
string field1;
int field2;
bool field3;
}
Bson b3 = S("foo", 42, true).serializeToBson();
}
public import vibe.data.json;
import std.algorithm;
import std.array;
import std.base64;
import std.bitmanip;
import std.conv;
import std.datetime;
import std.uuid: UUID;
import std.exception;
import std.range;
import std.traits;
import std.typecons : Tuple, tuple;
alias bdata_t = immutable(ubyte)[];
/**
Represents a BSON value.
*/
struct Bson {
@safe:
/// Represents the type of a BSON value
enum Type : ubyte {
end = 0x00, /// End marker - should never occur explicitly
double_ = 0x01, /// A 64-bit floating point value
string = 0x02, /// A UTF-8 string
object = 0x03, /// An object aka. dictionary of string to Bson
array = 0x04, /// An array of BSON values
binData = 0x05, /// Raw binary data (ubyte[])
undefined = 0x06, /// Deprecated
objectID = 0x07, /// BSON Object ID (96-bit)
bool_ = 0x08, /// Boolean value
date = 0x09, /// Date value (UTC)
null_ = 0x0A, /// Null value
regex = 0x0B, /// Regular expression
dbRef = 0x0C, /// Deprecated
code = 0x0D, /// JaveScript code
symbol = 0x0E, /// Symbol/variable name
codeWScope = 0x0F, /// JavaScript code with scope
int_ = 0x10, /// 32-bit integer
timestamp = 0x11, /// Timestamp value
long_ = 0x12, /// 64-bit integer
minKey = 0xff, /// Internal value
maxKey = 0x7f, /// Internal value
End = end, /// Compatibility alias - will be deprecated soon.
Double = double_, /// Compatibility alias - will be deprecated soon.
String = string, /// Compatibility alias - will be deprecated soon.
Object = object, /// Compatibility alias - will be deprecated soon.
Array = array, /// Compatibility alias - will be deprecated soon.
BinData = binData, /// Compatibility alias - will be deprecated soon.
Undefined = undefined, /// Compatibility alias - will be deprecated soon.
ObjectID = objectID, /// Compatibility alias - will be deprecated soon.
Bool = bool_, /// Compatibility alias - will be deprecated soon.
Date = date, /// Compatibility alias - will be deprecated soon.
Null = null_, /// Compatibility alias - will be deprecated soon.
Regex = regex, /// Compatibility alias - will be deprecated soon.
DBRef = dbRef, /// Compatibility alias - will be deprecated soon.
Code = code, /// Compatibility alias - will be deprecated soon.
Symbol = symbol, /// Compatibility alias - will be deprecated soon.
CodeWScope = codeWScope, /// Compatibility alias - will be deprecated soon.
Int = int_, /// Compatibility alias - will be deprecated soon.
Timestamp = timestamp, /// Compatibility alias - will be deprecated soon.
Long = long_, /// Compatibility alias - will be deprecated soon.
MinKey = minKey, /// Compatibility alias - will be deprecated soon.
MaxKey = maxKey /// Compatibility alias - will be deprecated soon.
}
/// Returns a new, empty Bson value of type Object.
static @property Bson emptyObject() { return Bson(cast(Bson[string])null); }
/// Returns a new, empty Bson value of type Array.
static @property Bson emptyArray() { return Bson(cast(Bson[])null); }
private {
Type m_type = Type.undefined;
bdata_t m_data;
}
/**
Creates a new BSON value using raw data.
A slice of the first bytes of `data` is stored, containg the data related to the value. An
exception is thrown if `data` is too short.
*/
this(Type type, bdata_t data)
{
m_type = type;
m_data = data;
final switch(type){
case Type.end: m_data = null; break;
case Type.double_: m_data = m_data[0 .. 8]; break;
case Type.string: m_data = m_data[0 .. 4 + fromBsonData!int(m_data)]; break;
case Type.object: m_data = m_data[0 .. fromBsonData!int(m_data)]; break;
case Type.array: m_data = m_data[0 .. fromBsonData!int(m_data)]; break;
case Type.binData: m_data = m_data[0 .. 5 + fromBsonData!int(m_data)]; break;
case Type.undefined: m_data = null; break;
case Type.objectID: m_data = m_data[0 .. 12]; break;
case Type.bool_: m_data = m_data[0 .. 1]; break;
case Type.date: m_data = m_data[0 .. 8]; break;
case Type.null_: m_data = null; break;
case Type.regex:
auto tmp = m_data;
tmp.skipCString();
tmp.skipCString();
m_data = m_data[0 .. $ - tmp.length];
break;
case Type.dbRef: m_data = m_data[0 .. 0]; assert(false, "Not implemented.");
case Type.code: m_data = m_data[0 .. 4 + fromBsonData!int(m_data)]; break;
case Type.symbol: m_data = m_data[0 .. 4 + fromBsonData!int(m_data)]; break;
case Type.codeWScope: m_data = m_data[0 .. 0]; assert(false, "Not implemented.");
case Type.int_: m_data = m_data[0 .. 4]; break;
case Type.timestamp: m_data = m_data[0 .. 8]; break;
case Type.long_: m_data = m_data[0 .. 8]; break;
case Type.minKey: m_data = null; break;
case Type.maxKey: m_data = null; break;
}
}
/**
Initializes a new BSON value from the given D type.
*/
this(double value) { opAssign(value); }
/// ditto
this(string value, Type type = Type.string)
{
assert(type == Type.string || type == Type.code || type == Type.symbol);
opAssign(value);
m_type = type;
}
/// ditto
this(in Bson[string] value) { opAssign(value); }
/// ditto
this(in Bson[] value) { opAssign(value); }
/// ditto
this(in BsonBinData value) { opAssign(value); }
/// ditto
this(in BsonObjectID value) { opAssign(value); }
/// ditto
this(bool value) { opAssign(value); }
/// ditto
this(in BsonDate value) { opAssign(value); }
/// ditto
this(typeof(null)) { opAssign(null); }
/// ditto
this(in BsonRegex value) { opAssign(value); }
/// ditto
this(int value) { opAssign(value); }
/// ditto
this(in BsonTimestamp value) { opAssign(value); }
/// ditto
this(long value) { opAssign(value); }
/// ditto
this(in Json value) { opAssign(value); }
/// ditto
this(in UUID value) { opAssign(value); }
/**
Assigns a D type to a BSON value.
*/
void opAssign(in Bson other)
{
m_data = other.m_data;
m_type = other.m_type;
}
/// ditto
void opAssign(double value)
{
m_data = toBsonData(value).idup;
m_type = Type.double_;
}
/// ditto
void opAssign(string value)
{
import std.utf;
debug std.utf.validate(value);
auto app = appender!bdata_t();
app.put(toBsonData(cast(int)value.length+1));
app.put(cast(bdata_t)value);
app.put(cast(ubyte)0);
m_data = app.data;
m_type = Type.string;
}
/// ditto
void opAssign(in Bson[string] value)
{
auto app = appender!bdata_t();
foreach( k, ref v; value ){
app.put(cast(ubyte)v.type);
putCString(app, k);
app.put(v.data);
}
auto dapp = appender!bdata_t();
dapp.put(toBsonData(cast(int)app.data.length+5));
dapp.put(app.data);
dapp.put(cast(ubyte)0);
m_data = dapp.data;
m_type = Type.object;
}
/// ditto
void opAssign(in Bson[] value)
{
auto app = appender!bdata_t();
foreach( i, ref v; value ){
app.put(v.type);
putCString(app, to!string(i));
app.put(v.data);
}
auto dapp = appender!bdata_t();
dapp.put(toBsonData(cast(int)app.data.length+5));
dapp.put(app.data);
dapp.put(cast(ubyte)0);
m_data = dapp.data;
m_type = Type.array;
}
/// ditto
void opAssign(in BsonBinData value)
{
auto app = appender!bdata_t();
app.put(toBsonData(cast(int)value.rawData.length));
app.put(value.type);
app.put(value.rawData);
m_data = app.data;
m_type = Type.binData;
}
/// ditto
void opAssign(in BsonObjectID value)
{
m_data = value.m_bytes.idup;
m_type = Type.objectID;
}
/// ditto
void opAssign(bool value)
{
m_data = [value ? 0x01 : 0x00];
m_type = Type.bool_;
}
/// ditto
void opAssign(in BsonDate value)
{
m_data = toBsonData(value.m_time).idup;
m_type = Type.date;
}
/// ditto
void opAssign(typeof(null))
{
m_data = null;
m_type = Type.null_;
}
/// ditto
void opAssign(in BsonRegex value)
{
auto app = appender!bdata_t();
putCString(app, value.expression);
putCString(app, value.options);
m_data = app.data;
m_type = type.regex;
}
/// ditto
void opAssign(int value)
{
m_data = toBsonData(value).idup;
m_type = Type.int_;
}
/// ditto
void opAssign(in BsonTimestamp value)
{
m_data = toBsonData(value.m_time).idup;
m_type = Type.timestamp;
}
/// ditto
void opAssign(long value)
{
m_data = toBsonData(value).idup;
m_type = Type.long_;
}
/// ditto
void opAssign(in Json value)
@trusted {
auto app = appender!bdata_t();
m_type = writeBson(app, value);
m_data = app.data;
}
/// ditto
void opAssign(in UUID value)
{
opAssign(BsonBinData(BsonBinData.Type.uuid, value.data.idup));
}
/**
Returns the BSON type of this value.
*/
@property Type type() const { return m_type; }
bool isNull() const { return m_type == Type.null_; }
/**
Returns the raw data representing this BSON value (not including the field name and type).
*/
@property bdata_t data() const { return m_data; }
/**
Converts the BSON value to a D value.
If the BSON type of the value does not match the D type, an exception is thrown.
See_Also: `deserializeBson`, `opt`
*/
T opCast(T)() const { return get!T(); }
/// ditto
@property T get(T)()
const {
static if( is(T == double) ){ checkType(Type.double_); return fromBsonData!double(m_data); }
else static if( is(T == string) ){
checkType(Type.string, Type.code, Type.symbol);
return cast(string)m_data[4 .. 4+fromBsonData!int(m_data)-1];
}
else static if( is(Unqual!T == Bson[string]) || is(Unqual!T == const(Bson)[string]) ){
checkType(Type.object);
Bson[string] ret;
auto d = m_data[4 .. $];
while( d.length > 0 ){
auto tp = cast(Type)d[0];
if( tp == Type.end ) break;
d = d[1 .. $];
auto key = skipCString(d);
auto value = Bson(tp, d);
d = d[value.data.length .. $];
ret[key] = value;
}
return cast(T)ret;
}
else static if( is(Unqual!T == Bson[]) || is(Unqual!T == const(Bson)[]) ){
checkType(Type.array);
Bson[] ret;
auto d = m_data[4 .. $];
while( d.length > 0 ){
auto tp = cast(Type)d[0];
if( tp == Type.end ) break;
/*auto key = */skipCString(d); // should be '0', '1', ...
auto value = Bson(tp, d);
d = d[value.data.length .. $];
ret ~= value;
}
return cast(T)ret;
}
else static if( is(T == BsonBinData) ){
checkType(Type.binData);
auto size = fromBsonData!int(m_data);
auto type = cast(BsonBinData.Type)m_data[4];
return BsonBinData(type, m_data[5 .. 5+size]);
}
else static if( is(T == BsonObjectID) ){ checkType(Type.objectID); return BsonObjectID(m_data[0 .. 12]); }
else static if( is(T == bool) ){ checkType(Type.bool_); return m_data[0] != 0; }
else static if( is(T == BsonDate) ){ checkType(Type.date); return BsonDate(fromBsonData!long(m_data)); }
else static if( is(T == SysTime) ){
checkType(Type.date);
string data = cast(string)m_data[4 .. 4+fromBsonData!int(m_data)-1];
return SysTime.fromISOString(data);
}
else static if( is(T == BsonRegex) ){
checkType(Type.regex);
auto d = m_data[0 .. $];
auto expr = skipCString(d);
auto options = skipCString(d);
return BsonRegex(expr, options);
}
else static if( is(T == int) ){ checkType(Type.int_); return fromBsonData!int(m_data); }
else static if( is(T == BsonTimestamp) ){ checkType(Type.timestamp); return BsonTimestamp(fromBsonData!long(m_data)); }
else static if( is(T == long) ){ checkType(Type.long_); return fromBsonData!long(m_data); }
else static if( is(T == Json) ){
pragma(msg, "Bson.get!Json() and Bson.opCast!Json() will soon be removed. Please use Bson.toJson() instead.");
return this.toJson();
}
else static if( is(T == UUID) ){
checkType(Type.binData);
auto bbd = this.get!BsonBinData();
enforce(bbd.type == BsonBinData.Type.uuid, "BsonBinData value is type '"~to!string(bbd.type)~"', expected to be uuid");
const ubyte[16] b = bbd.rawData;
return UUID(b);
}
else static if( is(T == SysTime) ) {
checkType(Type.date);
return BsonDate(fromBsonData!long(m_data)).toSysTime();
}
else static assert(false, "Cannot cast "~typeof(this).stringof~" to '"~T.stringof~"'.");
}
/** Returns the native type for this BSON if it matches the current runtime type.
If the runtime type does not match the given native type, the 'def' parameter is returned
instead.
*/
T opt(T)(T def = T.init)
{
if (isNull()) return def;
try return cast(T)this;
catch (Exception e) return def;
}
/// ditto
const(T) opt(T)(const(T) def = const(T).init)
const {
if (isNull()) return def;
try return cast(T)this;
catch (Exception e) return def;
}
/** Returns the length of a BSON value of type String, Array, Object or BinData.
*/
@property size_t length() const {
switch( m_type ){
default: enforce(false, "Bson objects of type "~to!string(m_type)~" do not have a length field."); break;
case Type.string, Type.code, Type.symbol: return (cast(string)this).length;
case Type.array: return byValue.walkLength;
case Type.object: return byValue.walkLength;
case Type.binData: assert(false); //return (cast(BsonBinData)this).length; break;
}
assert(false);
}
/** Converts a given JSON value to the corresponding BSON value.
*/
static Bson fromJson(in Json value)
@trusted {
auto app = appender!bdata_t();
auto tp = writeBson(app, value);
return Bson(tp, app.data);
}
/** Converts a BSON value to a JSON value.
All BSON types that cannot be exactly represented as JSON, will
be converted to a string.
*/
Json toJson()
const {
switch( this.type ){
default: assert(false);
case Bson.Type.double_: return Json(get!double());
case Bson.Type.string: return Json(get!string());
case Bson.Type.object:
Json[string] ret;
foreach (k, v; this.byKeyValue)
ret[k] = v.toJson();
return Json(ret);
case Bson.Type.array:
auto ret = new Json[this.length];
foreach (i, v; this.byIndexValue)
ret[i] = v.toJson();
return Json(ret);
case Bson.Type.binData: return Json(() @trusted { return cast(string)Base64.encode(get!BsonBinData.rawData); } ());
case Bson.Type.objectID: return Json(get!BsonObjectID().toString());
case Bson.Type.bool_: return Json(get!bool());
case Bson.Type.date: return Json(get!BsonDate.toString());
case Bson.Type.null_: return Json(null);
case Bson.Type.regex: assert(false, "TODO");
case Bson.Type.dbRef: assert(false, "TODO");
case Bson.Type.code: return Json(get!string());
case Bson.Type.symbol: return Json(get!string());
case Bson.Type.codeWScope: assert(false, "TODO");
case Bson.Type.int_: return Json(get!int());
case Bson.Type.timestamp: return Json(get!BsonTimestamp().m_time);
case Bson.Type.long_: return Json(get!long());
case Bson.Type.undefined: return Json();
}
}
/** Returns a string representation of this BSON value in JSON format.
*/
string toString()
const {
return toJson().toString();
}
import std.typecons : Nullable;
/**
Check whether the BSON object contains the given key.
*/
Nullable!Bson tryIndex(string key) const {
checkType(Type.object);
foreach (string idx, v; this.byKeyValue)
if(idx == key)
return Nullable!Bson(v);
return Nullable!Bson.init;
}
/** Allows accessing fields of a BSON object using `[]`.
Returns a null value if the specified field does not exist.
*/
inout(Bson) opIndex(string idx) inout {
foreach (string key, v; this.byKeyValue)
if( key == idx )
return v;
return Bson(null);
}
/// ditto
void opIndexAssign(T)(in T value, string idx){
// WARNING: it is ABSOLUTELY ESSENTIAL that ordering is not changed!!!
// MongoDB depends on ordering of the Bson maps.
auto newcont = appender!bdata_t();
checkType(Type.object);
auto d = m_data[4 .. $];
while( d.length > 0 ){
auto tp = cast(Type)d[0];
if( tp == Type.end ) break;
d = d[1 .. $];
auto key = skipCString(d);
auto val = Bson(tp, d);
d = d[val.data.length .. $];
if( key != idx ){
// copy to new array
newcont.put(cast(ubyte)tp);
putCString(newcont, key);
newcont.put(val.data);
}
}
static if( is(T == Bson) )
alias bval = value;
else
auto bval = Bson(value);
newcont.put(cast(ubyte)bval.type);
putCString(newcont, idx);
newcont.put(bval.data);
auto newdata = appender!bdata_t();
newdata.put(toBsonData(cast(uint)(newcont.data.length + 5)));
newdata.put(newcont.data);
newdata.put(cast(ubyte)0);
m_data = newdata.data;
}
///
unittest {
Bson value = Bson.emptyObject;
value["a"] = 1;
value["b"] = true;
value["c"] = "foo";
assert(value["a"] == Bson(1));
assert(value["b"] == Bson(true));
assert(value["c"] == Bson("foo"));
}
///
unittest {
auto srcUuid = UUID("00010203-0405-0607-0809-0a0b0c0d0e0f");
Bson b = srcUuid;
auto u = b.get!UUID();
assert(b.type == Bson.Type.binData);
assert(b.get!BsonBinData().type == BsonBinData.Type.uuid);
assert(u == srcUuid);
}
/** Allows index based access of a BSON array value.
Returns a null value if the index is out of bounds.
*/
inout(Bson) opIndex(size_t idx) inout {
foreach (size_t i, v; this.byIndexValue)
if (i == idx)
return v;
return Bson(null);
}
///
unittest {
Bson[] entries;
entries ~= Bson(1);
entries ~= Bson(true);
entries ~= Bson("foo");
Bson value = Bson(entries);
assert(value[0] == Bson(1));
assert(value[1] == Bson(true));
assert(value[2] == Bson("foo"));
}
/** Removes an entry from a BSON obect.
If the key doesn't exit, this function will be a no-op.
*/
void remove(string key)
{
checkType(Type.object);
auto d = m_data[4 .. $];
while (d.length > 0) {
size_t start_remainder = d.length;
auto tp = cast(Type)d[0];
if (tp == Type.end) break;
d = d[1 .. $];
auto ekey = skipCString(d);
auto evalue = Bson(tp, d);
d = d[evalue.data.length .. $];
if (ekey == key) {
m_data = m_data[0 .. $-start_remainder] ~ d;
break;
}
}
}
unittest {
auto o = Bson.emptyObject;
o["a"] = Bson(1);
o["b"] = Bson(2);
o["c"] = Bson(3);
assert(o.length == 3);
o.remove("b");
assert(o.length == 2);
assert(o["a"] == Bson(1));
assert(o["c"] == Bson(3));
o.remove("c");
assert(o.length == 1);
assert(o["a"] == Bson(1));
o.remove("c");
assert(o.length == 1);
assert(o["a"] == Bson(1));
o.remove("a");
assert(o.length == 0);
}
/**
Allows foreach iterating over BSON objects and arrays.
*/
int opApply(scope int delegate(Bson obj) del)
const @system {
foreach (value; byValue)
if (auto ret = del(value))
return ret;
return 0;
}
/// ditto
int opApply(scope int delegate(size_t idx, Bson obj) del)
const @system {
foreach (index, value; byIndexValue)
if (auto ret = del(index, value))
return ret;
return 0;
}
/// ditto
int opApply(scope int delegate(string idx, Bson obj) del)
const @system {
foreach (key, value; byKeyValue)
if (auto ret = del(key, value))
return ret;
return 0;
}
/// Iterates over all values of an object or array.
auto byValue() const { checkType(Type.array, Type.object); return byKeyValueImpl().map!(t => t[1]); }
/// Iterates over all index/value pairs of an array.
auto byIndexValue() const { checkType(Type.array); return byKeyValueImpl().map!(t => Tuple!(size_t, "key", Bson, "value")(t[0].to!size_t, t[1])); }
/// Iterates over all key/value pairs of an object.
auto byKeyValue() const { checkType(Type.object); return byKeyValueImpl(); }
private auto byKeyValueImpl()
const {
checkType(Type.object, Type.array);
alias T = Tuple!(string, "key", Bson, "value");
static struct Rng {
private {
immutable(ubyte)[] data;
string key;
Bson value;
}
@property bool empty() const { return data.length == 0; }
@property T front() { return T(key, value); }
@property Rng save() const { return this; }
void popFront()
{
auto tp = cast(Type)data[0];
data = data[1 .. $];
if (tp == Type.end) return;
key = skipCString(data);
value = Bson(tp, data);
data = data[value.data.length .. $];
}
}
auto ret = Rng(m_data[4 .. $]);
ret.popFront();
return ret;
}
///
bool opEquals(ref const Bson other) const {
if( m_type != other.m_type ) return false;
if (m_type != Type.object)
return m_data == other.m_data;
if (m_data == other.m_data)
return true;
// Similar objects can have a different key order, but they must have a same length
if (m_data.length != other.m_data.length)
return false;
foreach (k, ref v; this.byKeyValue)
{
if (other[k] != v)
return false;
}
return true;
}
/// ditto
bool opEquals(const Bson other) const {
if( m_type != other.m_type ) return false;
return opEquals(other);
}
private void checkType(in Type[] valid_types...)
const {
foreach( t; valid_types )
if( m_type == t )
return;
throw new Exception("BSON value is type '"~to!string(m_type)~"', expected to be one of "~to!string(valid_types));
}
}
/**
Represents a BSON binary data value (Bson.Type.binData).
*/
struct BsonBinData {
@safe:
enum Type : ubyte {
generic = 0x00,
function_ = 0x01,
binaryOld = 0x02,
uuid = 0x03,
md5 = 0x05,
userDefined = 0x80,
Generic = generic, /// Compatibility alias - will be deprecated soon
Function = function_, /// Compatibility alias - will be deprecated soon
BinaryOld = binaryOld, /// Compatibility alias - will be deprecated soon
UUID = uuid, /// Compatibility alias - will be deprecated soon
MD5 = md5, /// Compatibility alias - will be deprecated soon
UserDefined = userDefined, /// Compatibility alias - will be deprecated soon
}
private {
Type m_type;
bdata_t m_data;
}
this(Type type, immutable(ubyte)[] data)
{
m_type = type;
m_data = data;
}
@property Type type() const { return m_type; }
@property bdata_t rawData() const { return m_data; }
}
/**
Represents a BSON object id (Bson.Type.binData).
*/
struct BsonObjectID {
@safe:
private {
ubyte[12] m_bytes;
static immutable uint MACHINE_ID;
static immutable int ms_pid;
static uint ms_inc = 0;
}
shared static this()
{
import std.process;
import std.random;
MACHINE_ID = uniform(0, 0xffffff);
ms_pid = thisProcessID;
}
static this()
{
import std.random;
ms_inc = uniform(0, 0xffffff);
}
/** Constructs a new object ID from the given raw byte array.
*/
this(in ubyte[] bytes)
{
assert(bytes.length == 12);
m_bytes[] = bytes[];
}
/** Creates an on object ID from a string in standard hexa-decimal form.
*/
static BsonObjectID fromString(string str)
{
import std.conv : ConvException;
static const lengthex = new ConvException("BSON Object ID string must be 24 characters.");
static const charex = new ConvException("Not a valid hex string.");
if (str.length != 24) throw lengthex;
BsonObjectID ret = void;
uint b = 0;
foreach( i, ch; str ){
ubyte n;
if( ch >= '0' && ch <= '9' ) n = cast(ubyte)(ch - '0');
else if( ch >= 'a' && ch <= 'f' ) n = cast(ubyte)(ch - 'a' + 10);
else if( ch >= 'A' && ch <= 'F' ) n = cast(ubyte)(ch - 'F' + 10);
else throw charex;
b <<= 4;
b += n;
if( i % 8 == 7 ){
auto j = i / 8;
ret.m_bytes[j*4 .. (j+1)*4] = toBigEndianData(b)[];
b = 0;
}
}
return ret;
}
/// ditto
alias fromHexString = fromString;
/** Generates a unique object ID.
*
* By default it will use `Clock.currTime(UTC())` as the timestamp
* which guarantees that `BsonObjectID`s are chronologically
* sorted.
*/
static BsonObjectID generate(in SysTime time = Clock.currTime(UTC()))
{
import std.datetime;
BsonObjectID ret = void;
ret.m_bytes[0 .. 4] = toBigEndianData(cast(uint)time.toUnixTime())[];
ret.m_bytes[4 .. 7] = toBsonData(MACHINE_ID)[0 .. 3];
ret.m_bytes[7 .. 9] = toBsonData(cast(ushort)ms_pid)[];
ret.m_bytes[9 .. 12] = toBigEndianData(ms_inc++)[1 .. 4];
return ret;
}
/** Creates a pseudo object ID that matches the given date.
This kind of ID can be useful to query a database for items in a certain
date interval using their ID. This works using the property of standard BSON
object IDs that they store their creation date as part of the ID. Note that
this date part is only 32-bit wide and is limited to the same timespan as a
32-bit Unix timestamp.
*/
static BsonObjectID createDateID(in SysTime time)
{
BsonObjectID ret;
ret.m_bytes[0 .. 4] = toBigEndianData(cast(uint)time.toUnixTime())[];
return ret;
}
/** Returns true for any non-zero ID.
*/
@property bool valid() const {
foreach( b; m_bytes )
if( b != 0 )
return true;
return false;
}
/** Extracts the time/date portion of the object ID.
For IDs created using the standard generation algorithm or using createDateID
this will return the associated time stamp.
*/
@property SysTime timeStamp()
const {
ubyte[4] tm = m_bytes[0 .. 4];
return SysTime(unixTimeToStdTime(bigEndianToNative!uint(tm)));
}
/** Allows for relational comparison of different IDs.
*/
int opCmp(ref const BsonObjectID other)
const {
import core.stdc.string;
return () @trusted { return memcmp(m_bytes.ptr, other.m_bytes.ptr, m_bytes.length); } ();
}
/** Converts the ID to its standard hexa-decimal string representation.
*/
string toString() const pure {
enum hexdigits = "0123456789abcdef";
auto ret = new char[24];
foreach( i, b; m_bytes ){
ret[i*2+0] = hexdigits[(b >> 4) & 0x0F];
ret[i*2+1] = hexdigits[b & 0x0F];
}
return ret;
}
inout(ubyte)[] opCast() inout { return m_bytes; }
}
unittest {
auto t0 = SysTime(Clock.currTime(UTC()).toUnixTime.unixTimeToStdTime);
auto id = BsonObjectID.generate();
auto t1 = SysTime(Clock.currTime(UTC()).toUnixTime.unixTimeToStdTime);
assert(t0 <= id.timeStamp);
assert(id.timeStamp <= t1);
id = BsonObjectID.generate(t0);
assert(id.timeStamp == t0);
id = BsonObjectID.generate(t1);
assert(id.timeStamp == t1);
immutable dt = DateTime(2014, 07, 31, 19, 14, 55);
id = BsonObjectID.generate(SysTime(dt, UTC()));
assert(id.timeStamp == SysTime(dt, UTC()));
}
unittest {
auto b = Bson(true);
assert(b.opt!bool(false) == true);
assert(b.opt!int(12) == 12);
assert(b.opt!(Bson[])(null).length == 0);
const c = b;
assert(c.opt!bool(false) == true);
assert(c.opt!int(12) == 12);
assert(c.opt!(Bson[])(null).length == 0);
}
/**
Represents a BSON date value (`Bson.Type.date`).
BSON date values are stored in UNIX time format, counting the number of
milliseconds from 1970/01/01.
*/
struct BsonDate {
@safe:
private long m_time; // milliseconds since UTC unix epoch
/** Constructs a BsonDate from the given date value.
The time-zone independent Date and DateTime types are assumed to be in
the local time zone and converted to UTC if tz is left to null.
*/
this(in Date date, immutable TimeZone tz = null) { this(SysTime(date, tz)); }
/// ditto
this(in DateTime date, immutable TimeZone tz = null) { this(SysTime(date, tz)); }
/// ditto
this(in SysTime date) { this(fromStdTime(date.stdTime()).m_time); }
/** Constructs a BsonDate from the given UNIX time.
unix_time needs to be given in milliseconds from 1970/01/01. This is
the native storage format for BsonDate.
*/
this(long unix_time)
{
m_time = unix_time;
}
/** Constructs a BsonDate from the given date/time string in ISO extended format.
*/
static BsonDate fromString(string iso_ext_string) { return BsonDate(SysTime.fromISOExtString(iso_ext_string)); }
/** Constructs a BsonDate from the given date/time in standard time as defined in `std.datetime`.
*/
static BsonDate fromStdTime(long std_time)
{
enum zero = unixTimeToStdTime(0);
return BsonDate((std_time - zero) / 10_000L);
}
/** The raw unix time value.
This is the native storage/transfer format of a BsonDate.
*/
@property long value() const { return m_time; }
/// ditto
@property void value(long v) { m_time = v; }
/** Returns the date formatted as ISO extended format.
*/
string toString() const { return toSysTime().toISOExtString(); }
/* Converts to a SysTime using UTC timezone.
*/
SysTime toSysTime() const {
return toSysTime(UTC());
}
/* Converts to a SysTime with a given timezone.
*/
SysTime toSysTime(immutable TimeZone tz) const {
auto zero = unixTimeToStdTime(0);
return SysTime(zero + m_time * 10_000L, tz);
}
/** Allows relational and equality comparisons.
*/
bool opEquals(ref const BsonDate other) const { return m_time == other.m_time; }
/// ditto
int opCmp(ref const BsonDate other) const {
if( m_time == other.m_time ) return 0;
if( m_time < other.m_time ) return -1;
else return 1;
}
}
/**
Represents a BSON timestamp value `(Bson.Type.timestamp)`.
*/
struct BsonTimestamp {
@safe:
private long m_time;
this( long time ){
m_time = time;
}
}
/**
Represents a BSON regular expression value `(Bson.Type.regex)`.
*/
struct BsonRegex {
@safe:
private {
string m_expr;
string m_options;
}
this(string expr, string options)
{
m_expr = expr;
m_options = options;
}
@property string expression() const { return m_expr; }
@property string options() const { return m_options; }
}
/**
Serializes the given value to BSON.
The following types of values are supported:
$(DL
$(DT `Bson`) $(DD Used as-is)
$(DT `Json`) $(DD Converted to BSON)
$(DT `BsonBinData`) $(DD Converted to `Bson.Type.binData`)
$(DT `BsonObjectID`) $(DD Converted to `Bson.Type.objectID`)
$(DT `BsonDate`) $(DD Converted to `Bson.Type.date`)
$(DT `BsonTimestamp`) $(DD Converted to `Bson.Type.timestamp`)
$(DT `BsonRegex`) $(DD Converted to `Bson.Type.regex`)
$(DT `null`) $(DD Converted to `Bson.Type.null_`)
$(DT `bool`) $(DD Converted to `Bson.Type.bool_`)
$(DT `float`, `double`) $(DD Converted to `Bson.Type.double_`)
$(DT `short`, `ushort`, `int`, `uint`, `long`, `ulong`) $(DD Converted to `Bson.Type.long_`)
$(DT `string`) $(DD Converted to `Bson.Type.string`)
$(DT `ubyte[]`) $(DD Converted to `Bson.Type.binData`)
$(DT `T[]`) $(DD Converted to `Bson.Type.array`)
$(DT `T[string]`) $(DD Converted to `Bson.Type.object`)
$(DT `struct`) $(DD Converted to `Bson.Type.object`)
$(DT `class`) $(DD Converted to `Bson.Type.object` or `Bson.Type.null_`)
)
All entries of an array or an associative array, as well as all R/W properties and
all fields of a struct/class are recursively serialized using the same rules.
Fields ending with an underscore will have the last underscore stripped in the
serialized output. This makes it possible to use fields with D keywords as their name
by simply appending an underscore.
The following methods can be used to customize the serialization of structs/classes:
---
Bson toBson() const;
static T fromBson(Bson src);
Json toJson() const;
static T fromJson(Json src);
string toString() const;
static T fromString(string src);
---
The methods will have to be defined in pairs. The first pair that is implemented by
the type will be used for serialization (i.e. `toBson` overrides `toJson`).
See_Also: `deserializeBson`
*/
Bson serializeToBson(T)(auto ref T value, ubyte[] buffer = null)
{
return serialize!BsonSerializer(value, buffer);
}
template deserializeBson(T)
{
/**
Deserializes a BSON value into the destination variable.
The same types as for `serializeToBson()` are supported and handled inversely.
See_Also: `serializeToBson`
*/
void deserializeBson(ref T dst, Bson src)
{
dst = deserializeBson!T(src);
}
/// ditto
T deserializeBson(Bson src)
{
return deserialize!(BsonSerializer, T)(src);
}
}
unittest {
import std.stdio;
enum Foo : string { k = "test" }
enum Boo : int { l = 5 }
static struct S { float a; double b; bool c; int d; string e; byte f; ubyte g; long h; ulong i; float[] j; Foo k; Boo l;}
immutable S t = {1.5, -3.0, true, int.min, "Test", -128, 255, long.min, ulong.max, [1.1, 1.2, 1.3], Foo.k, Boo.l,};
S u;
deserializeBson(u, serializeToBson(t));
assert(t.a == u.a);
assert(t.b == u.b);
assert(t.c == u.c);
assert(t.d == u.d);
assert(t.e == u.e);
assert(t.f == u.f);
assert(t.g == u.g);
assert(t.h == u.h);
assert(t.i == u.i);
assert(t.j == u.j);
assert(t.k == u.k);
assert(t.l == u.l);
}
unittest
{
assert(uint.max == serializeToBson(uint.max).deserializeBson!uint);
assert(ulong.max == serializeToBson(ulong.max).deserializeBson!ulong);
}
unittest {
assert(deserializeBson!SysTime(serializeToBson(SysTime(0))) == SysTime(0));
assert(deserializeBson!SysTime(serializeToBson(SysTime(0, UTC()))) == SysTime(0, UTC()));
assert(deserializeBson!Date(serializeToBson(Date.init)) == Date.init);
assert(deserializeBson!Date(serializeToBson(Date(2001, 1, 1))) == Date(2001, 1, 1));
}
@safe unittest {
static struct A { int value; static A fromJson(Json val) @safe { return A(val.get!int); } Json toJson() const @safe { return Json(value); } Bson toBson() { return Bson(); } }
static assert(!isStringSerializable!A && isJsonSerializable!A && !isBsonSerializable!A);
static assert(!isStringSerializable!(const(A)) && isJsonSerializable!(const(A)) && !isBsonSerializable!(const(A)));
// assert(serializeToBson(const A(123)) == Bson(123));
// assert(serializeToBson(A(123)) == Bson(123));
static struct B { int value; static B fromBson(Bson val) @safe { return B(val.get!int); } Bson toBson() const @safe { return Bson(value); } Json toJson() { return Json(); } }
static assert(!isStringSerializable!B && !isJsonSerializable!B && isBsonSerializable!B);
static assert(!isStringSerializable!(const(B)) && !isJsonSerializable!(const(B)) && isBsonSerializable!(const(B)));
assert(serializeToBson(const B(123)) == Bson(123));
assert(serializeToBson(B(123)) == Bson(123));
static struct C { int value; static C fromString(string val) @safe { return C(val.to!int); } string toString() const @safe { return value.to!string; } Json toJson() { return Json(); } }
static assert(isStringSerializable!C && !isJsonSerializable!C && !isBsonSerializable!C);
static assert(isStringSerializable!(const(C)) && !isJsonSerializable!(const(C)) && !isBsonSerializable!(const(C)));
assert(serializeToBson(const C(123)) == Bson("123"));
assert(serializeToBson(C(123)) == Bson("123"));
static struct D { int value; string toString() const { return ""; } }
static assert(!isStringSerializable!D && !isJsonSerializable!D && !isBsonSerializable!D);
static assert(!isStringSerializable!(const(D)) && !isJsonSerializable!(const(D)) && !isBsonSerializable!(const(D)));
assert(serializeToBson(const D(123)) == serializeToBson(["value": 123]));
assert(serializeToBson(D(123)) == serializeToBson(["value": 123]));
// test if const(class) is serializable
static class E { int value; this(int v) @safe { value = v; } static E fromBson(Bson val) @safe { return new E(val.get!int); } Bson toBson() const @safe { return Bson(value); } Json toJson() { return Json(); } }
static assert(!isStringSerializable!E && !isJsonSerializable!E && isBsonSerializable!E);
static assert(!isStringSerializable!(const(E)) && !isJsonSerializable!(const(E)) && isBsonSerializable!(const(E)));
assert(serializeToBson(new const E(123)) == Bson(123));
assert(serializeToBson(new E(123)) == Bson(123));
}
@safe unittest {
static struct E { ubyte[4] bytes; ubyte[] more; }
auto e = E([1, 2, 3, 4], [5, 6]);
auto eb = serializeToBson(e);
assert(eb["bytes"].type == Bson.Type.binData);
assert(eb["more"].type == Bson.Type.binData);
assert(e == deserializeBson!E(eb));
}
@safe unittest {
static class C {
@safe:
int a;
private int _b;
@property int b() const { return _b; }
@property void b(int v) { _b = v; }
@property int test() const @safe { return 10; }
void test2() {}
}
C c = new C;
c.a = 1;
c.b = 2;
C d;
deserializeBson(d, serializeToBson(c));
assert(c.a == d.a);
assert(c.b == d.b);
const(C) e = c; // serialize const class instances (issue #653)
deserializeBson(d, serializeToBson(e));
assert(e.a == d.a);
assert(e.b == d.b);
}
unittest {
static struct C { @safe: int value; static C fromString(string val) { return C(val.to!int); } string toString() const { return value.to!string; } }
enum Color { Red, Green, Blue }
{
static class T {
@safe:
string[Color] enumIndexedMap;
string[C] stringableIndexedMap;
this() {
enumIndexedMap = [ Color.Red : "magenta", Color.Blue : "deep blue" ];
stringableIndexedMap = [ C(42) : "forty-two" ];
}
}
T original = new T;
original.enumIndexedMap[Color.Green] = "olive";
T other;
deserializeBson(other, serializeToBson(original));
assert(serializeToBson(other) == serializeToBson(original));
}
{
static struct S {
string[Color] enumIndexedMap;
string[C] stringableIndexedMap;
}
S original;
original.enumIndexedMap = [ Color.Red : "magenta", Color.Blue : "deep blue" ];
original.enumIndexedMap[Color.Green] = "olive";
original.stringableIndexedMap = [ C(42) : "forty-two" ];
S other;
deserializeBson(other, serializeToBson(original));
assert(serializeToBson(other) == serializeToBson(original));
}
}
unittest {
ubyte[] data = [1, 2, 3];
auto bson = serializeToBson(data);
assert(bson.type == Bson.Type.binData);
assert(deserializeBson!(ubyte[])(bson) == data);
}
unittest { // issue #709
ulong[] data = [2354877787627192443, 1, 2354877787627192442];
auto bson = Bson.fromJson(serializeToBson(data).toJson);
assert(deserializeBson!(ulong[])(bson) == data);
}
unittest { // issue #709
uint[] data = [1, 2, 3, 4];
auto bson = Bson.fromJson(serializeToBson(data).toJson);
// assert(deserializeBson!(uint[])(bson) == data);
assert(deserializeBson!(ulong[])(bson).equal(data));
}
unittest {
import std.typecons;
Nullable!bool x;
auto bson = serializeToBson(x);
assert(bson.type == Bson.Type.null_);
deserializeBson(x, bson);
assert(x.isNull);
x = true;
bson = serializeToBson(x);
assert(bson.type == Bson.Type.bool_ && bson.get!bool == true);
deserializeBson(x, bson);
assert(x == true);
}
unittest { // issue #793
char[] test = "test".dup;
auto bson = serializeToBson(test);
//assert(bson.type == Bson.Type.string);
//assert(bson.get!string == "test");
assert(bson.type == Bson.Type.array);
assert(bson[0].type == Bson.Type.string && bson[0].get!string == "t");
}
@safe unittest { // issue #2212
auto bsonRegex = Bson(BsonRegex(".*", "i"));
auto parsedRegex = bsonRegex.get!BsonRegex;
assert(bsonRegex.type == Bson.Type.regex);
assert(parsedRegex.expression == ".*");
assert(parsedRegex.options == "i");
}
unittest
{
UUID uuid = UUID("35399104-fbc9-4c08-bbaf-65a5efe6f5f2");
auto bson = Bson(uuid);
assert(bson.get!UUID == uuid);
assert(bson.deserializeBson!UUID == uuid);
bson = Bson([Bson(uuid)]);
assert(bson.deserializeBson!(UUID[]) == [uuid]);
bson = [uuid].serializeToBson();
assert(bson.deserializeBson!(UUID[]) == [uuid]);
}
/**
Serializes to an in-memory BSON representation.
See_Also: `vibe.data.serialization.serialize`, `vibe.data.serialization.deserialize`, `serializeToBson`, `deserializeBson`
*/
struct BsonSerializer {
import vibe.utils.array : AllocAppender;
private {
AllocAppender!(ubyte[]) m_dst;
size_t[] m_compositeStack;
Bson.Type m_type = Bson.Type.null_;
Bson m_inputData;
string m_entryName;
size_t m_entryIndex = size_t.max;
}
this(Bson input)
@safe {
m_inputData = input;
}
this(ubyte[] buffer)
@safe {
import vibe.internal.utilallocator;
m_dst = () @trusted { return AllocAppender!(ubyte[])(vibeThreadAllocator(), buffer); } ();
}
@disable this(this);
template isSupportedValueType(T) { enum isSupportedValueType = is(typeof(getBsonTypeID(T.init))); }
//
// serialization
//
Bson getSerializedResult()
@safe {
auto ret = Bson(m_type, () @trusted { return cast(immutable)m_dst.data; } ());
() @trusted { m_dst.reset(); } ();
m_type = Bson.Type.null_;
return ret;
}
void beginWriteDictionary(Traits)()
{
writeCompositeEntryHeader(Bson.Type.object);
m_compositeStack ~= m_dst.data.length;
m_dst.put(toBsonData(cast(int)0));
}
void endWriteDictionary(Traits)()
{
m_dst.put(Bson.Type.end);
auto sh = m_compositeStack[$-1];
m_compositeStack.length--;
m_dst.data[sh .. sh + 4] = toBsonData(cast(uint)(m_dst.data.length - sh))[];
}
void beginWriteDictionaryEntry(Traits)(string name) { m_entryName = name; }
void endWriteDictionaryEntry(Traits)(string name) {}
void beginWriteArray(Traits)(size_t)
{
writeCompositeEntryHeader(Bson.Type.array);
m_compositeStack ~= m_dst.data.length;
m_dst.put(toBsonData(cast(int)0));
}
void endWriteArray(Traits)() { endWriteDictionary!Traits(); }
void beginWriteArrayEntry(Traits)(size_t idx) { m_entryIndex = idx; }
void endWriteArrayEntry(Traits)(size_t idx) {}
void writeValue(Traits, T)(auto ref T value) { writeValueH!(T, true)(value); }
private void writeValueH(T, bool write_header)(auto ref T value)
{
alias UT = Unqual!T;
static if (write_header) writeCompositeEntryHeader(getBsonTypeID(value));
static if (is(UT == Bson)) { m_dst.put(value.data); }
else static if (is(UT == Json)) { m_dst.put(Bson(value).data); } // FIXME: use .writeBsonValue
else static if (is(UT == typeof(null))) {}
else static if (is(UT == string)) { m_dst.put(toBsonData(cast(uint)value.length+1)); m_dst.putCString(value); }
else static if (is(UT == BsonBinData)) { m_dst.put(toBsonData(cast(int)value.rawData.length)); m_dst.put(value.type); m_dst.put(value.rawData); }
else static if (is(UT == BsonObjectID)) { m_dst.put(value.m_bytes[]); }
else static if (is(UT == BsonDate)) { m_dst.put(toBsonData(value.m_time)); }
else static if (is(UT == SysTime)) { m_dst.put(toBsonData(BsonDate(value).m_time)); }
else static if (is(UT == BsonRegex)) { m_dst.putCString(value.expression); m_dst.putCString(value.options); }
else static if (is(UT == BsonTimestamp)) { m_dst.put(toBsonData(value.m_time)); }
else static if (is(UT == bool)) { m_dst.put(cast(ubyte)(value ? 0x01 : 0x00)); }
else static if (is(UT : int) && isIntegral!UT) { m_dst.put(toBsonData(cast(int)value)); }
else static if (is(UT : long) && isIntegral!UT) { m_dst.put(toBsonData(value)); }
else static if (is(UT : double) && isFloatingPoint!UT) { m_dst.put(toBsonData(cast(double)value)); }
else static if (is(UT == UUID)) { m_dst.put(Bson(value).data); }
else static if (isBsonSerializable!UT) {
static if (!__traits(compiles, () @safe { return value.toBson(); } ()))
pragma(msg, "Non-@safe toBson/fromBson methods are deprecated - annotate "~T.stringof~".toBson() with @safe.");
m_dst.put(() @trusted { return value.toBson(); } ().data);
} else static if (isJsonSerializable!UT) {
static if (!__traits(compiles, () @safe { return value.toJson(); } ()))
pragma(msg, "Non-@safe toJson/fromJson methods are deprecated - annotate "~UT.stringof~".toJson() with @safe.");
m_dst.put(Bson(() @trusted { return value.toJson(); } ()).data);
} else static if (is(UT : const(ubyte)[])) { writeValueH!(BsonBinData, false)(BsonBinData(BsonBinData.Type.generic, value.idup)); }
else static assert(false, "Unsupported type: " ~ UT.stringof);
}
private void writeCompositeEntryHeader(Bson.Type tp)
@safe {
if (!m_compositeStack.length) {
assert(m_type == Bson.Type.null_, "Overwriting root item.");
m_type = tp;
}
if (m_entryName !is null) {
m_dst.put(tp);
m_dst.putCString(m_entryName);
m_entryName = null;
} else if (m_entryIndex != size_t.max) {
import std.format;
m_dst.put(tp);
static struct Wrapper {
@trusted:
AllocAppender!(ubyte[])* app;
void put(char ch) { (*app).put(ch); }
void put(in char[] str) { (*app).put(cast(const(ubyte)[])str); }
}
auto wr = Wrapper(&m_dst);
wr.formattedWrite("%d\0", m_entryIndex);
m_entryIndex = size_t.max;
}
}
//
// deserialization
//
void readDictionary(Traits)(scope void delegate(string) @safe entry_callback)
{
enforce(m_inputData.type == Bson.Type.object, "Expected object instead of "~m_inputData.type.to!string());
auto old = m_inputData;
foreach (string name, value; old.byKeyValue) {
m_inputData = value;
entry_callback(name);
}
m_inputData = old;
}
void beginReadDictionaryEntry(Traits)(string name) {}
void endReadDictionaryEntry(Traits)(string name) {}
void readArray(Traits)(scope void delegate(size_t) @safe size_callback, scope void delegate() @safe entry_callback)
{
enforce(m_inputData.type == Bson.Type.array, "Expected array instead of "~m_inputData.type.to!string());
auto old = m_inputData;
foreach (value; old.byValue) {
m_inputData = value;
entry_callback();
}
m_inputData = old;
}
void beginReadArrayEntry(Traits)(size_t index) {}
void endReadArrayEntry(Traits)(size_t index) {}
T readValue(Traits, T)()
{
static if (is(T == Bson)) return m_inputData;
else static if (is(T == Json)) return m_inputData.toJson();
else static if (is(T == bool)) return m_inputData.get!bool();
else static if (is(T == uint)) return cast(T)m_inputData.get!int();
else static if (is(T : int)) {
if(m_inputData.type == Bson.Type.long_) {
enforce((m_inputData.get!long() >= int.min) && (m_inputData.get!long() <= int.max), "Long out of range while attempting to deserialize to int: " ~ m_inputData.get!long.to!string);
return cast(T)m_inputData.get!long();
}
else return m_inputData.get!int().to!T;
}
else static if (is(T : long)) {
if(m_inputData.type == Bson.Type.int_) return cast(T)m_inputData.get!int();
else return cast(T)m_inputData.get!long();
}
else static if (is(T : double)) return cast(T)m_inputData.get!double();
else static if (is(T == SysTime)) {
// support legacy behavior to serialize as string
if (m_inputData.type == Bson.Type.string) return SysTime.fromISOExtString(m_inputData.get!string);
else return m_inputData.get!BsonDate().toSysTime();
}
else static if (isBsonSerializable!T) {
static if (!__traits(compiles, () @safe { return T.fromBson(Bson.init); } ()))
pragma(msg, "Non-@safe toBson/fromBson methods are deprecated - annotate "~T.stringof~".fromBson() with @safe.");
auto bval = readValue!(Traits, Bson);
return () @trusted { return T.fromBson(bval); } ();
} else static if (isJsonSerializable!T) {
static if (!__traits(compiles, () @safe { return T.fromJson(Json.init); } ()))
pragma(msg, "Non-@safe toJson/fromJson methods are deprecated - annotate "~T.stringof~".fromJson() with @safe.");
auto jval = readValue!(Traits, Bson).toJson();
return () @trusted { return T.fromJson(jval); } ();
} else static if (is(T : const(ubyte)[])) {
auto ret = m_inputData.get!BsonBinData.rawData;
static if (isStaticArray!T) return cast(T)ret[0 .. T.length];
else static if (is(T : immutable(char)[])) return ret;
else return cast(T)ret.dup;
} else return m_inputData.get!T();
}
bool tryReadNull(Traits)()
{
if (m_inputData.type == Bson.Type.null_) return true;
return false;
}
private static Bson.Type getBsonTypeID(T, bool accept_ao = false)(auto ref T value)
@safe {
alias UT = Unqual!T;
Bson.Type tp;
static if (is(T == Bson)) tp = value.type;
else static if (is(UT == Json)) tp = jsonTypeToBsonType(value.type);
else static if (is(UT == typeof(null))) tp = Bson.Type.null_;
else static if (is(UT == string)) tp = Bson.Type.string;
else static if (is(UT == BsonBinData)) tp = Bson.Type.binData;
else static if (is(UT == BsonObjectID)) tp = Bson.Type.objectID;
else static if (is(UT == BsonDate)) tp = Bson.Type.date;
else static if (is(UT == SysTime)) tp = Bson.Type.date;
else static if (is(UT == BsonRegex)) tp = Bson.Type.regex;
else static if (is(UT == BsonTimestamp)) tp = Bson.Type.timestamp;
else static if (is(UT == bool)) tp = Bson.Type.bool_;
else static if (isIntegral!UT && is(UT : int)) tp = Bson.Type.int_;
else static if (isIntegral!UT && is(UT : long)) tp = Bson.Type.long_;
else static if (isFloatingPoint!UT && is(UT : double)) tp = Bson.Type.double_;
else static if (isBsonSerializable!UT) tp = value.toBson().type; // FIXME: this is highly inefficient
else static if (isJsonSerializable!UT) tp = jsonTypeToBsonType(value.toJson().type); // FIXME: this is highly inefficient
else static if (is(UT == UUID)) tp = Bson.Type.binData;
else static if (is(UT : const(ubyte)[])) tp = Bson.Type.binData;
else static if (accept_ao && isArray!UT) tp = Bson.Type.array;
else static if (accept_ao && isAssociativeArray!UT) tp = Bson.Type.object;
else static if (accept_ao && (is(UT == class) || is(UT == struct))) tp = Bson.Type.object;
else static assert(false, "Unsupported type: " ~ UT.stringof);
return tp;
}
}
private Bson.Type jsonTypeToBsonType(Json.Type tp)
@safe {
static immutable Bson.Type[Json.Type.max+1] JsonIDToBsonID = [
Bson.Type.undefined,
Bson.Type.null_,
Bson.Type.bool_,
Bson.Type.long_,
Bson.Type.long_,
Bson.Type.double_,
Bson.Type.string,
Bson.Type.array,
Bson.Type.object
];
return JsonIDToBsonID[tp];
}
private Bson.Type writeBson(R)(ref R dst, in Json value)
if( isOutputRange!(R, ubyte) )
{
final switch(value.type){
case Json.Type.undefined:
return Bson.Type.undefined;
case Json.Type.null_:
return Bson.Type.null_;
case Json.Type.bool_:
dst.put(cast(ubyte)(cast(bool)value ? 0x01 : 0x00));
return Bson.Type.bool_;
case Json.Type.int_:
dst.put(toBsonData(cast(long)value));
return Bson.Type.long_;
case Json.Type.bigInt:
dst.put(toBsonData(cast(long)value));
return Bson.Type.long_;
case Json.Type.float_:
dst.put(toBsonData(cast(double)value));
return Bson.Type.double_;
case Json.Type.string:
dst.put(toBsonData(cast(uint)value.length+1));
dst.put(cast(bdata_t)cast(string)value);
dst.put(cast(ubyte)0);
return Bson.Type.string;
case Json.Type.array:
auto app = appender!bdata_t();
foreach( size_t i, ref const Json v; value ){
app.put(cast(ubyte)(jsonTypeToBsonType(v.type)));
putCString(app, to!string(i));
writeBson(app, v);
}
dst.put(toBsonData(cast(int)(app.data.length + int.sizeof + 1)));
dst.put(app.data);
dst.put(cast(ubyte)0);
return Bson.Type.array;
case Json.Type.object:
auto app = appender!bdata_t();
foreach( string k, ref const Json v; value ){
app.put(cast(ubyte)(jsonTypeToBsonType(v.type)));
putCString(app, k);
writeBson(app, v);
}
dst.put(toBsonData(cast(int)(app.data.length + int.sizeof + 1)));
dst.put(app.data);
dst.put(cast(ubyte)0);
return Bson.Type.object;
}
}
unittest
{
Json jsvalue = parseJsonString("{\"key\" : \"Value\"}");
assert(serializeToBson(jsvalue).toJson() == jsvalue);
jsvalue = parseJsonString("{\"key\" : [{\"key\" : \"Value\"}, {\"key2\" : \"Value2\"}] }");
assert(serializeToBson(jsvalue).toJson() == jsvalue);
jsvalue = parseJsonString("[ 1 , 2 , 3]");
assert(serializeToBson(jsvalue).toJson() == jsvalue);
}
unittest
{
static struct Pipeline(ARGS...) { @asArray ARGS pipeline; }
auto getPipeline(ARGS...)(ARGS args) { return Pipeline!ARGS(args); }
string[string] a = ["foo":"bar"];
int b = 42;
auto fields = getPipeline(a, b).serializeToBson()["pipeline"].get!(Bson[]);
assert(fields[0]["foo"].get!string == "bar");
assert(fields[1].get!int == 42);
}
private string skipCString(ref bdata_t data)
@safe {
auto idx = data.countUntil(0);
enforce(idx >= 0, "Unterminated BSON C-string.");
auto ret = data[0 .. idx];
data = data[idx+1 .. $];
return cast(string)ret;
}
private void putCString(R)(ref R dst, string str)
{
dst.put(cast(bdata_t)str);
dst.put(cast(ubyte)0);
}
ubyte[] toBsonData(T)(T v)
{
/*static T tmp;
tmp = nativeToLittleEndian(v);
return cast(ubyte[])((&tmp)[0 .. 1]);*/
if (__ctfe) return nativeToLittleEndian(v).dup;
else {
static ubyte[T.sizeof] ret;
ret = nativeToLittleEndian(v);
return ret;
}
}
T fromBsonData(T)(in ubyte[] v)
{
assert(v.length >= T.sizeof);
//return (cast(T[])v[0 .. T.sizeof])[0];
ubyte[T.sizeof] vu = v[0 .. T.sizeof];
return littleEndianToNative!T(vu);
}
ubyte[] toBigEndianData(T)(T v)
{
if (__ctfe) return nativeToBigEndian(v).dup;
else {
static ubyte[T.sizeof] ret;
ret = nativeToBigEndian(v);
return ret;
}
}
private string underscoreStrip(string field_name)
pure @safe {
if( field_name.length < 1 || field_name[$-1] != '_' ) return field_name;
else return field_name[0 .. $-1];
}
/// private
package template isBsonSerializable(T) { enum isBsonSerializable = is(typeof(T.init.toBson()) : Bson) && is(typeof(T.fromBson(Bson())) : T); }
| D |
module dedit.main;
import std.format;
import dlangui;
mixin APP_ENTRY_POINT;
extern (C) int UIAppMain(string[] args)
{
auto window = Platform.instance.createWindow("t19 test", null);
auto vlay = new VerticalLayout;
window.mainWidget = vlay;
MainMenu mm = new MainMenu;
auto mm0 = new MenuItem;
auto mmi0 = new MenuItem(new Action(0, "item0"d));
mm0.add(mmi0);
mm.menuItems = mm0;
auto mmi1 = new MenuItem(new Action(0, "item1"d));
mm0.add(mmi1);
/* mm.menuItems = mm0; */
vlay.addChild(mm);
window.show();
return Platform.instance.enterMessageLoop();
}
| D |
/****************************************************************************
**
** Copyright (C) 2014 Digia Plc and/or its subsidiary(-ies).
** Contact: http://www.qt-project.org/legal
**
** This file is part of the QtWidgets module of the Qt Toolkit.
**
** $QT_BEGIN_LICENSE:LGPL21$
** Commercial License Usage
** Licensees holding valid commercial Qt licenses may use this file in
** accordance with the commercial license agreement provided with the
** Software or, alternatively, in accordance with the terms contained in
** a written agreement between you and Digia. For licensing terms and
** conditions see http://qt.digia.com/licensing. For further information
** use the contact form at http://qt.digia.com/contact-us.
**
** GNU Lesser General Public License Usage
** Alternatively, this file may be used under the terms of the GNU Lesser
** General Public License version 2.1 or version 3 as published by the Free
** Software Foundation and appearing in the file LICENSE.LGPLv21 and
** LICENSE.LGPLv3 included in the packaging of this file. Please review the
** following information to ensure the GNU Lesser General Public License
** requirements will be met: https://www.gnu.org/licenses/lgpl.html and
** http://www.gnu.org/licenses/old-licenses/lgpl-2.1.html.
**
** In addition, as a special exception, Digia gives you certain additional
** rights. These rights are described in the Digia Qt LGPL Exception
** version 1.1, included in the file LGPL_EXCEPTION.txt in this package.
**
** $QT_END_LICENSE$
**
****************************************************************************/
#ifndef QWIDGETSFUNCTIONS_WCE_H
#define QWIDGETSFUNCTIONS_WCE_H
public import qt.QtCore.qglobal;
#ifdef Q_OS_WINCE
public import qt.QtCore.qfunctions_wince;
#ifdef QT_BUILD_GUI_LIB
QT_BEGIN_NAMESPACE
QT_END_NAMESPACE
#endif
//WinCe 7 has shell support
#ifndef ShellExecute
HINSTANCE qt_wince_ShellExecute(HWND hwnd, LPCWSTR operation, LPCWSTR file, LPCWSTR params, LPCWSTR dir, int showCmd);
#define ShellExecute(a,b,c,d,e,f) qt_wince_ShellExecute(a,b,c,d,e,f)
#endif
#endif // Q_OS_WINCE
#endif // QWIDGETSFUNCTIONS_WCE_H
| D |
/**
* Copyright © DiamondMVC 2019
* License: MIT (https://github.com/DiamondMVC/Diamond/blob/master/LICENSE)
* Author: Jacob Jensen (bausshf)
*/
module diamond.seo.schema.structures.organizations.localbusinesses.store;
import diamond.core.apptype;
static if (isWeb)
{
import diamond.seo.schema.structures.organizations.localbusiness;
/// http://schema.org/Store
final class Store : LocalBusiness
{
private:
public:
final:
/// Creates a new store.
this()
{
super("Store");
}
@property
{
}
}
}
| D |
/* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
* See the License for the specific language governing permissions and
* limitations under the License.
*/
module flow.engine.impl.persistence.entity.HistoricDetailVariableInstanceUpdateEntity;
import flow.common.db.HasRevision;
import flow.common.persistence.entity.Entity;
import flow.engine.history.HistoricVariableUpdate;
import flow.variable.service.api.types.ValueFields;
import flow.variable.service.api.types.VariableType;
import flow.engine.impl.persistence.entity.HistoricDetailEntity;
import flow.engine.impl.persistence.entity.ByteArrayRef;
/**
* @author Tom Baeyens
* @author Joram Barrez
*/
interface HistoricDetailVariableInstanceUpdateEntity : HistoricDetailEntity, ValueFields, HistoricVariableUpdate, Entity, HasRevision {
void setName(string name);
ByteArrayRef getByteArrayRef();
VariableType getVariableType();
void setVariableType(VariableType variableType);
}
| D |
/home/nils/git/just_another_card_game/card_game_client/target/debug/build/getrandom-384b0be3da23b777/build_script_build-384b0be3da23b777: /home/nils/.cargo/registry/src/github.com-1ecc6299db9ec823/getrandom-0.1.14/build.rs
/home/nils/git/just_another_card_game/card_game_client/target/debug/build/getrandom-384b0be3da23b777/build_script_build-384b0be3da23b777.d: /home/nils/.cargo/registry/src/github.com-1ecc6299db9ec823/getrandom-0.1.14/build.rs
/home/nils/.cargo/registry/src/github.com-1ecc6299db9ec823/getrandom-0.1.14/build.rs:
| D |
///////////////////////////////////////////////////////////////////////
// Info EXIT
///////////////////////////////////////////////////////////////////////
INSTANCE DIA_Alvares_EXIT (C_INFO)
{
npc = SLD_840_Alvares;
nr = 999;
condition = DIA_Alvares_EXIT_Condition;
information = DIA_Alvares_EXIT_Info;
permanent = TRUE;
description = DIALOG_ENDE;
};
FUNC INT DIA_Alvares_EXIT_Condition()
{
return TRUE;
};
FUNC VOID DIA_Alvares_EXIT_Info()
{
AI_StopProcessInfos (self);
};
///////////////////////////////////////////////////////////////////////
// Info HauAb
///////////////////////////////////////////////////////////////////////
instance DIA_Alvares_HAUAB (C_INFO)
{
npc = SLD_840_Alvares;
nr = 4;
condition = DIA_Alvares_HAUAB_Condition;
information = DIA_Alvares_HAUAB_Info;
permanent = FALSE;
important = TRUE;
};
func int DIA_Alvares_HAUAB_Condition ()
{
if (Npc_IsInState (self, ZS_Talk))
{
return TRUE;
};
};
func void DIA_Alvares_HAUAB_Info ()
{
Akils_SLDStillthere = TRUE;
AI_Output (self, other, "DIA_Alvares_HAUAB_11_00"); //Aă už tę sem pâivedlo cokoliv, radši na to zapomeŕ a bęž dál.
Log_CreateTopic (TOPIC_AkilsSLDStillthere, LOG_MISSION);
Log_SetTopicStatus(TOPIC_AkilsSLDStillthere, LOG_RUNNING);
B_LogEntry (TOPIC_AkilsSLDStillthere,"Akilovu farmu ohrožují žoldnéâi.");
AI_StopProcessInfos (self);
};
///////////////////////////////////////////////////////////////////////
// Info Attack
///////////////////////////////////////////////////////////////////////
instance DIA_Alvares_ATTACK (C_INFO)
{
npc = SLD_840_Alvares;
nr = 6;
condition = DIA_Alvares_ATTACK_Condition;
information = DIA_Alvares_ATTACK_Info;
permanent = FALSE;
important = TRUE;
};
func int DIA_Alvares_ATTACK_Condition ()
{
if (Npc_KnowsInfo(other, DIA_Alvares_HAUAB))
&& (Npc_IsInState (self, ZS_Talk))
{
return TRUE;
};
};
func void DIA_Alvares_ATTACK_Info ()
{
AI_Output (self, other, "DIA_Alvares_ATTACK_11_00"); //Hej, tys ještę tady? Dal jsem ti na výbęr, cizinče: buë vypadni, nebo chcípni.
Info_ClearChoices (DIA_Alvares_ATTACK);
Info_AddChoice (DIA_Alvares_ATTACK,"Co jste zač? Párek vtipálků?",DIA_Alvares_ATTACK_Kerle);
Info_AddChoice (DIA_Alvares_ATTACK,"Chci se k vám žoldnéâum pâidat.",DIA_Alvares_ATTACK_Soeldner);
Info_AddChoice (DIA_Alvares_ATTACK,"Teëka odsud hezky rychle vypadnete...",DIA_Alvares_ATTACK_Witz);
Info_AddChoice (DIA_Alvares_ATTACK,"Nestojím o žádné problémy.",DIA_Alvares_ATTACK_Aerger);
if (MIS_Baltram_ScoutAkil == LOG_RUNNING)
{
Info_AddChoice (DIA_Alvares_ATTACK,"Jen jsem si pâišel nęco vyzvednout.",DIA_Alvares_ATTACK_Lieferung);
};
};
FUNC VOID DIA_Alvares_ATTACK_Witz()
{
AI_Output (other, self, "DIA_Alvares_ATTACK_Witz_15_00"); //Hele, kluci, prostę odtuë hnedka zmizíte, jasný?
AI_Output (self, other, "DIA_Alvares_ATTACK_Witz_11_01"); //A helemese, máme tu nového hrdinu - a je to opravdový blbec.
AI_Output (self, other, "DIA_Alvares_ATTACK_Witz_11_02"); //Víš, co si myslím?
AI_Output (other, self, "DIA_Alvares_ATTACK_Witz_15_03"); //Koho zajímá, co si myslíš?
AI_Output (self, other, "DIA_Alvares_ATTACK_Witz_11_04"); //Myslím, že dobrý hrdina je jedinę mrtvý hrdina. Udęlej mi teda laskavost - chcípni co nejrychlejc!
AI_StopProcessInfos (self);
B_Attack (self, other, AR_SuddenEnemyInferno, 1);
};
FUNC VOID DIA_Alvares_ATTACK_Kerle()
{
AI_Output (other, self, "DIA_Alvares_ATTACK_Kerle_15_00"); //Co jste zač? Párek vtipálků?
AI_Output (self, other, "DIA_Alvares_ATTACK_Kerle_11_01"); //Tos uhodl. Ale poâádnę se zasmęju, teprve až budeš ležet držkou v blátę.
AI_Output (self, other, "DIA_Alvares_ATTACK_Kerle_11_02"); //(volá) Engardo, do toho! Ty chytni toho sedláka a já se vypoâádám s tímhle šaškem!
AI_StopProcessInfos (self);
B_Attack (self, other, AR_SuddenEnemyInferno, 1);
};
FUNC VOID DIA_Alvares_ATTACK_Aerger()
{
AI_Output (other, self, "DIA_Alvares_ATTACK_Aerger_15_00"); //Nestojím o žádné problémy.
AI_Output (self, other, "DIA_Alvares_ATTACK_Aerger_11_01"); //Ale my zase máme problémy moc rádi. Urazili jsme pękný kus cesty, jenom abysme nęjaké vyvolali.
AI_Output (self, other, "DIA_Alvares_ATTACK_Aerger_11_02"); //Jo, tęch problémů nebude zrovna málo. A jestli okamžitę nezmizíš, začneme rovnou s tebou.
AI_StopProcessInfos (self);
};
FUNC VOID DIA_Alvares_ATTACK_Lieferung()
{
AI_Output (other, self, "DIA_Alvares_ATTACK_Lieferung_15_00"); //Jen jsem si pâišel nęco vyzvednout.
AI_Output (self, other, "DIA_Alvares_ATTACK_Lieferung_11_01"); //To my taky, a my jsme tu byli první. Takže buë vypadneš, nebo ti budu muset ublížit.
AI_StopProcessInfos (self);
};
FUNC VOID DIA_Alvares_ATTACK_Soeldner()
{
AI_Output (other, self, "DIA_Alvares_ATTACK_Soeldner_15_00"); //Chci se k vám žoldnéâům pâidat.
AI_Output (self, other, "DIA_Alvares_ATTACK_Soeldner_11_01"); //Ou, vážnę? Tak to koukej mazat, nebo už se nikdy k nikomu nepâidáš.
AI_StopProcessInfos (self);
};
///////////////////////////////////////////////////////////////////////
// Info Schluss
///////////////////////////////////////////////////////////////////////
instance DIA_Alvares_Schluss (C_INFO)
{
npc = SLD_840_Alvares;
nr = 4;
condition = DIA_Alvares_Schluss_Condition;
information = DIA_Alvares_Schluss_Info;
permanent = FALSE;
important = TRUE;
};
func int DIA_Alvares_Schluss_Condition ()
{
if (Npc_IsInState (self, ZS_Talk))
&& (Npc_KnowsInfo (other,DIA_Alvares_ATTACK))
{
return TRUE;
};
};
func void DIA_Alvares_Schluss_Info ()
{
AI_Output (self, other, "DIA_Alvares_Schluss_11_00"); //Dostal jsi šanci. Ale vypadá to, že rozumný důvody prostę ignoruješ.
AI_Output (self, other, "DIA_Alvares_Schluss_11_01"); //Jak chceš - tak to tę prostę teë hned zabiju. (volá) Engardo, oddęlej ho!
AI_StopProcessInfos (self);
B_Attack (self, other, AR_SuddenEnemyInferno, 1);
};
// ************************************************************
// PICK POCKET
// ************************************************************
INSTANCE DIA_Alvares_PICKPOCKET (C_INFO)
{
npc = SLD_840_Alvares;
nr = 900;
condition = DIA_Alvares_PICKPOCKET_Condition;
information = DIA_Alvares_PICKPOCKET_Info;
permanent = TRUE;
description = Pickpocket_20;
};
FUNC INT DIA_Alvares_PICKPOCKET_Condition()
{
C_Beklauen (20, 15);
};
FUNC VOID DIA_Alvares_PICKPOCKET_Info()
{
Info_ClearChoices (DIA_Alvares_PICKPOCKET);
Info_AddChoice (DIA_Alvares_PICKPOCKET, DIALOG_BACK ,DIA_Alvares_PICKPOCKET_BACK);
Info_AddChoice (DIA_Alvares_PICKPOCKET, DIALOG_PICKPOCKET ,DIA_Alvares_PICKPOCKET_DoIt);
};
func void DIA_Alvares_PICKPOCKET_DoIt()
{
B_Beklauen ();
Info_ClearChoices (DIA_Alvares_PICKPOCKET);
};
func void DIA_Alvares_PICKPOCKET_BACK()
{
Info_ClearChoices (DIA_Alvares_PICKPOCKET);
};
| D |
module hunt.wechat.bean.paymch.Unifiedorder;
import javax.xml.bind.annotation.XmlAccessType;
import javax.xml.bind.annotation.XmlAccessorType;
import javax.xml.bind.annotation.XmlRootElement;
import javax.xml.bind.annotation.adapters.XmlJavaTypeAdapter;
import hunt.wechat.bean.AdaptorCDATA;
import java.math.BigDecimal;
/**
* 统一支付请求参数
*
*
*
*/
@XmlRootElement(name = "xml")
@XmlAccessorType(XmlAccessType.FIELD)
class Unifiedorder : MchVersion{
private string appid;
private string mch_id;
private string device_info;
private string nonce_str;
/**
* @since 2.8.5
*/
//@XmlJavaTypeAdapter(value = Detail.typeid(JsonXmlAdapter))
private Detail detail;
//@XmlJavaTypeAdapter(value = typeid(AdaptorCDATA))
private string sign;
private string sign_type;
//@XmlJavaTypeAdapter(value = typeid(AdaptorCDATA))
private string body;
//@XmlJavaTypeAdapter(value = typeid(AdaptorCDATA))
private string attach;
private string out_trade_no;
private string fee_type;
private string total_fee;
private BigDecimal order_amount;
private string spbill_create_ip;
private string time_start;
private string time_expire;
private string goods_tag;
private string notify_url;
private string trade_type;
private string product_id;
private string limit_pay;
private string openid;
/**
* @since 2.8.5
*/
private string sub_appid;
/**
* @since 2.8.5
*/
private string sub_mch_id;
/**
* @since 2.8.5
*/
private string sub_openid;
/**
* @since 2.8.21
*/
//@XmlJavaTypeAdapter(value= SceneInfo.typeid(JsonXmlAdapter))
private SceneInfo scene_info;
/**
* @since 2.8.27
*/
private string receipt;
/**
* @since 2.8.27
*/
private string profit_sharing;
public string getAppid() {
return appid;
}
public void setAppid(string appid) {
this.appid = appid;
}
public string getMch_id() {
return mch_id;
}
public void setMch_id(string mch_id) {
this.mch_id = mch_id;
}
public string getDevice_info() {
return device_info;
}
public void setDevice_info(string device_info) {
this.device_info = device_info;
}
public string getNonce_str() {
return nonce_str;
}
public void setNonce_str(string nonce_str) {
this.nonce_str = nonce_str;
}
public string getSign() {
return sign;
}
public void setSign(string sign) {
this.sign = sign;
}
public string getBody() {
return body;
}
public void setBody(string body) {
this.body = body;
}
public string getAttach() {
return attach;
}
public void setAttach(string attach) {
this.attach = attach;
}
public string getOut_trade_no() {
return out_trade_no;
}
public void setOut_trade_no(string out_trade_no) {
this.out_trade_no = out_trade_no;
}
public string getTotal_fee() {
return total_fee;
}
public void setTotal_fee(string total_fee) {
this.total_fee = total_fee;
}
public BigDecimal getOrder_amount() {
return order_amount;
}
public void setOrder_amount(BigDecimal order_amount) {
this.order_amount = order_amount;
}
public string getSpbill_create_ip() {
return spbill_create_ip;
}
public void setSpbill_create_ip(string spbill_create_ip) {
this.spbill_create_ip = spbill_create_ip;
}
public string getTime_start() {
return time_start;
}
public void setTime_start(string time_start) {
this.time_start = time_start;
}
public string getTime_expire() {
return time_expire;
}
public void setTime_expire(string time_expire) {
this.time_expire = time_expire;
}
public string getGoods_tag() {
return goods_tag;
}
public void setGoods_tag(string goods_tag) {
this.goods_tag = goods_tag;
}
public string getNotify_url() {
return notify_url;
}
public void setNotify_url(string notify_url) {
this.notify_url = notify_url;
}
public string getTrade_type() {
return trade_type;
}
/**
* 支付类型
*
* @param trade_type
*
*
* JSAPI--公众号支付
* NATIVE--原生扫码支付
* APP--APP支付
* MWEB--H5
*/
public void setTrade_type(string trade_type) {
this.trade_type = trade_type;
}
public string getOpenid() {
return openid;
}
public void setOpenid(string openid) {
this.openid = openid;
}
public string getProduct_id() {
return product_id;
}
public void setProduct_id(string product_id) {
this.product_id = product_id;
}
public string getLimit_pay() {
return limit_pay;
}
public void setLimit_pay(string limit_pay) {
this.limit_pay = limit_pay;
}
public Detail getDetail() {
return detail;
}
public void setDetail(Detail detail) {
this.detail = detail;
}
public string getFee_type() {
return fee_type;
}
public void setFee_type(string fee_type) {
this.fee_type = fee_type;
}
public string getSub_appid() {
return sub_appid;
}
public void setSub_appid(string sub_appid) {
this.sub_appid = sub_appid;
}
public string getSub_mch_id() {
return sub_mch_id;
}
public void setSub_mch_id(string sub_mch_id) {
this.sub_mch_id = sub_mch_id;
}
public string getSub_openid() {
return sub_openid;
}
public void setSub_openid(string sub_openid) {
this.sub_openid = sub_openid;
}
public string getSign_type() {
return sign_type;
}
/**
* 签名类型
* @since 2.8.5
* @param sign_type HMAC-SHA256和MD5
*/
public void setSign_type(string sign_type) {
this.sign_type = sign_type;
}
public SceneInfo getScene_info() {
return scene_info;
}
public void setScene_info(SceneInfo scene_info) {
this.scene_info = scene_info;
}
public string getReceipt() {
return receipt;
}
public void setReceipt(string receipt) {
this.receipt = receipt;
}
public string getProfit_sharing() {
return profit_sharing;
}
public void setProfit_sharing(string profit_sharing) {
this.profit_sharing = profit_sharing;
}
}
| D |
/**
This module contains various combinatorics algorithms.
Authors: Sebastian Wilzbach, Ilia Ki
License: $(HTTP www.apache.org/licenses/LICENSE-2.0, Apache-2.0)
*/
module mir.combinatorics;
import mir.primitives: hasLength;
import mir.qualifier;
import std.traits;
///
version(mir_test) unittest
{
import mir.ndslice.fuse;
import std.string: representation;
assert(['a', 'b'].representation.permutations.fuse == [['a', 'b'], ['b', 'a']]);
assert(['a', 'b'].representation.cartesianPower(2).fuse == [['a', 'a'], ['a', 'b'], ['b', 'a'], ['b', 'b']]);
assert(['a', 'b'].representation.combinations(2).fuse == [['a', 'b']]);
assert(['a', 'b'].representation.combinationsRepeat(2).fuse == [['a', 'a'], ['a', 'b'], ['b', 'b']]);
assert(permutations!ushort(2).fuse == [[0, 1], [1, 0]]);
assert(cartesianPower!ushort(2, 2).fuse == [[0, 0], [0, 1], [1, 0], [1, 1]]);
assert(combinations!ushort(2, 2).fuse == [[0, 1]]);
assert(combinationsRepeat!ushort(2, 2).fuse == [[0, 0], [0, 1], [1, 1]]);
assert([3, 1].permutations!ubyte.fuse == [[3, 1], [1, 3]]);
assert([3, 1].cartesianPower!ubyte(2).fuse == [[3, 3], [3, 1], [1, 3], [1, 1]]);
assert([3, 1].combinations!ubyte(2).fuse == [[3, 1]]);
assert([3, 1].combinationsRepeat!ubyte(2).fuse == [[3, 3], [3, 1], [1, 1]]);
}
/**
Checks whether we can do basic arithmetic operations, comparisons, modulo and
assign values to the type.
*/
private template isArithmetic(R)
{
enum bool isArithmetic = is(typeof(
(inout int = 0)
{
R r = 1;
R test = (r * r / r + r - r) % r;
if (r < r && r > r) {}
}));
}
/**
Checks whether we can do basic arithmetic operations, comparison and modulo
between two types. R needs to support item assignment of S (it includes S).
Both R and S need to be arithmetic types themselves.
*/
private template isArithmetic(R, S)
{
enum bool isArithmetic = is(typeof(
(inout int = 0)
{
if (isArithmetic!R && isArithmetic!S) {}
S s = 1;
R r = 1;
R test = r * s + r * s;
R test2 = r / s + r / s;
R test3 = r - s + r - s;
R test4 = r % s + r % s;
if (r < s && s > r) {}
if (s < r && r > s) {}
}));
}
/**
Computes the $(WEB en.wikipedia.org/wiki/Binomial_coefficient, binomial coefficient)
of n and k.
It is also known as "n choose k" or more formally as `_n!/_k!(_n-_k)`.
If a fixed-length integer type is used and an overflow happens, `0` is returned.
Uses the generalized binomial coefficient for negative integers and floating
point number
Params:
n = arbitrary arithmetic type
k = arbitrary arithmetic type
Returns:
Binomial coefficient
*/
R binomial(R = ulong, T)(const T n, const T k)
if (isArithmetic!(R, T) &&
((is(typeof(T.min < 0)) && is(typeof(T.init & 1))) || !is(typeof(T.min < 0))) )
{
R result = 1;
enum hasMinProperty = is(typeof(T.min < 0));
T n2 = n;
T k2 = k;
// only add negative support if possible
static if ((hasMinProperty && T.min < 0) || !hasMinProperty)
{
if (n2 < 0)
{
if (k2 >= 0)
{
return (k2 & 1 ? -1 : 1) * binomial!(R, T)(-n2 + k2 - 1, k2);
}
else if (k2 <= n2)
{
return ((n2 - k2) & 1 ? -1 : 1) * binomial!(R, T)(-k2 - 1, n2 - k2);
}
}
if (k2 < 0)
{
result = 0;
return result;
}
}
if (k2 > n2)
{
result = 0;
return result;
}
if (k2 > n2 - k2)
{
k2 = n2 - k2;
}
// make a copy of n (could be a custom type)
for (T i = 1, m = n2; i <= k2; i++, m--)
{
// check whether an overflow can happen
// hasMember!(Result, "max") doesn't work with dmd2.068 and ldc 0.17
static if (is(typeof(0 > R.max)))
{
if (result / i > R.max / m) return 0;
result = result / i * m + result % i * m / i;
}
else
{
result = result * m / i;
}
}
return result;
}
///
pure version(mir_test) unittest
{
assert(binomial(5, 2) == 10);
assert(binomial(6, 4) == 15);
assert(binomial(3, 1) == 3);
import std.bigint: BigInt;
assert(binomial!BigInt(1000, 10) == BigInt("263409560461970212832400"));
}
pure nothrow @safe @nogc version(mir_test) unittest
{
assert(binomial(5, 1) == 5);
assert(binomial(5, 0) == 1);
assert(binomial(1, 2) == 0);
assert(binomial(1, 0) == 1);
assert(binomial(1, 1) == 1);
assert(binomial(2, 1) == 2);
assert(binomial(2, 1) == 2);
// negative
assert(binomial!long(-5, 3) == -35);
assert(binomial!long(5, -3) == 0);
}
version(mir_test) unittest
{
import std.bigint;
// test larger numbers
assert(binomial(100, 10) == 17_310_309_456_440);
assert(binomial(999, 5) == 82_09_039_793_949);
assert(binomial(300, 10) == 1_398_320_233_241_701_770LU);
assert(binomial(300LU, 10LU) == 1_398_320_233_241_701_770LU);
// test overflow
assert(binomial(500, 10) == 0);
// all parameters as custom types
BigInt n = 1010, k = 9;
assert(binomial!BigInt(n, k) == BigInt("2908077120956865974260"));
// negative
assert(binomial!BigInt(-5, 3) == -35);
assert(binomial!BigInt(5, -3) == 0);
assert(binomial!BigInt(-5, -7) == 15);
}
version(mir_test)
@safe pure nothrow @nogc
unittest
{
const size_t n = 5;
const size_t k = 2;
assert(binomial(n, k) == 10);
}
/**
Creates a projection of a generalized `Collection` range for the numeric case
case starting from `0` onto a custom `range` of any type.
Params:
collection = range to be projected from
range = random access range to be projected to
Returns:
Range with a projection to range for every element of collection
See_Also:
$(LREF permutations), $(LREF cartesianPower), $(LREF combinations),
$(LREF combinationsRepeat)
*/
IndexedRoR!(Collection, Range) indexedRoR(Collection, Range)(Collection collection, Range range)
if (__traits(compiles, Range.init[size_t.init]))
{
return IndexedRoR!(Collection, Range)(collection, range);
}
/// ditto
struct IndexedRoR(Collection, Range)
if (__traits(compiles, Range.init[size_t.init]))
{
private Collection c;
private Range r;
///
alias DeepElement = ForeachType!Range;
///
this()(Collection collection, Range range)
{
this.c = collection;
this.r = range;
}
///
auto lightScope()() return scope
{
return IndexedRoR!(LightScopeOf!Collection, LightScopeOf!Range)(.lightScope(c), .lightScope(r));
}
///
auto lightScope()() return scope const
{
return IndexedRoR!(LightConstOf!(LightScopeOf!Collection), LightConstOf!(LightScopeOf!Range))(.lightScope(c), .lightScope(r));
}
///
auto lightConst()() return scope const
{
return IndexedRoR!(LightConstOf!Collection, LightConstOf!Range)(.lightConst(c), .lightConst(r));
}
/// Input range primitives
auto front()() @property
{
import mir.ndslice.slice: isSlice, sliced;
import mir.ndslice.topology: indexed;
import std.traits: ForeachType;
static if (isSlice!(ForeachType!Collection))
return r.indexed(c.front);
else
return r.indexed(c.front.sliced);
}
/// ditto
void popFront() scope
{
c.popFront;
}
/// ditto
bool empty()() @property scope const
{
return c.empty;
}
static if (hasLength!Collection)
{
/// ditto
@property size_t length()() scope const
{
return c.length;
}
///
@property size_t[2] shape()() scope const
{
return c.shape;
}
}
static if (__traits(hasMember, Collection, "save"))
{
/// Forward range primitive. Calls `collection.save`.
typeof(this) save()() @property
{
return IndexedRoR!(Collection, Range)(c.save, r);
}
}
}
///
@safe pure nothrow version(mir_test) unittest
{
import mir.ndslice.fuse;
auto perms = 2.permutations;
assert(perms.save.fuse == [[0, 1], [1, 0]]);
auto projection = perms.indexedRoR([1, 2]);
assert(projection.fuse == [[1, 2], [2, 1]]);
}
///
version(mir_test) unittest
{
import mir.ndslice.fuse;
import std.string: representation;
// import mir.ndslice.topology: only;
auto projectionD = 2.permutations.indexedRoR("ab"d.representation);
assert(projectionD.fuse == [['a', 'b'], ['b', 'a']]);
// auto projectionC = 2.permutations.indexedRoR(only('a', 'b'));
// assert(projectionC.fuse == [['a', 'b'], ['b', 'a']]);
}
@safe pure nothrow version(mir_test) unittest
{
import mir.ndslice.fuse;
import std.range: dropOne;
auto perms = 2.permutations;
auto projection = perms.indexedRoR([1, 2]);
assert(projection.length == 2);
// can save
assert(projection.save.dropOne.front == [2, 1]);
assert(projection.front == [1, 2]);
}
@safe nothrow @nogc version(mir_test) unittest
{
import mir.algorithm.iteration: all;
import mir.ndslice.slice: sliced;
import mir.ndslice.fuse;
static perms = 2.permutations;
static immutable projectionArray = [1, 2];
auto projection = perms.indexedRoR(projectionArray);
static immutable result = [1, 2,
2, 1];
assert(result.sliced(2, 2).all!"a == b"(projection));
}
/**
Lazily computes all _permutations of `r` using $(WEB
en.wikipedia.org/wiki/Heap%27s_algorithm, Heap's algorithm).
While generating a new item is in `O(k)` (amortized `O(1)`),
the number of permutations is `|n|!`.
Params:
n = number of elements (`|r|`)
r = random access field. A field may not have iteration primitivies.
alloc = custom Allocator
Returns:
Forward range, which yields the permutations
See_Also:
$(LREF Permutations)
*/
Permutations!T permutations(T = uint)(size_t n) @safe pure nothrow
if (isUnsigned!T && T.sizeof <= size_t.sizeof)
{
assert(n, "must have at least one item");
return Permutations!T(new T[n-1], new T[n]);
}
/// ditto
IndexedRoR!(Permutations!T, Range) permutations(T = uint, Range)(Range r) @safe pure nothrow
if (__traits(compiles, Range.init[size_t.init]))
{
return permutations!T(r.length).indexedRoR(r);
}
/// ditto
Permutations!T makePermutations(T = uint, Allocator)(auto ref Allocator alloc, size_t n)
if (isUnsigned!T && T.sizeof <= size_t.sizeof)
{
assert(n, "must have at least one item");
import std.experimental.allocator: makeArray;
auto state = alloc.makeArray!T(n - 1);
auto indices = alloc.makeArray!T(n);
return Permutations!T(state, indices);
}
/**
Lazy Forward range of permutations using $(WEB
en.wikipedia.org/wiki/Heap%27s_algorithm, Heap's algorithm).
It always generates the permutations from 0 to `n - 1`,
use $(LREF indexedRoR) to map it to your range.
Generating a new item is in `O(k)` (amortized `O(1)`),
the total number of elements is `n^k`.
See_Also:
$(LREF permutations), $(LREF makePermutations)
*/
struct Permutations(T)
if (isUnsigned!T && T.sizeof <= size_t.sizeof)
{
import mir.ndslice.slice: sliced, Slice;
private T[] indices, state;
private bool _empty;
private size_t _max_states = 1, _pos;
///
alias DeepElement = const T;
/**
state should have the length of `n - 1`,
whereas the length of indices should be `n`
*/
this()(T[] state, T[] indices) @safe pure nothrow @nogc
{
assert(state.length + 1 == indices.length);
// iota
foreach (i, ref index; indices)
index = cast(T)i;
state[] = 0;
this.indices = indices;
this.state = state;
_empty = indices.length == 0;
// factorial
foreach (i; 1..indices.length + 1)
_max_states *= i;
}
/// Input range primitives
@property Slice!(const(T)*) front()() @safe pure nothrow @nogc
{
import mir.ndslice.slice: sliced;
return indices.sliced;
}
/// ditto
void popFront()() scope @safe pure nothrow @nogc
{
import std.algorithm.mutation : swapAt;
assert(!empty);
_pos++;
for (T h = 0;;h++)
{
if (h + 2 > indices.length)
{
_empty = true;
break;
}
indices.swapAt((h & 1) ? 0 : state[h], h + 1);
if (state[h] == h + 1)
{
state[h] = 0;
continue;
}
state[h]++;
break;
}
}
/// ditto
@property bool empty()() @safe pure nothrow @nogc scope const
{
return _empty;
}
/// ditto
@property size_t length()() @safe pure nothrow @nogc scope const
{
return _max_states - _pos;
}
///
@property size_t[2] shape()() scope const
{
return [length, indices.length];
}
/// Forward range primitive. Allocates using GC.
@property Permutations save()() @safe pure nothrow
{
typeof(this) c = this;
c.indices = indices.dup;
c.state = state.dup;
return c;
}
}
///
pure @safe nothrow version(mir_test) unittest
{
import mir.ndslice.fuse;
import mir.ndslice.topology : iota;
auto expectedRes = [[0, 1, 2],
[1, 0, 2],
[2, 0, 1],
[0, 2, 1],
[1, 2, 0],
[2, 1, 0]];
auto r = iota(3);
auto rp = permutations(r.length).indexedRoR(r);
assert(rp.fuse == expectedRes);
// direct style
auto rp2 = iota(3).permutations;
assert(rp2.fuse == expectedRes);
}
///
@nogc version(mir_test) unittest
{
import mir.algorithm.iteration: equal;
import mir.ndslice.slice: sliced;
import mir.ndslice.topology : iota;
import std.experimental.allocator.mallocator;
static immutable expected2 = [0, 1, 1, 0];
auto r = iota(2);
auto rp = makePermutations(Mallocator.instance, r.length);
assert(expected2.sliced(2, 2).equal(rp.indexedRoR(r)));
dispose(Mallocator.instance, rp);
}
pure @safe nothrow version(mir_test) unittest
{
// is copyable?
import mir.ndslice.fuse;
import mir.ndslice.topology: iota;
import std.range: dropOne;
auto a = iota(2).permutations;
assert(a.front == [0, 1]);
assert(a.save.dropOne.front == [1, 0]);
assert(a.front == [0, 1]);
// length
assert(1.permutations.length == 1);
assert(2.permutations.length == 2);
assert(3.permutations.length == 6);
assert(4.permutations.length == 24);
assert(10.permutations.length == 3_628_800);
}
version (assert)
version(mir_test) unittest
{
// check invalid
import std.exception: assertThrown;
import core.exception: AssertError;
import std.experimental.allocator.mallocator: Mallocator;
assertThrown!AssertError(0.permutations);
assertThrown!AssertError(Mallocator.instance.makePermutations(0));
}
/**
Disposes a Permutations object. It destroys and then deallocates the
Permutations object pointed to by a pointer.
It is assumed the respective entities had been allocated with the same allocator.
Params:
alloc = Custom allocator
perm = Permutations object
See_Also:
$(LREF makePermutations)
*/
void dispose(T, Allocator)(auto ref Allocator alloc, auto ref Permutations!T perm)
{
import std.experimental.allocator: dispose;
dispose(alloc, perm.state);
dispose(alloc, perm.indices);
}
/**
Lazily computes the Cartesian power of `r` with itself
for a number of repetitions `D repeat`.
If the input is sorted, the product is in lexicographic order.
While generating a new item is in `O(k)` (amortized `O(1)`),
the total number of elements is `n^k`.
Params:
n = number of elements (`|r|`)
r = random access field. A field may not have iteration primitivies.
repeat = number of repetitions
alloc = custom Allocator
Returns:
Forward range, which yields the product items
See_Also:
$(LREF CartesianPower)
*/
CartesianPower!T cartesianPower(T = uint)(size_t n, size_t repeat = 1) @safe pure nothrow
if (isUnsigned!T && T.sizeof <= size_t.sizeof)
{
assert(repeat >= 1, "Invalid number of repetitions");
return CartesianPower!T(n, new T[repeat]);
}
/// ditto
IndexedRoR!(CartesianPower!T, Range) cartesianPower(T = uint, Range)(Range r, size_t repeat = 1)
if (isUnsigned!T && __traits(compiles, Range.init[size_t.init]))
{
assert(repeat >= 1, "Invalid number of repetitions");
return cartesianPower!T(r.length, repeat).indexedRoR(r);
}
/// ditto
CartesianPower!T makeCartesianPower(T = uint, Allocator)(auto ref Allocator alloc, size_t n, size_t repeat)
if (isUnsigned!T && T.sizeof <= size_t.sizeof)
{
assert(repeat >= 1, "Invalid number of repetitions");
import std.experimental.allocator: makeArray;
return CartesianPower!T(n, alloc.makeArray!T(repeat));
}
/**
Lazy Forward range of Cartesian Power.
It always generates Cartesian Power from 0 to `n - 1`,
use $(LREF indexedRoR) to map it to your range.
Generating a new item is in `O(k)` (amortized `O(1)`),
the total number of elements is `n^k`.
See_Also:
$(LREF cartesianPower), $(LREF makeCartesianPower)
*/
struct CartesianPower(T)
if (isUnsigned!T && T.sizeof <= size_t.sizeof)
{
import mir.ndslice.slice: Slice;
private T[] _state;
private size_t n;
private size_t _max_states, _pos;
///
alias DeepElement = const T;
/// state should have the length of `repeat`
this()(size_t n, T[] state) @safe pure nothrow @nogc
{
assert(state.length >= 1, "Invalid number of repetitions");
import std.math: pow;
this.n = n;
assert(n <= T.max);
this._state = state;
_max_states = pow(n, state.length);
}
/// Input range primitives
@property Slice!(const(T)*) front()() @safe pure nothrow @nogc
{
import mir.ndslice.slice: sliced;
return _state.sliced;
}
/// ditto
void popFront()() scope @safe pure nothrow @nogc
{
assert(!empty);
_pos++;
/*
* Bitwise increment - starting from back
* It works like adding 1 in primary school arithmetic.
* If a block has reached the number of elements, we reset it to
* 0, and continue to increment, e.g. for n = 2:
*
* [0, 0, 0] -> [0, 0, 1]
* [0, 1, 1] -> [1, 0, 0]
*/
foreach_reverse (i, ref el; _state)
{
++el;
if (el < n)
break;
el = 0;
}
}
/// ditto
@property size_t length()() @safe pure nothrow @nogc scope const
{
return _max_states - _pos;
}
/// ditto
@property bool empty()() @safe pure nothrow @nogc scope const
{
return _pos == _max_states;
}
///
@property size_t[2] shape()() scope const
{
return [length, _state.length];
}
/// Forward range primitive. Allocates using GC.
@property CartesianPower save()() @safe pure nothrow
{
typeof(this) c = this;
c._state = _state.dup;
return c;
}
}
///
pure nothrow @safe version(mir_test) unittest
{
import mir.ndslice.fuse;
import mir.ndslice.topology: iota;
assert(iota(2).cartesianPower.fuse == [[0], [1]]);
assert(iota(2).cartesianPower(2).fuse == [[0, 0], [0, 1], [1, 0], [1, 1]]);
auto three_nums_two_bins = [[0, 0], [0, 1], [0, 2], [1, 0], [1, 1], [1, 2], [2, 0], [2, 1], [2, 2]];
assert(iota(3).cartesianPower(2).fuse == three_nums_two_bins);
import std.string: representation;
assert("AB"d.representation.cartesianPower(2).fuse == ["AA"d, "AB"d, "BA"d, "BB"d]);
}
///
@nogc version(mir_test) unittest
{
import mir.ndslice.topology: iota;
import mir.algorithm.iteration: equal;
import mir.ndslice.slice: sliced;
import std.experimental.allocator.mallocator: Mallocator;
auto alloc = Mallocator.instance;
static immutable expected2r2 = [
0, 0,
0, 1,
1, 0,
1, 1];
auto r = iota(2);
auto rc = alloc.makeCartesianPower(r.length, 2);
assert(expected2r2.sliced(4, 2).equal(rc.indexedRoR(r)));
alloc.dispose(rc);
}
pure nothrow @safe version(mir_test) unittest
{
import mir.ndslice.fuse;
import mir.array.allocation: array;
import mir.ndslice.topology: iota;
import std.range: dropOne;
import std.string: representation;
assert(iota(0).cartesianPower.length == 0);
assert("AB"d.representation.cartesianPower(3).fuse == ["AAA"d, "AAB"d, "ABA"d, "ABB"d, "BAA"d, "BAB"d, "BBA"d, "BBB"d]);
auto expected = ["AA"d, "AB"d, "AC"d, "AD"d,
"BA"d, "BB"d, "BC"d, "BD"d,
"CA"d, "CB"d, "CC"d, "CD"d,
"DA"d, "DB"d, "DC"d, "DD"d];
assert("ABCD"d.representation.cartesianPower(2).fuse == expected);
// verify with array too
assert("ABCD"d.representation.cartesianPower(2).fuse == expected);
assert(iota(2).cartesianPower.front == [0]);
// is copyable?
auto a = iota(2).cartesianPower;
assert(a.front == [0]);
assert(a.save.dropOne.front == [1]);
assert(a.front == [0]);
// test length shrinking
auto d = iota(2).cartesianPower;
assert(d.length == 2);
d.popFront;
assert(d.length == 1);
}
version(assert)
version(mir_test) unittest
{
// check invalid
import std.exception: assertThrown;
import core.exception: AssertError;
import std.experimental.allocator.mallocator : Mallocator;
assertThrown!AssertError(0.cartesianPower(0));
assertThrown!AssertError(Mallocator.instance.makeCartesianPower(0, 0));
}
// length
pure nothrow @safe version(mir_test) unittest
{
assert(1.cartesianPower(1).length == 1);
assert(1.cartesianPower(2).length == 1);
assert(2.cartesianPower(1).length == 2);
assert(2.cartesianPower(2).length == 4);
assert(2.cartesianPower(3).length == 8);
assert(3.cartesianPower(1).length == 3);
assert(3.cartesianPower(2).length == 9);
assert(3.cartesianPower(3).length == 27);
assert(3.cartesianPower(4).length == 81);
assert(4.cartesianPower(10).length == 1_048_576);
assert(14.cartesianPower(7).length == 105_413_504);
}
/**
Disposes a CartesianPower object. It destroys and then deallocates the
CartesianPower object pointed to by a pointer.
It is assumed the respective entities had been allocated with the same allocator.
Params:
alloc = Custom allocator
cartesianPower = CartesianPower object
See_Also:
$(LREF makeCartesianPower)
*/
void dispose(T = uint, Allocator)(auto ref Allocator alloc, auto ref CartesianPower!T cartesianPower)
{
import std.experimental.allocator: dispose;
dispose(alloc, cartesianPower._state);
}
/**
Lazily computes all k-combinations of `r`.
Imagine this as the $(LREF cartesianPower) filtered for only strictly ordered items.
While generating a new combination is in `O(k)`,
the number of combinations is `binomial(n, k)`.
Params:
n = number of elements (`|r|`)
r = random access field. A field may not have iteration primitivies.
k = number of combinations
alloc = custom Allocator
Returns:
Forward range, which yields the k-combinations items
See_Also:
$(LREF Combinations)
*/
Combinations!T combinations(T = uint)(size_t n, size_t k = 1) @safe pure nothrow
if (isUnsigned!T && T.sizeof <= size_t.sizeof)
{
assert(k >= 1, "Invalid number of combinations");
return Combinations!T(n, new T[k]);
}
/// ditto
IndexedRoR!(Combinations!T, Range) combinations(T = uint, Range)(Range r, size_t k = 1)
if (isUnsigned!T && __traits(compiles, Range.init[size_t.init]))
{
assert(k >= 1, "Invalid number of combinations");
return combinations!T(r.length, k).indexedRoR(r);
}
/// ditto
Combinations!T makeCombinations(T = uint, Allocator)(auto ref Allocator alloc, size_t n, size_t repeat)
if (isUnsigned!T && T.sizeof <= size_t.sizeof)
{
assert(repeat >= 1, "Invalid number of repetitions");
import std.experimental.allocator: makeArray;
return Combinations!T(cast(T) n, alloc.makeArray!T(cast(T) repeat));
}
/**
Lazy Forward range of Combinations.
It always generates combinations from 0 to `n - 1`,
use $(LREF indexedRoR) to map it to your range.
Generating a new combination is in `O(k)`,
the number of combinations is `binomial(n, k)`.
See_Also:
$(LREF combinations), $(LREF makeCombinations)
*/
struct Combinations(T)
if (isUnsigned!T && T.sizeof <= size_t.sizeof)
{
import mir.ndslice.slice: Slice;
private T[] state;
private size_t n;
private size_t max_states, pos;
///
alias DeepElement = const T;
/// state should have the length of `repeat`
this()(size_t n, T[] state) @safe pure nothrow @nogc
{
import mir.ndslice.topology: iota;
assert(state.length <= T.max);
this.n = n;
assert(n <= T.max);
this.max_states = cast(size_t) binomial(n, state.length);
this.state = state;
// set initial state and calculate max possibilities
if (n > 0)
{
// skip first duplicate
if (n > 1 && state.length > 1)
{
auto iotaResult = iota(state.length);
foreach (i, ref el; state)
{
el = cast(T) iotaResult[i];
}
}
}
}
/// Input range primitives
@property Slice!(const(T)*) front()() @safe pure nothrow @nogc
{
import mir.ndslice.slice: sliced;
return state.sliced;
}
/// ditto
void popFront()() scope @safe pure nothrow @nogc
{
assert(!empty);
pos++;
// we might have bumped into the end state now
if (empty) return;
// Behaves like: do _getNextState(); while (!_state.isStrictlySorted);
size_t i = state.length - 1;
/* Go from the back to next settable block
* - A must block must be lower than it's previous
* - A state i is not settable if it's maximum height is reached
*
* Think of it as a backwords search on state with
* iota(_repeat + d, _repeat + d) as search mask.
* (d = _nrElements -_repeat)
*
* As an example n = 3, r = 2, iota is [1, 2] and hence:
* [0, 1] -> i = 2
* [0, 2] -> i = 1
*/
while (state[i] == n - state.length + i)
{
i--;
}
state[i] = cast(T)(state[i] + 1);
/* Starting from our changed block, we need to take the change back
* to the end of the state array and update them by their new diff.
* [0, 1, 4] -> [0, 2, 3]
* [0, 3, 4] -> [1, 2, 3]
*/
foreach (j; i + 1 .. state.length)
{
state[j] = cast(T)(state[i] + j - i);
}
}
/// ditto
@property size_t length()() @safe pure nothrow @nogc scope const
{
return max_states - pos;
}
/// ditto
@property bool empty()() @safe pure nothrow @nogc scope const
{
return pos == max_states;
}
///
@property size_t[2] shape()() scope const
{
return [length, state.length];
}
/// Forward range primitive. Allocates using GC.
@property Combinations save()() @safe pure nothrow
{
typeof(this) c = this;
c.state = state.dup;
return c;
}
}
///
pure nothrow @safe version(mir_test) unittest
{
import mir.ndslice.fuse;
import mir.ndslice.topology: iota;
import std.string: representation;
assert(iota(3).combinations(2).fuse == [[0, 1], [0, 2], [1, 2]]);
assert("AB"d.representation.combinations(2).fuse == ["AB"d]);
assert("ABC"d.representation.combinations(2).fuse == ["AB"d, "AC"d, "BC"d]);
}
///
@nogc version(mir_test) unittest
{
import mir.algorithm.iteration: equal;
import mir.ndslice.slice: sliced;
import mir.ndslice.topology: iota;
import std.experimental.allocator.mallocator;
auto alloc = Mallocator.instance;
static immutable expected3r2 = [
0, 1,
0, 2,
1, 2];
auto r = iota(3);
auto rc = alloc.makeCombinations(r.length, 2);
assert(expected3r2.sliced(3, 2).equal(rc.indexedRoR(r)));
alloc.dispose(rc);
}
pure nothrow @safe version(mir_test) unittest
{
import mir.ndslice.fuse;
import mir.array.allocation: array;
import mir.ndslice.topology: iota;
import std.range: dropOne;
import std.string: representation;
assert(iota(0).combinations.length == 0);
assert(iota(2).combinations.fuse == [[0], [1]]);
auto expected = ["AB"d, "AC"d, "AD"d, "BC"d, "BD"d, "CD"d];
assert("ABCD"d.representation.combinations(2).fuse == expected);
// verify with array too
assert("ABCD"d.representation.combinations(2).fuse == expected);
assert(iota(2).combinations.front == [0]);
// is copyable?
auto a = iota(2).combinations;
assert(a.front == [0]);
assert(a.save.dropOne.front == [1]);
assert(a.front == [0]);
// test length shrinking
auto d = iota(2).combinations;
assert(d.length == 2);
d.popFront;
assert(d.length == 1);
// test larger combinations
auto expected5 = [[0, 1, 2], [0, 1, 3], [0, 1, 4],
[0, 2, 3], [0, 2, 4], [0, 3, 4],
[1, 2, 3], [1, 2, 4], [1, 3, 4],
[2, 3, 4]];
assert(iota(5).combinations(3).fuse == expected5);
assert(iota(4).combinations(3).fuse == [[0, 1, 2], [0, 1, 3], [0, 2, 3], [1, 2, 3]]);
assert(iota(3).combinations(3).fuse == [[0, 1, 2]]);
assert(iota(2).combinations(3).length == 0);
assert(iota(1).combinations(3).length == 0);
assert(iota(3).combinations(2).fuse == [[0, 1], [0, 2], [1, 2]]);
assert(iota(2).combinations(2).fuse == [[0, 1]]);
assert(iota(1).combinations(2).length == 0);
assert(iota(1).combinations(1).fuse == [[0]]);
}
pure nothrow @safe version(mir_test) unittest
{
// test larger combinations
import mir.ndslice.fuse;
import mir.ndslice.topology: iota;
auto expected6r4 = [[0, 1, 2, 3], [0, 1, 2, 4], [0, 1, 2, 5],
[0, 1, 3, 4], [0, 1, 3, 5], [0, 1, 4, 5],
[0, 2, 3, 4], [0, 2, 3, 5], [0, 2, 4, 5],
[0, 3, 4, 5], [1, 2, 3, 4], [1, 2, 3, 5],
[1, 2, 4, 5], [1, 3, 4, 5], [2, 3, 4, 5]];
assert(iota(6).combinations(4).fuse == expected6r4);
auto expected6r3 = [[0, 1, 2], [0, 1, 3], [0, 1, 4], [0, 1, 5],
[0, 2, 3], [0, 2, 4], [0, 2, 5], [0, 3, 4],
[0, 3, 5], [0, 4, 5], [1, 2, 3], [1, 2, 4],
[1, 2, 5], [1, 3, 4], [1, 3, 5], [1, 4, 5],
[2, 3, 4], [2, 3, 5], [2, 4, 5], [3, 4, 5]];
assert(iota(6).combinations(3).fuse == expected6r3);
auto expected6r2 = [[0, 1], [0, 2], [0, 3], [0, 4], [0, 5],
[1, 2], [1, 3], [1, 4], [1, 5], [2, 3],
[2, 4], [2, 5], [3, 4], [3, 5], [4, 5]];
assert(iota(6).combinations(2).fuse == expected6r2);
auto expected7r5 = [[0, 1, 2, 3, 4], [0, 1, 2, 3, 5], [0, 1, 2, 3, 6],
[0, 1, 2, 4, 5], [0, 1, 2, 4, 6], [0, 1, 2, 5, 6],
[0, 1, 3, 4, 5], [0, 1, 3, 4, 6], [0, 1, 3, 5, 6],
[0, 1, 4, 5, 6], [0, 2, 3, 4, 5], [0, 2, 3, 4, 6],
[0, 2, 3, 5, 6], [0, 2, 4, 5, 6], [0, 3, 4, 5, 6],
[1, 2, 3, 4, 5], [1, 2, 3, 4, 6], [1, 2, 3, 5, 6],
[1, 2, 4, 5, 6], [1, 3, 4, 5, 6], [2, 3, 4, 5, 6]];
assert(iota(7).combinations(5).fuse == expected7r5);
}
// length
pure nothrow @safe version(mir_test) unittest
{
assert(1.combinations(1).length == 1);
assert(1.combinations(2).length == 0);
assert(2.combinations(1).length == 2);
assert(2.combinations(2).length == 1);
assert(2.combinations(3).length == 0);
assert(3.combinations(1).length == 3);
assert(3.combinations(2).length == 3);
assert(3.combinations(3).length == 1);
assert(3.combinations(4).length == 0);
assert(4.combinations(10).length == 0);
assert(14.combinations(11).length == 364);
assert(20.combinations(7).length == 77_520);
assert(30.combinations(10).length == 30_045_015);
assert(30.combinations(15).length == 155_117_520);
}
version(assert)
version(mir_test) unittest
{
// check invalid
import std.exception: assertThrown;
import core.exception: AssertError;
import std.experimental.allocator.mallocator: Mallocator;
assertThrown!AssertError(0.combinations(0));
assertThrown!AssertError(Mallocator.instance.makeCombinations(0, 0));
}
/**
Disposes a Combinations object. It destroys and then deallocates the
Combinations object pointed to by a pointer.
It is assumed the respective entities had been allocated with the same allocator.
Params:
alloc = Custom allocator
perm = Combinations object
See_Also:
$(LREF makeCombinations)
*/
void dispose(T, Allocator)(auto ref Allocator alloc, auto ref Combinations!T perm)
{
import std.experimental.allocator: dispose;
dispose(alloc, perm.state);
}
/**
Lazily computes all k-combinations of `r` with repetitions.
A k-combination with repetitions, or k-multicombination,
or multisubset of size k from a set S is given by a sequence of k
not necessarily distinct elements of S, where order is not taken into account.
Imagine this as the cartesianPower filtered for only ordered items.
While generating a new combination with repeats is in `O(k)`,
the number of combinations with repeats is `binomial(n + k - 1, k)`.
Params:
n = number of elements (`|r|`)
r = random access field. A field may not have iteration primitivies.
k = number of combinations
alloc = custom Allocator
Returns:
Forward range, which yields the k-multicombinations items
See_Also:
$(LREF CombinationsRepeat)
*/
CombinationsRepeat!T combinationsRepeat(T = uint)(size_t n, size_t k = 1) @safe pure nothrow
if (isUnsigned!T && T.sizeof <= size_t.sizeof)
{
assert(k >= 1, "Invalid number of combinations");
return CombinationsRepeat!T(n, new T[k]);
}
/// ditto
IndexedRoR!(CombinationsRepeat!T, Range) combinationsRepeat(T = uint, Range)(Range r, size_t k = 1)
if (isUnsigned!T && __traits(compiles, Range.init[size_t.init]))
{
assert(k >= 1, "Invalid number of combinations");
return combinationsRepeat!T(r.length, k).indexedRoR(r);
}
/// ditto
CombinationsRepeat!T makeCombinationsRepeat(T = uint, Allocator)(auto ref Allocator alloc, size_t n, size_t repeat)
if (isUnsigned!T && T.sizeof <= size_t.sizeof)
{
assert(repeat >= 1, "Invalid number of repetitions");
import std.experimental.allocator: makeArray;
return CombinationsRepeat!T(n, alloc.makeArray!T(repeat));
}
/**
Lazy Forward range of combinations with repeats.
It always generates combinations with repeats from 0 to `n - 1`,
use $(LREF indexedRoR) to map it to your range.
Generating a new combination with repeats is in `O(k)`,
the number of combinations with repeats is `binomial(n, k)`.
See_Also:
$(LREF combinationsRepeat), $(LREF makeCombinationsRepeat)
*/
struct CombinationsRepeat(T)
if (isUnsigned!T && T.sizeof <= size_t.sizeof)
{
import mir.ndslice.slice: Slice;
private T[] state;
private size_t n;
private size_t max_states, pos;
///
alias DeepElement = const T;
/// state should have the length of `repeat`
this()(size_t n, T[] state) @safe pure nothrow @nogc
{
this.n = n;
assert(n <= T.max);
this.state = state;
size_t repeatLen = state.length;
// set initial state and calculate max possibilities
if (n > 0)
{
max_states = cast(size_t) binomial(n + repeatLen - 1, repeatLen);
}
}
/// Input range primitives
@property Slice!(const(T)*) front()() @safe pure nothrow @nogc
{
import mir.ndslice.slice: sliced;
return state.sliced;
}
/// ditto
void popFront()() scope @safe pure nothrow @nogc
{
assert(!empty);
pos++;
immutable repeat = state.length;
// behaves like: do _getNextState(); while (!_state.isSorted);
size_t i = repeat - 1;
// go to next settable block
// a block is settable if its not in the end state (=nrElements - 1)
while (state[i] == n - 1 && i != 0)
{
i--;
}
state[i] = cast(T)(state[i] + 1);
// if we aren't at the last block, we need to set all blocks
// to equal the current one
// e.g. [0, 2] -> (upper block: [1, 2]) -> [1, 1]
if (i != repeat - 1)
{
for (size_t j = i + 1; j < repeat; j++)
state[j] = state[i];
}
}
/// ditto
@property size_t length()() @safe pure nothrow @nogc scope const
{
return max_states - pos;
}
/// ditto
@property bool empty()() @safe pure nothrow @nogc scope const
{
return pos == max_states;
}
///
@property size_t[2] shape()() scope const
{
return [length, state.length];
}
/// Forward range primitive. Allocates using GC.
@property CombinationsRepeat save()() @safe pure nothrow
{
typeof(this) c = this;
c.state = state.dup;
return c;
}
}
///
pure nothrow @safe version(mir_test) unittest
{
import mir.ndslice.fuse;
import mir.ndslice.topology: iota;
import std.string: representation;
assert(iota(2).combinationsRepeat.fuse == [[0], [1]]);
assert(iota(2).combinationsRepeat(2).fuse == [[0, 0], [0, 1], [1, 1]]);
assert(iota(3).combinationsRepeat(2).fuse == [[0, 0], [0, 1], [0, 2], [1, 1], [1, 2], [2, 2]]);
assert("AB"d.representation.combinationsRepeat(2).fuse == ["AA"d, "AB"d, "BB"d]);
}
///
@nogc version(mir_test) unittest
{
import mir.algorithm.iteration: equal;
import mir.ndslice.slice: sliced;
import mir.ndslice.topology: iota;
import std.experimental.allocator.mallocator;
auto alloc = Mallocator.instance;
static immutable expected3r1 = [
0,
1,
2];
auto r = iota(3);
auto rc = alloc.makeCombinationsRepeat(r.length, 1);
assert(expected3r1.sliced(3, 1).equal(rc.indexedRoR(r)));
alloc.dispose(rc);
}
version(mir_test) unittest
{
import mir.ndslice.fuse;
import mir.array.allocation: array;
import mir.ndslice.topology: iota;
import std.range: dropOne;
import std.string: representation;
assert(iota(0).combinationsRepeat.length == 0);
assert("AB"d.representation.combinationsRepeat(3).fuse == ["AAA"d, "AAB"d, "ABB"d,"BBB"d]);
auto expected = ["AA"d, "AB"d, "AC"d, "AD"d, "BB"d, "BC"d, "BD"d, "CC"d, "CD"d, "DD"d];
assert("ABCD"d.representation.combinationsRepeat(2).fuse == expected);
// verify with array too
assert("ABCD"d.representation.combinationsRepeat(2).fuse == expected);
assert(iota(2).combinationsRepeat.front == [0]);
// is copyable?
auto a = iota(2).combinationsRepeat;
assert(a.front == [0]);
assert(a.save.dropOne.front == [1]);
assert(a.front == [0]);
// test length shrinking
auto d = iota(2).combinationsRepeat;
assert(d.length == 2);
d.popFront;
assert(d.length == 1);
}
// length
pure nothrow @safe version(mir_test) unittest
{
assert(1.combinationsRepeat(1).length == 1);
assert(1.combinationsRepeat(2).length == 1);
assert(2.combinationsRepeat(1).length == 2);
assert(2.combinationsRepeat(2).length == 3);
assert(2.combinationsRepeat(3).length == 4);
assert(3.combinationsRepeat(1).length == 3);
assert(3.combinationsRepeat(2).length == 6);
assert(3.combinationsRepeat(3).length == 10);
assert(3.combinationsRepeat(4).length == 15);
assert(4.combinationsRepeat(10).length == 286);
assert(11.combinationsRepeat(14).length == 1_961_256);
assert(20.combinationsRepeat(7).length == 657_800);
assert(20.combinationsRepeat(10).length == 20_030_010);
assert(30.combinationsRepeat(10).length == 635_745_396);
}
pure nothrow @safe version(mir_test) unittest
{
// test larger combinations
import mir.ndslice.fuse;
import mir.ndslice.topology: iota;
auto expected3r1 = [[0], [1], [2]];
assert(iota(3).combinationsRepeat(1).fuse == expected3r1);
auto expected3r2 = [[0, 0], [0, 1], [0, 2], [1, 1], [1, 2], [2, 2]];
assert(iota(3).combinationsRepeat(2).fuse == expected3r2);
auto expected3r3 = [[0, 0, 0], [0, 0, 1], [0, 0, 2], [0, 1, 1],
[0, 1, 2], [0, 2, 2], [1, 1, 1], [1, 1, 2],
[1, 2, 2], [2, 2, 2]];
assert(iota(3).combinationsRepeat(3).fuse == expected3r3);
auto expected3r4 = [[0, 0, 0, 0], [0, 0, 0, 1], [0, 0, 0, 2],
[0, 0, 1, 1], [0, 0, 1, 2], [0, 0, 2, 2],
[0, 1, 1, 1], [0, 1, 1, 2], [0, 1, 2, 2],
[0, 2, 2, 2], [1, 1, 1, 1], [1, 1, 1, 2],
[1, 1, 2, 2], [1, 2, 2, 2], [2, 2, 2, 2]];
assert(iota(3).combinationsRepeat(4).fuse == expected3r4);
auto expected4r3 = [[0, 0, 0], [0, 0, 1], [0, 0, 2],
[0, 0, 3], [0, 1, 1], [0, 1, 2],
[0, 1, 3], [0, 2, 2], [0, 2, 3],
[0, 3, 3], [1, 1, 1], [1, 1, 2],
[1, 1, 3], [1, 2, 2], [1, 2, 3],
[1, 3, 3], [2, 2, 2], [2, 2, 3],
[2, 3, 3], [3, 3, 3]];
assert(iota(4).combinationsRepeat(3).fuse == expected4r3);
auto expected4r2 = [[0, 0], [0, 1], [0, 2], [0, 3],
[1, 1], [1, 2], [1, 3], [2, 2],
[2, 3], [3, 3]];
assert(iota(4).combinationsRepeat(2).fuse == expected4r2);
auto expected5r3 = [[0, 0, 0], [0, 0, 1], [0, 0, 2], [0, 0, 3], [0, 0, 4],
[0, 1, 1], [0, 1, 2], [0, 1, 3], [0, 1, 4], [0, 2, 2],
[0, 2, 3], [0, 2, 4], [0, 3, 3], [0, 3, 4], [0, 4, 4],
[1, 1, 1], [1, 1, 2], [1, 1, 3], [1, 1, 4], [1, 2, 2],
[1, 2, 3], [1, 2, 4], [1, 3, 3], [1, 3, 4], [1, 4, 4],
[2, 2, 2], [2, 2, 3], [2, 2, 4], [2, 3, 3], [2, 3, 4],
[2, 4, 4], [3, 3, 3], [3, 3, 4], [3, 4, 4], [4, 4, 4]];
assert(iota(5).combinationsRepeat(3).fuse == expected5r3);
auto expected5r2 = [[0, 0], [0, 1], [0, 2], [0, 3], [0, 4],
[1, 1], [1, 2], [1, 3], [1, 4], [2, 2],
[2, 3], [2, 4], [3, 3], [3, 4], [4, 4]];
assert(iota(5).combinationsRepeat(2).fuse == expected5r2);
}
version(assert)
version(mir_test) unittest
{
// check invalid
import std.exception: assertThrown;
import core.exception: AssertError;
import std.experimental.allocator.mallocator: Mallocator;
assertThrown!AssertError(0.combinationsRepeat(0));
assertThrown!AssertError(Mallocator.instance.makeCombinationsRepeat(0, 0));
}
/**
Disposes a CombinationsRepeat object. It destroys and then deallocates the
CombinationsRepeat object pointed to by a pointer.
It is assumed the respective entities had been allocated with the same allocator.
Params:
alloc = Custom allocator
perm = CombinationsRepeat object
See_Also:
$(LREF makeCombinationsRepeat)
*/
void dispose(T, Allocator)(auto ref Allocator alloc, auto ref CombinationsRepeat!T perm)
{
import std.experimental.allocator: dispose;
dispose(alloc, perm.state);
}
| D |
module android.java.android.R_drawable;
public import android.java.android.R_drawable_d_interface;
import arsd.jni : ImportExportImpl;
mixin ImportExportImpl!R_drawable;
import import0 = android.java.java.lang.Class;
| D |
/Users/AleixDiaz/Desktop/VaporProject/LaSalleChat/.build/x86_64-apple-macosx10.10/debug/Vapor.build/JSON/HTTP/Body+JSON.swift.o : /Users/AleixDiaz/Desktop/VaporProject/LaSalleChat/.build/checkouts/vapor.git-5492988889259800272/Sources/Vapor/JSON/HTTP/Message+JSON.swift /Users/AleixDiaz/Desktop/VaporProject/LaSalleChat/.build/checkouts/vapor.git-5492988889259800272/Sources/Vapor/JSON/HTTP/Response+JSON.swift /Users/AleixDiaz/Desktop/VaporProject/LaSalleChat/.build/checkouts/vapor.git-5492988889259800272/Sources/Vapor/JSON/HTTP/Body+JSON.swift /Users/AleixDiaz/Desktop/VaporProject/LaSalleChat/.build/checkouts/vapor.git-5492988889259800272/Sources/Vapor/JSON/JSON.swift /Users/AleixDiaz/Desktop/VaporProject/LaSalleChat/.build/checkouts/vapor.git-5492988889259800272/Sources/Vapor/Multipart/Request+FormData.swift /Users/AleixDiaz/Desktop/VaporProject/LaSalleChat/.build/checkouts/vapor.git-5492988889259800272/Sources/Vapor/View/ViewData.swift /Users/AleixDiaz/Desktop/VaporProject/LaSalleChat/.build/checkouts/vapor.git-5492988889259800272/Sources/Vapor/Multipart/FormData+Polymorphic.swift /Users/AleixDiaz/Desktop/VaporProject/LaSalleChat/.build/checkouts/vapor.git-5492988889259800272/Sources/Vapor/FormURLEncoded/StructuredData+FormURLEncoded.swift /Users/AleixDiaz/Desktop/VaporProject/LaSalleChat/.build/checkouts/vapor.git-5492988889259800272/Sources/Vapor/FormURLEncoded/Request+FormURLEncoded.swift /Users/AleixDiaz/Desktop/VaporProject/LaSalleChat/.build/checkouts/vapor.git-5492988889259800272/Sources/Vapor/Commands/Config+Command.swift /Users/AleixDiaz/Desktop/VaporProject/LaSalleChat/.build/checkouts/vapor.git-5492988889259800272/Sources/Vapor/Log/Log+Convenience.swift /Users/AleixDiaz/Desktop/VaporProject/LaSalleChat/.build/checkouts/vapor.git-5492988889259800272/Sources/Vapor/Utilities/StringCharacterSequence.swift /Users/AleixDiaz/Desktop/VaporProject/LaSalleChat/.build/checkouts/vapor.git-5492988889259800272/Sources/Vapor/Routing/Resource.swift /Users/AleixDiaz/Desktop/VaporProject/LaSalleChat/.build/checkouts/vapor.git-5492988889259800272/Sources/Vapor/HTTP/HTTP+Node.swift /Users/AleixDiaz/Desktop/VaporProject/LaSalleChat/.build/checkouts/vapor.git-5492988889259800272/Sources/Vapor/HTTP/AcceptLanguage.swift /Users/AleixDiaz/Desktop/VaporProject/LaSalleChat/.build/checkouts/vapor.git-5492988889259800272/Sources/Vapor/Cache/Config+Cache.swift /Users/AleixDiaz/Desktop/VaporProject/LaSalleChat/.build/checkouts/vapor.git-5492988889259800272/Sources/Vapor/JSON/HTTP/Message+Codable.swift /Users/AleixDiaz/Desktop/VaporProject/LaSalleChat/.build/checkouts/vapor.git-5492988889259800272/Sources/Vapor/JSON/HTTP/Response+Codable.swift /Users/AleixDiaz/Desktop/VaporProject/LaSalleChat/.build/checkouts/vapor.git-5492988889259800272/Sources/Vapor/Config/Configurable.swift /Users/AleixDiaz/Desktop/VaporProject/LaSalleChat/.build/checkouts/vapor.git-5492988889259800272/Sources/Vapor/JSON/JSONRepresentable.swift /Users/AleixDiaz/Desktop/VaporProject/LaSalleChat/.build/checkouts/vapor.git-5492988889259800272/Sources/Vapor/Utilities/StringInitializable.swift /Users/AleixDiaz/Desktop/VaporProject/LaSalleChat/.build/checkouts/vapor.git-5492988889259800272/Sources/Vapor/HTTP/RequestInitializable.swift /Users/AleixDiaz/Desktop/VaporProject/LaSalleChat/.build/checkouts/vapor.git-5492988889259800272/Sources/Vapor/Commands/Config+Console.swift /Users/AleixDiaz/Desktop/VaporProject/LaSalleChat/.build/checkouts/vapor.git-5492988889259800272/Sources/Vapor/Commands/Vapor+Console.swift /Users/AleixDiaz/Desktop/VaporProject/LaSalleChat/.build/checkouts/vapor.git-5492988889259800272/Sources/Vapor/Content/MediaType.swift /Users/AleixDiaz/Desktop/VaporProject/LaSalleChat/.build/checkouts/vapor.git-5492988889259800272/Sources/Vapor/Middleware/Config+Middleware.swift /Users/AleixDiaz/Desktop/VaporProject/LaSalleChat/.build/checkouts/vapor.git-5492988889259800272/Sources/Vapor/CORS/CORSMiddleware.swift /Users/AleixDiaz/Desktop/VaporProject/LaSalleChat/.build/checkouts/vapor.git-5492988889259800272/Sources/Vapor/File/FileMiddleware.swift /Users/AleixDiaz/Desktop/VaporProject/LaSalleChat/.build/checkouts/vapor.git-5492988889259800272/Sources/Vapor/Date/DateMiddleware.swift /Users/AleixDiaz/Desktop/VaporProject/LaSalleChat/.build/checkouts/vapor.git-5492988889259800272/Sources/Vapor/Error/ErrorMiddleware.swift /Users/AleixDiaz/Desktop/VaporProject/LaSalleChat/.build/checkouts/vapor.git-5492988889259800272/Sources/Vapor/File/File+Response.swift /Users/AleixDiaz/Desktop/VaporProject/LaSalleChat/.build/checkouts/vapor.git-5492988889259800272/Sources/Vapor/Config/Resolve.swift /Users/AleixDiaz/Desktop/VaporProject/LaSalleChat/.build/checkouts/vapor.git-5492988889259800272/Sources/Vapor/Serve/Serve.swift /Users/AleixDiaz/Desktop/VaporProject/LaSalleChat/.build/checkouts/vapor.git-5492988889259800272/Sources/Vapor/Commands/DumpConfig.swift /Users/AleixDiaz/Desktop/VaporProject/LaSalleChat/.build/checkouts/vapor.git-5492988889259800272/Sources/Vapor/Serve/Config+ServerConfig.swift /Users/AleixDiaz/Desktop/VaporProject/LaSalleChat/.build/checkouts/vapor.git-5492988889259800272/Sources/Vapor/Serve/ServerConfig.swift /Users/AleixDiaz/Desktop/VaporProject/LaSalleChat/.build/checkouts/vapor.git-5492988889259800272/Sources/Vapor/Cipher/CryptoEncoding.swift /Users/AleixDiaz/Desktop/VaporProject/LaSalleChat/.build/checkouts/vapor.git-5492988889259800272/Sources/Vapor/Middleware/Chaining.swift /Users/AleixDiaz/Desktop/VaporProject/LaSalleChat/.build/checkouts/vapor.git-5492988889259800272/Sources/Vapor/Routing/Droplet+Routing.swift /Users/AleixDiaz/Desktop/VaporProject/LaSalleChat/.build/checkouts/vapor.git-5492988889259800272/Sources/Vapor/Log/Config+Log.swift /Users/AleixDiaz/Desktop/VaporProject/LaSalleChat/.build/checkouts/vapor.git-5492988889259800272/Sources/Vapor/Routing/RoutesLog.swift /Users/AleixDiaz/Desktop/VaporProject/LaSalleChat/.build/checkouts/vapor.git-5492988889259800272/Sources/Vapor/Hash/Config+Hash.swift /Users/AleixDiaz/Desktop/VaporProject/LaSalleChat/.build/checkouts/vapor.git-5492988889259800272/Sources/Vapor/Log/LogLevel.swift /Users/AleixDiaz/Desktop/VaporProject/LaSalleChat/.build/checkouts/vapor.git-5492988889259800272/Sources/Vapor/Mail/Config+Mail.swift /Users/AleixDiaz/Desktop/VaporProject/LaSalleChat/.build/checkouts/vapor.git-5492988889259800272/Sources/Vapor/Mail/Mail.swift /Users/AleixDiaz/Desktop/VaporProject/LaSalleChat/.build/checkouts/vapor.git-5492988889259800272/Sources/Vapor/Provider/ProviderInstall.swift /Users/AleixDiaz/Desktop/VaporProject/LaSalleChat/.build/checkouts/vapor.git-5492988889259800272/Sources/Vapor/Log/LogProtocol.swift /Users/AleixDiaz/Desktop/VaporProject/LaSalleChat/.build/checkouts/vapor.git-5492988889259800272/Sources/Vapor/Hash/HashProtocol.swift /Users/AleixDiaz/Desktop/VaporProject/LaSalleChat/.build/checkouts/vapor.git-5492988889259800272/Sources/Vapor/Cipher/CipherProtocol.swift /Users/AleixDiaz/Desktop/VaporProject/LaSalleChat/.build/checkouts/vapor.git-5492988889259800272/Sources/Vapor/Engine/Server/ServerProtocol.swift /Users/AleixDiaz/Desktop/VaporProject/LaSalleChat/.build/checkouts/vapor.git-5492988889259800272/Sources/Vapor/Engine/Client/ClientProtocol.swift /Users/AleixDiaz/Desktop/VaporProject/LaSalleChat/.build/checkouts/vapor.git-5492988889259800272/Sources/Vapor/Engine/Server/ServerFactoryProtocol.swift /Users/AleixDiaz/Desktop/VaporProject/LaSalleChat/.build/checkouts/vapor.git-5492988889259800272/Sources/Vapor/Engine/Client/ClientFactoryProtocol.swift /Users/AleixDiaz/Desktop/VaporProject/LaSalleChat/.build/checkouts/vapor.git-5492988889259800272/Sources/Vapor/Hash/Int+Random.swift /Users/AleixDiaz/Desktop/VaporProject/LaSalleChat/.build/checkouts/vapor.git-5492988889259800272/Sources/Vapor/Commands/Version.swift /Users/AleixDiaz/Desktop/VaporProject/LaSalleChat/.build/checkouts/vapor.git-5492988889259800272/Sources/Vapor/CORS/CORSConfiguration.swift /Users/AleixDiaz/Desktop/VaporProject/LaSalleChat/.build/checkouts/vapor.git-5492988889259800272/Sources/Vapor/Routing/RouteCollection.swift /Users/AleixDiaz/Desktop/VaporProject/LaSalleChat/.build/checkouts/vapor.git-5492988889259800272/Sources/Vapor/Event/Subscription.swift /Users/AleixDiaz/Desktop/VaporProject/LaSalleChat/.build/checkouts/vapor.git-5492988889259800272/Sources/Vapor/Droplet/Droplet+Run.swift /Users/AleixDiaz/Desktop/VaporProject/LaSalleChat/.build/checkouts/vapor.git-5492988889259800272/Sources/Vapor/Mail/Mailgun.swift /Users/AleixDiaz/Desktop/VaporProject/LaSalleChat/.build/checkouts/vapor.git-5492988889259800272/Sources/Vapor/Provider/Config+Provider.swift /Users/AleixDiaz/Desktop/VaporProject/LaSalleChat/.build/checkouts/vapor.git-5492988889259800272/Sources/Vapor/Provider/Provider.swift /Users/AleixDiaz/Desktop/VaporProject/LaSalleChat/.build/checkouts/vapor.git-5492988889259800272/Sources/Vapor/Droplet/Droplet+Responder.swift /Users/AleixDiaz/Desktop/VaporProject/LaSalleChat/.build/checkouts/vapor.git-5492988889259800272/Sources/Vapor/File/FileManager.swift /Users/AleixDiaz/Desktop/VaporProject/LaSalleChat/.build/checkouts/vapor.git-5492988889259800272/Sources/Vapor/Log/ConsoleLogger.swift /Users/AleixDiaz/Desktop/VaporProject/LaSalleChat/.build/checkouts/vapor.git-5492988889259800272/Sources/Vapor/Cipher/Config+Cipher.swift /Users/AleixDiaz/Desktop/VaporProject/LaSalleChat/.build/checkouts/vapor.git-5492988889259800272/Sources/Vapor/Cipher/CryptoCipher.swift /Users/AleixDiaz/Desktop/VaporProject/LaSalleChat/.build/checkouts/vapor.git-5492988889259800272/Sources/Vapor/Hash/CryptoHasher.swift /Users/AleixDiaz/Desktop/VaporProject/LaSalleChat/.build/checkouts/vapor.git-5492988889259800272/Sources/Vapor/Hash/BCryptHasher.swift /Users/AleixDiaz/Desktop/VaporProject/LaSalleChat/.build/checkouts/vapor.git-5492988889259800272/Sources/Vapor/View/ViewRenderer.swift /Users/AleixDiaz/Desktop/VaporProject/LaSalleChat/.build/checkouts/vapor.git-5492988889259800272/Sources/Vapor/View/StaticViewRenderer.swift /Users/AleixDiaz/Desktop/VaporProject/LaSalleChat/.build/checkouts/vapor.git-5492988889259800272/Sources/Vapor/Engine/Server/EngineServer.swift /Users/AleixDiaz/Desktop/VaporProject/LaSalleChat/.build/checkouts/vapor.git-5492988889259800272/Sources/Vapor/Engine/SecurityLayer.swift /Users/AleixDiaz/Desktop/VaporProject/LaSalleChat/.build/checkouts/vapor.git-5492988889259800272/Sources/Vapor/Error/AbortError.swift /Users/AleixDiaz/Desktop/VaporProject/LaSalleChat/.build/checkouts/vapor.git-5492988889259800272/Sources/Vapor/Provider/Provider+Resources.swift /Users/AleixDiaz/Desktop/VaporProject/LaSalleChat/.build/checkouts/vapor.git-5492988889259800272/Sources/Vapor/Config/Directories.swift /Users/AleixDiaz/Desktop/VaporProject/LaSalleChat/.build/checkouts/vapor.git-5492988889259800272/Sources/Vapor/Utilities/Bytes.swift /Users/AleixDiaz/Desktop/VaporProject/LaSalleChat/.build/checkouts/vapor.git-5492988889259800272/Sources/Vapor/Utilities/InitProtocols.swift /Users/AleixDiaz/Desktop/VaporProject/LaSalleChat/.build/checkouts/vapor.git-5492988889259800272/Sources/Vapor/Sessions/Config+Sessions.swift /Users/AleixDiaz/Desktop/VaporProject/LaSalleChat/.build/checkouts/vapor.git-5492988889259800272/Sources/Vapor/Engine/Client/Responder+Helpers.swift /Users/AleixDiaz/Desktop/VaporProject/LaSalleChat/.build/checkouts/vapor.git-5492988889259800272/Sources/Vapor/WebSockets/WebSockets.swift /Users/AleixDiaz/Desktop/VaporProject/LaSalleChat/.build/checkouts/vapor.git-5492988889259800272/Sources/Vapor/Utilities/Exports.swift /Users/AleixDiaz/Desktop/VaporProject/LaSalleChat/.build/checkouts/vapor.git-5492988889259800272/Sources/Vapor/Droplet/Droplet.swift /Users/AleixDiaz/Desktop/VaporProject/LaSalleChat/.build/checkouts/vapor.git-5492988889259800272/Sources/Vapor/Engine/Client/EngineClient.swift /Users/AleixDiaz/Desktop/VaporProject/LaSalleChat/.build/checkouts/vapor.git-5492988889259800272/Sources/Vapor/Engine/Client/FoundationClient.swift /Users/AleixDiaz/Desktop/VaporProject/LaSalleChat/.build/checkouts/vapor.git-5492988889259800272/Sources/Vapor/Content/Response+Content.swift /Users/AleixDiaz/Desktop/VaporProject/LaSalleChat/.build/checkouts/vapor.git-5492988889259800272/Sources/Vapor/Content/Request+Content.swift /Users/AleixDiaz/Desktop/VaporProject/LaSalleChat/.build/checkouts/vapor.git-5492988889259800272/Sources/Vapor/Content/Content.swift /Users/AleixDiaz/Desktop/VaporProject/LaSalleChat/.build/checkouts/vapor.git-5492988889259800272/Sources/Vapor/Event/Event.swift /Users/AleixDiaz/Desktop/VaporProject/LaSalleChat/.build/checkouts/vapor.git-5492988889259800272/Sources/Vapor/HTTP/Accept.swift /Users/AleixDiaz/Desktop/VaporProject/LaSalleChat/.build/checkouts/vapor.git-5492988889259800272/Sources/Vapor/Multipart/Request+Multipart.swift /Users/AleixDiaz/Desktop/VaporProject/LaSalleChat/.build/checkouts/vapor.git-5492988889259800272/Sources/Vapor/Error/Abort.swift /Users/AleixDiaz/Desktop/VaporProject/LaSalleChat/.build/checkouts/vapor.git-5492988889259800272/Sources/Vapor/View/ViewRenderer+Request.swift /Users/AleixDiaz/Desktop/VaporProject/LaSalleChat/.build/checkouts/vapor.git-5492988889259800272/Sources/Vapor/View/Config+View.swift /Users/AleixDiaz/Desktop/VaporProject/LaSalleChat/.build/checkouts/vapor.git-5492988889259800272/Sources/Vapor/View/View.swift /Users/AleixDiaz/Desktop/VaporProject/LaSalleChat/.build/checkouts/vapor.git-5492988889259800272/Sources/Vapor/Error/ErrorView.swift /Users/AleixDiaz/Desktop/VaporProject/LaSalleChat/.build/checkouts/vapor.git-5492988889259800272/Sources/Vapor/Engine/Server/Config+ServerFactory.swift /Users/AleixDiaz/Desktop/VaporProject/LaSalleChat/.build/checkouts/vapor.git-5492988889259800272/Sources/Vapor/Engine/Server/ServerFactory.swift /Users/AleixDiaz/Desktop/VaporProject/LaSalleChat/.build/checkouts/vapor.git-5492988889259800272/Sources/Vapor/Engine/Client/Config+ClientFactory.swift /Users/AleixDiaz/Desktop/VaporProject/LaSalleChat/.build/checkouts/vapor.git-5492988889259800272/Sources/Vapor/Engine/Client/ClientFactory.swift /Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/lib/swift/macosx/x86_64/Dispatch.apinotesc /Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/lib/swift/macosx/x86_64/ObjectiveC.swiftmodule /Users/AleixDiaz/Desktop/VaporProject/LaSalleChat/.build/x86_64-apple-macosx10.10/debug/URI.swiftmodule /Users/AleixDiaz/Desktop/VaporProject/LaSalleChat/.build/x86_64-apple-macosx10.10/debug/JSON.swiftmodule /Users/AleixDiaz/Desktop/VaporProject/LaSalleChat/.build/x86_64-apple-macosx10.10/debug/SMTP.swiftmodule /Users/AleixDiaz/Desktop/VaporProject/LaSalleChat/.build/x86_64-apple-macosx10.10/debug/HTTP.swiftmodule /Users/AleixDiaz/Desktop/VaporProject/LaSalleChat/.build/x86_64-apple-macosx10.10/debug/TLS.swiftmodule /Users/AleixDiaz/Desktop/VaporProject/LaSalleChat/.build/x86_64-apple-macosx10.10/debug/FormData.swiftmodule /Users/AleixDiaz/Desktop/VaporProject/LaSalleChat/.build/x86_64-apple-macosx10.10/debug/libc.swiftmodule /Users/AleixDiaz/Desktop/VaporProject/LaSalleChat/.build/x86_64-apple-macosx10.10/debug/Node.swiftmodule /Users/AleixDiaz/Desktop/VaporProject/LaSalleChat/.build/x86_64-apple-macosx10.10/debug/Cache.swiftmodule /Users/AleixDiaz/Desktop/VaporProject/LaSalleChat/.build/x86_64-apple-macosx10.10/debug/PathIndexable.swiftmodule /Users/AleixDiaz/Desktop/VaporProject/LaSalleChat/.build/x86_64-apple-macosx10.10/debug/Console.swiftmodule /Users/AleixDiaz/Desktop/VaporProject/LaSalleChat/.build/x86_64-apple-macosx10.10/debug/Core.swiftmodule /Users/AleixDiaz/Desktop/VaporProject/LaSalleChat/.build/x86_64-apple-macosx10.10/debug/Debugging.swiftmodule /Users/AleixDiaz/Desktop/VaporProject/LaSalleChat/.build/x86_64-apple-macosx10.10/debug/Routing.swiftmodule /Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/lib/swift/macosx/x86_64/Dispatch.swiftmodule /Users/AleixDiaz/Desktop/VaporProject/LaSalleChat/.build/x86_64-apple-macosx10.10/debug/Random.swiftmodule /Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/lib/swift/macosx/x86_64/Darwin.swiftmodule /Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/lib/swift/macosx/x86_64/Foundation.swiftmodule /Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/lib/swift/macosx/x86_64/CoreFoundation.swiftmodule /Users/AleixDiaz/Desktop/VaporProject/LaSalleChat/.build/x86_64-apple-macosx10.10/debug/Crypto.swiftmodule /Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/lib/swift/macosx/x86_64/CoreGraphics.swiftmodule /Users/AleixDiaz/Desktop/VaporProject/LaSalleChat/.build/x86_64-apple-macosx10.10/debug/Branches.swiftmodule /Users/AleixDiaz/Desktop/VaporProject/LaSalleChat/.build/x86_64-apple-macosx10.10/debug/Cookies.swiftmodule /Users/AleixDiaz/Desktop/VaporProject/LaSalleChat/.build/x86_64-apple-macosx10.10/debug/Configs.swiftmodule /Users/AleixDiaz/Desktop/VaporProject/LaSalleChat/.build/x86_64-apple-macosx10.10/debug/Sessions.swiftmodule /Users/AleixDiaz/Desktop/VaporProject/LaSalleChat/.build/x86_64-apple-macosx10.10/debug/Sockets.swiftmodule /Users/AleixDiaz/Desktop/VaporProject/LaSalleChat/.build/x86_64-apple-macosx10.10/debug/WebSockets.swiftmodule /Users/AleixDiaz/Desktop/VaporProject/LaSalleChat/.build/x86_64-apple-macosx10.10/debug/Bits.swiftmodule /Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/lib/swift/macosx/x86_64/Swift.swiftmodule /Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/lib/swift/macosx/x86_64/IOKit.swiftmodule /Users/AleixDiaz/Desktop/VaporProject/LaSalleChat/.build/x86_64-apple-macosx10.10/debug/BCrypt.swiftmodule /Users/AleixDiaz/Desktop/VaporProject/LaSalleChat/.build/x86_64-apple-macosx10.10/debug/Multipart.swiftmodule /Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/lib/swift/macosx/x86_64/SwiftOnoneSupport.swiftmodule /Users/AleixDiaz/Desktop/VaporProject/LaSalleChat/.build/x86_64-apple-macosx10.10/debug/Transport.swiftmodule /Users/AleixDiaz/Desktop/VaporProject/LaSalleChat/.build/checkouts/engine.git-3311994267206676365/Sources/CHTTP/include/http_parser.h /Users/AleixDiaz/Desktop/VaporProject/LaSalleChat/.build/checkouts/ctls.git-9210868160426949823/module.modulemap /Users/AleixDiaz/Desktop/VaporProject/LaSalleChat/.build/x86_64-apple-macosx10.10/debug/CHTTP.build/module.modulemap /Users/AleixDiaz/Desktop/VaporProject/LaSalleChat/.build/x86_64-apple-macosx10.10/debug/CSQLite.build/module.modulemap /Applications/Xcode.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX10.13.sdk/usr/include/Darwin.apinotes
/Users/AleixDiaz/Desktop/VaporProject/LaSalleChat/.build/x86_64-apple-macosx10.10/debug/Vapor.build/Body+JSON~partial.swiftmodule : /Users/AleixDiaz/Desktop/VaporProject/LaSalleChat/.build/checkouts/vapor.git-5492988889259800272/Sources/Vapor/JSON/HTTP/Message+JSON.swift /Users/AleixDiaz/Desktop/VaporProject/LaSalleChat/.build/checkouts/vapor.git-5492988889259800272/Sources/Vapor/JSON/HTTP/Response+JSON.swift /Users/AleixDiaz/Desktop/VaporProject/LaSalleChat/.build/checkouts/vapor.git-5492988889259800272/Sources/Vapor/JSON/HTTP/Body+JSON.swift /Users/AleixDiaz/Desktop/VaporProject/LaSalleChat/.build/checkouts/vapor.git-5492988889259800272/Sources/Vapor/JSON/JSON.swift /Users/AleixDiaz/Desktop/VaporProject/LaSalleChat/.build/checkouts/vapor.git-5492988889259800272/Sources/Vapor/Multipart/Request+FormData.swift /Users/AleixDiaz/Desktop/VaporProject/LaSalleChat/.build/checkouts/vapor.git-5492988889259800272/Sources/Vapor/View/ViewData.swift /Users/AleixDiaz/Desktop/VaporProject/LaSalleChat/.build/checkouts/vapor.git-5492988889259800272/Sources/Vapor/Multipart/FormData+Polymorphic.swift /Users/AleixDiaz/Desktop/VaporProject/LaSalleChat/.build/checkouts/vapor.git-5492988889259800272/Sources/Vapor/FormURLEncoded/StructuredData+FormURLEncoded.swift /Users/AleixDiaz/Desktop/VaporProject/LaSalleChat/.build/checkouts/vapor.git-5492988889259800272/Sources/Vapor/FormURLEncoded/Request+FormURLEncoded.swift /Users/AleixDiaz/Desktop/VaporProject/LaSalleChat/.build/checkouts/vapor.git-5492988889259800272/Sources/Vapor/Commands/Config+Command.swift /Users/AleixDiaz/Desktop/VaporProject/LaSalleChat/.build/checkouts/vapor.git-5492988889259800272/Sources/Vapor/Log/Log+Convenience.swift /Users/AleixDiaz/Desktop/VaporProject/LaSalleChat/.build/checkouts/vapor.git-5492988889259800272/Sources/Vapor/Utilities/StringCharacterSequence.swift /Users/AleixDiaz/Desktop/VaporProject/LaSalleChat/.build/checkouts/vapor.git-5492988889259800272/Sources/Vapor/Routing/Resource.swift /Users/AleixDiaz/Desktop/VaporProject/LaSalleChat/.build/checkouts/vapor.git-5492988889259800272/Sources/Vapor/HTTP/HTTP+Node.swift /Users/AleixDiaz/Desktop/VaporProject/LaSalleChat/.build/checkouts/vapor.git-5492988889259800272/Sources/Vapor/HTTP/AcceptLanguage.swift /Users/AleixDiaz/Desktop/VaporProject/LaSalleChat/.build/checkouts/vapor.git-5492988889259800272/Sources/Vapor/Cache/Config+Cache.swift /Users/AleixDiaz/Desktop/VaporProject/LaSalleChat/.build/checkouts/vapor.git-5492988889259800272/Sources/Vapor/JSON/HTTP/Message+Codable.swift /Users/AleixDiaz/Desktop/VaporProject/LaSalleChat/.build/checkouts/vapor.git-5492988889259800272/Sources/Vapor/JSON/HTTP/Response+Codable.swift /Users/AleixDiaz/Desktop/VaporProject/LaSalleChat/.build/checkouts/vapor.git-5492988889259800272/Sources/Vapor/Config/Configurable.swift /Users/AleixDiaz/Desktop/VaporProject/LaSalleChat/.build/checkouts/vapor.git-5492988889259800272/Sources/Vapor/JSON/JSONRepresentable.swift /Users/AleixDiaz/Desktop/VaporProject/LaSalleChat/.build/checkouts/vapor.git-5492988889259800272/Sources/Vapor/Utilities/StringInitializable.swift /Users/AleixDiaz/Desktop/VaporProject/LaSalleChat/.build/checkouts/vapor.git-5492988889259800272/Sources/Vapor/HTTP/RequestInitializable.swift /Users/AleixDiaz/Desktop/VaporProject/LaSalleChat/.build/checkouts/vapor.git-5492988889259800272/Sources/Vapor/Commands/Config+Console.swift /Users/AleixDiaz/Desktop/VaporProject/LaSalleChat/.build/checkouts/vapor.git-5492988889259800272/Sources/Vapor/Commands/Vapor+Console.swift /Users/AleixDiaz/Desktop/VaporProject/LaSalleChat/.build/checkouts/vapor.git-5492988889259800272/Sources/Vapor/Content/MediaType.swift /Users/AleixDiaz/Desktop/VaporProject/LaSalleChat/.build/checkouts/vapor.git-5492988889259800272/Sources/Vapor/Middleware/Config+Middleware.swift /Users/AleixDiaz/Desktop/VaporProject/LaSalleChat/.build/checkouts/vapor.git-5492988889259800272/Sources/Vapor/CORS/CORSMiddleware.swift /Users/AleixDiaz/Desktop/VaporProject/LaSalleChat/.build/checkouts/vapor.git-5492988889259800272/Sources/Vapor/File/FileMiddleware.swift /Users/AleixDiaz/Desktop/VaporProject/LaSalleChat/.build/checkouts/vapor.git-5492988889259800272/Sources/Vapor/Date/DateMiddleware.swift /Users/AleixDiaz/Desktop/VaporProject/LaSalleChat/.build/checkouts/vapor.git-5492988889259800272/Sources/Vapor/Error/ErrorMiddleware.swift /Users/AleixDiaz/Desktop/VaporProject/LaSalleChat/.build/checkouts/vapor.git-5492988889259800272/Sources/Vapor/File/File+Response.swift /Users/AleixDiaz/Desktop/VaporProject/LaSalleChat/.build/checkouts/vapor.git-5492988889259800272/Sources/Vapor/Config/Resolve.swift /Users/AleixDiaz/Desktop/VaporProject/LaSalleChat/.build/checkouts/vapor.git-5492988889259800272/Sources/Vapor/Serve/Serve.swift /Users/AleixDiaz/Desktop/VaporProject/LaSalleChat/.build/checkouts/vapor.git-5492988889259800272/Sources/Vapor/Commands/DumpConfig.swift /Users/AleixDiaz/Desktop/VaporProject/LaSalleChat/.build/checkouts/vapor.git-5492988889259800272/Sources/Vapor/Serve/Config+ServerConfig.swift /Users/AleixDiaz/Desktop/VaporProject/LaSalleChat/.build/checkouts/vapor.git-5492988889259800272/Sources/Vapor/Serve/ServerConfig.swift /Users/AleixDiaz/Desktop/VaporProject/LaSalleChat/.build/checkouts/vapor.git-5492988889259800272/Sources/Vapor/Cipher/CryptoEncoding.swift /Users/AleixDiaz/Desktop/VaporProject/LaSalleChat/.build/checkouts/vapor.git-5492988889259800272/Sources/Vapor/Middleware/Chaining.swift /Users/AleixDiaz/Desktop/VaporProject/LaSalleChat/.build/checkouts/vapor.git-5492988889259800272/Sources/Vapor/Routing/Droplet+Routing.swift /Users/AleixDiaz/Desktop/VaporProject/LaSalleChat/.build/checkouts/vapor.git-5492988889259800272/Sources/Vapor/Log/Config+Log.swift /Users/AleixDiaz/Desktop/VaporProject/LaSalleChat/.build/checkouts/vapor.git-5492988889259800272/Sources/Vapor/Routing/RoutesLog.swift /Users/AleixDiaz/Desktop/VaporProject/LaSalleChat/.build/checkouts/vapor.git-5492988889259800272/Sources/Vapor/Hash/Config+Hash.swift /Users/AleixDiaz/Desktop/VaporProject/LaSalleChat/.build/checkouts/vapor.git-5492988889259800272/Sources/Vapor/Log/LogLevel.swift /Users/AleixDiaz/Desktop/VaporProject/LaSalleChat/.build/checkouts/vapor.git-5492988889259800272/Sources/Vapor/Mail/Config+Mail.swift /Users/AleixDiaz/Desktop/VaporProject/LaSalleChat/.build/checkouts/vapor.git-5492988889259800272/Sources/Vapor/Mail/Mail.swift /Users/AleixDiaz/Desktop/VaporProject/LaSalleChat/.build/checkouts/vapor.git-5492988889259800272/Sources/Vapor/Provider/ProviderInstall.swift /Users/AleixDiaz/Desktop/VaporProject/LaSalleChat/.build/checkouts/vapor.git-5492988889259800272/Sources/Vapor/Log/LogProtocol.swift /Users/AleixDiaz/Desktop/VaporProject/LaSalleChat/.build/checkouts/vapor.git-5492988889259800272/Sources/Vapor/Hash/HashProtocol.swift /Users/AleixDiaz/Desktop/VaporProject/LaSalleChat/.build/checkouts/vapor.git-5492988889259800272/Sources/Vapor/Cipher/CipherProtocol.swift /Users/AleixDiaz/Desktop/VaporProject/LaSalleChat/.build/checkouts/vapor.git-5492988889259800272/Sources/Vapor/Engine/Server/ServerProtocol.swift /Users/AleixDiaz/Desktop/VaporProject/LaSalleChat/.build/checkouts/vapor.git-5492988889259800272/Sources/Vapor/Engine/Client/ClientProtocol.swift /Users/AleixDiaz/Desktop/VaporProject/LaSalleChat/.build/checkouts/vapor.git-5492988889259800272/Sources/Vapor/Engine/Server/ServerFactoryProtocol.swift /Users/AleixDiaz/Desktop/VaporProject/LaSalleChat/.build/checkouts/vapor.git-5492988889259800272/Sources/Vapor/Engine/Client/ClientFactoryProtocol.swift /Users/AleixDiaz/Desktop/VaporProject/LaSalleChat/.build/checkouts/vapor.git-5492988889259800272/Sources/Vapor/Hash/Int+Random.swift /Users/AleixDiaz/Desktop/VaporProject/LaSalleChat/.build/checkouts/vapor.git-5492988889259800272/Sources/Vapor/Commands/Version.swift /Users/AleixDiaz/Desktop/VaporProject/LaSalleChat/.build/checkouts/vapor.git-5492988889259800272/Sources/Vapor/CORS/CORSConfiguration.swift /Users/AleixDiaz/Desktop/VaporProject/LaSalleChat/.build/checkouts/vapor.git-5492988889259800272/Sources/Vapor/Routing/RouteCollection.swift /Users/AleixDiaz/Desktop/VaporProject/LaSalleChat/.build/checkouts/vapor.git-5492988889259800272/Sources/Vapor/Event/Subscription.swift /Users/AleixDiaz/Desktop/VaporProject/LaSalleChat/.build/checkouts/vapor.git-5492988889259800272/Sources/Vapor/Droplet/Droplet+Run.swift /Users/AleixDiaz/Desktop/VaporProject/LaSalleChat/.build/checkouts/vapor.git-5492988889259800272/Sources/Vapor/Mail/Mailgun.swift /Users/AleixDiaz/Desktop/VaporProject/LaSalleChat/.build/checkouts/vapor.git-5492988889259800272/Sources/Vapor/Provider/Config+Provider.swift /Users/AleixDiaz/Desktop/VaporProject/LaSalleChat/.build/checkouts/vapor.git-5492988889259800272/Sources/Vapor/Provider/Provider.swift /Users/AleixDiaz/Desktop/VaporProject/LaSalleChat/.build/checkouts/vapor.git-5492988889259800272/Sources/Vapor/Droplet/Droplet+Responder.swift /Users/AleixDiaz/Desktop/VaporProject/LaSalleChat/.build/checkouts/vapor.git-5492988889259800272/Sources/Vapor/File/FileManager.swift /Users/AleixDiaz/Desktop/VaporProject/LaSalleChat/.build/checkouts/vapor.git-5492988889259800272/Sources/Vapor/Log/ConsoleLogger.swift /Users/AleixDiaz/Desktop/VaporProject/LaSalleChat/.build/checkouts/vapor.git-5492988889259800272/Sources/Vapor/Cipher/Config+Cipher.swift /Users/AleixDiaz/Desktop/VaporProject/LaSalleChat/.build/checkouts/vapor.git-5492988889259800272/Sources/Vapor/Cipher/CryptoCipher.swift /Users/AleixDiaz/Desktop/VaporProject/LaSalleChat/.build/checkouts/vapor.git-5492988889259800272/Sources/Vapor/Hash/CryptoHasher.swift /Users/AleixDiaz/Desktop/VaporProject/LaSalleChat/.build/checkouts/vapor.git-5492988889259800272/Sources/Vapor/Hash/BCryptHasher.swift /Users/AleixDiaz/Desktop/VaporProject/LaSalleChat/.build/checkouts/vapor.git-5492988889259800272/Sources/Vapor/View/ViewRenderer.swift /Users/AleixDiaz/Desktop/VaporProject/LaSalleChat/.build/checkouts/vapor.git-5492988889259800272/Sources/Vapor/View/StaticViewRenderer.swift /Users/AleixDiaz/Desktop/VaporProject/LaSalleChat/.build/checkouts/vapor.git-5492988889259800272/Sources/Vapor/Engine/Server/EngineServer.swift /Users/AleixDiaz/Desktop/VaporProject/LaSalleChat/.build/checkouts/vapor.git-5492988889259800272/Sources/Vapor/Engine/SecurityLayer.swift /Users/AleixDiaz/Desktop/VaporProject/LaSalleChat/.build/checkouts/vapor.git-5492988889259800272/Sources/Vapor/Error/AbortError.swift /Users/AleixDiaz/Desktop/VaporProject/LaSalleChat/.build/checkouts/vapor.git-5492988889259800272/Sources/Vapor/Provider/Provider+Resources.swift /Users/AleixDiaz/Desktop/VaporProject/LaSalleChat/.build/checkouts/vapor.git-5492988889259800272/Sources/Vapor/Config/Directories.swift /Users/AleixDiaz/Desktop/VaporProject/LaSalleChat/.build/checkouts/vapor.git-5492988889259800272/Sources/Vapor/Utilities/Bytes.swift /Users/AleixDiaz/Desktop/VaporProject/LaSalleChat/.build/checkouts/vapor.git-5492988889259800272/Sources/Vapor/Utilities/InitProtocols.swift /Users/AleixDiaz/Desktop/VaporProject/LaSalleChat/.build/checkouts/vapor.git-5492988889259800272/Sources/Vapor/Sessions/Config+Sessions.swift /Users/AleixDiaz/Desktop/VaporProject/LaSalleChat/.build/checkouts/vapor.git-5492988889259800272/Sources/Vapor/Engine/Client/Responder+Helpers.swift /Users/AleixDiaz/Desktop/VaporProject/LaSalleChat/.build/checkouts/vapor.git-5492988889259800272/Sources/Vapor/WebSockets/WebSockets.swift /Users/AleixDiaz/Desktop/VaporProject/LaSalleChat/.build/checkouts/vapor.git-5492988889259800272/Sources/Vapor/Utilities/Exports.swift /Users/AleixDiaz/Desktop/VaporProject/LaSalleChat/.build/checkouts/vapor.git-5492988889259800272/Sources/Vapor/Droplet/Droplet.swift /Users/AleixDiaz/Desktop/VaporProject/LaSalleChat/.build/checkouts/vapor.git-5492988889259800272/Sources/Vapor/Engine/Client/EngineClient.swift /Users/AleixDiaz/Desktop/VaporProject/LaSalleChat/.build/checkouts/vapor.git-5492988889259800272/Sources/Vapor/Engine/Client/FoundationClient.swift /Users/AleixDiaz/Desktop/VaporProject/LaSalleChat/.build/checkouts/vapor.git-5492988889259800272/Sources/Vapor/Content/Response+Content.swift /Users/AleixDiaz/Desktop/VaporProject/LaSalleChat/.build/checkouts/vapor.git-5492988889259800272/Sources/Vapor/Content/Request+Content.swift /Users/AleixDiaz/Desktop/VaporProject/LaSalleChat/.build/checkouts/vapor.git-5492988889259800272/Sources/Vapor/Content/Content.swift /Users/AleixDiaz/Desktop/VaporProject/LaSalleChat/.build/checkouts/vapor.git-5492988889259800272/Sources/Vapor/Event/Event.swift /Users/AleixDiaz/Desktop/VaporProject/LaSalleChat/.build/checkouts/vapor.git-5492988889259800272/Sources/Vapor/HTTP/Accept.swift /Users/AleixDiaz/Desktop/VaporProject/LaSalleChat/.build/checkouts/vapor.git-5492988889259800272/Sources/Vapor/Multipart/Request+Multipart.swift /Users/AleixDiaz/Desktop/VaporProject/LaSalleChat/.build/checkouts/vapor.git-5492988889259800272/Sources/Vapor/Error/Abort.swift /Users/AleixDiaz/Desktop/VaporProject/LaSalleChat/.build/checkouts/vapor.git-5492988889259800272/Sources/Vapor/View/ViewRenderer+Request.swift /Users/AleixDiaz/Desktop/VaporProject/LaSalleChat/.build/checkouts/vapor.git-5492988889259800272/Sources/Vapor/View/Config+View.swift /Users/AleixDiaz/Desktop/VaporProject/LaSalleChat/.build/checkouts/vapor.git-5492988889259800272/Sources/Vapor/View/View.swift /Users/AleixDiaz/Desktop/VaporProject/LaSalleChat/.build/checkouts/vapor.git-5492988889259800272/Sources/Vapor/Error/ErrorView.swift /Users/AleixDiaz/Desktop/VaporProject/LaSalleChat/.build/checkouts/vapor.git-5492988889259800272/Sources/Vapor/Engine/Server/Config+ServerFactory.swift /Users/AleixDiaz/Desktop/VaporProject/LaSalleChat/.build/checkouts/vapor.git-5492988889259800272/Sources/Vapor/Engine/Server/ServerFactory.swift /Users/AleixDiaz/Desktop/VaporProject/LaSalleChat/.build/checkouts/vapor.git-5492988889259800272/Sources/Vapor/Engine/Client/Config+ClientFactory.swift /Users/AleixDiaz/Desktop/VaporProject/LaSalleChat/.build/checkouts/vapor.git-5492988889259800272/Sources/Vapor/Engine/Client/ClientFactory.swift /Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/lib/swift/macosx/x86_64/Dispatch.apinotesc /Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/lib/swift/macosx/x86_64/ObjectiveC.swiftmodule /Users/AleixDiaz/Desktop/VaporProject/LaSalleChat/.build/x86_64-apple-macosx10.10/debug/URI.swiftmodule /Users/AleixDiaz/Desktop/VaporProject/LaSalleChat/.build/x86_64-apple-macosx10.10/debug/JSON.swiftmodule /Users/AleixDiaz/Desktop/VaporProject/LaSalleChat/.build/x86_64-apple-macosx10.10/debug/SMTP.swiftmodule /Users/AleixDiaz/Desktop/VaporProject/LaSalleChat/.build/x86_64-apple-macosx10.10/debug/HTTP.swiftmodule /Users/AleixDiaz/Desktop/VaporProject/LaSalleChat/.build/x86_64-apple-macosx10.10/debug/TLS.swiftmodule /Users/AleixDiaz/Desktop/VaporProject/LaSalleChat/.build/x86_64-apple-macosx10.10/debug/FormData.swiftmodule /Users/AleixDiaz/Desktop/VaporProject/LaSalleChat/.build/x86_64-apple-macosx10.10/debug/libc.swiftmodule /Users/AleixDiaz/Desktop/VaporProject/LaSalleChat/.build/x86_64-apple-macosx10.10/debug/Node.swiftmodule /Users/AleixDiaz/Desktop/VaporProject/LaSalleChat/.build/x86_64-apple-macosx10.10/debug/Cache.swiftmodule /Users/AleixDiaz/Desktop/VaporProject/LaSalleChat/.build/x86_64-apple-macosx10.10/debug/PathIndexable.swiftmodule /Users/AleixDiaz/Desktop/VaporProject/LaSalleChat/.build/x86_64-apple-macosx10.10/debug/Console.swiftmodule /Users/AleixDiaz/Desktop/VaporProject/LaSalleChat/.build/x86_64-apple-macosx10.10/debug/Core.swiftmodule /Users/AleixDiaz/Desktop/VaporProject/LaSalleChat/.build/x86_64-apple-macosx10.10/debug/Debugging.swiftmodule /Users/AleixDiaz/Desktop/VaporProject/LaSalleChat/.build/x86_64-apple-macosx10.10/debug/Routing.swiftmodule /Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/lib/swift/macosx/x86_64/Dispatch.swiftmodule /Users/AleixDiaz/Desktop/VaporProject/LaSalleChat/.build/x86_64-apple-macosx10.10/debug/Random.swiftmodule /Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/lib/swift/macosx/x86_64/Darwin.swiftmodule /Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/lib/swift/macosx/x86_64/Foundation.swiftmodule /Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/lib/swift/macosx/x86_64/CoreFoundation.swiftmodule /Users/AleixDiaz/Desktop/VaporProject/LaSalleChat/.build/x86_64-apple-macosx10.10/debug/Crypto.swiftmodule /Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/lib/swift/macosx/x86_64/CoreGraphics.swiftmodule /Users/AleixDiaz/Desktop/VaporProject/LaSalleChat/.build/x86_64-apple-macosx10.10/debug/Branches.swiftmodule /Users/AleixDiaz/Desktop/VaporProject/LaSalleChat/.build/x86_64-apple-macosx10.10/debug/Cookies.swiftmodule /Users/AleixDiaz/Desktop/VaporProject/LaSalleChat/.build/x86_64-apple-macosx10.10/debug/Configs.swiftmodule /Users/AleixDiaz/Desktop/VaporProject/LaSalleChat/.build/x86_64-apple-macosx10.10/debug/Sessions.swiftmodule /Users/AleixDiaz/Desktop/VaporProject/LaSalleChat/.build/x86_64-apple-macosx10.10/debug/Sockets.swiftmodule /Users/AleixDiaz/Desktop/VaporProject/LaSalleChat/.build/x86_64-apple-macosx10.10/debug/WebSockets.swiftmodule /Users/AleixDiaz/Desktop/VaporProject/LaSalleChat/.build/x86_64-apple-macosx10.10/debug/Bits.swiftmodule /Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/lib/swift/macosx/x86_64/Swift.swiftmodule /Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/lib/swift/macosx/x86_64/IOKit.swiftmodule /Users/AleixDiaz/Desktop/VaporProject/LaSalleChat/.build/x86_64-apple-macosx10.10/debug/BCrypt.swiftmodule /Users/AleixDiaz/Desktop/VaporProject/LaSalleChat/.build/x86_64-apple-macosx10.10/debug/Multipart.swiftmodule /Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/lib/swift/macosx/x86_64/SwiftOnoneSupport.swiftmodule /Users/AleixDiaz/Desktop/VaporProject/LaSalleChat/.build/x86_64-apple-macosx10.10/debug/Transport.swiftmodule /Users/AleixDiaz/Desktop/VaporProject/LaSalleChat/.build/checkouts/engine.git-3311994267206676365/Sources/CHTTP/include/http_parser.h /Users/AleixDiaz/Desktop/VaporProject/LaSalleChat/.build/checkouts/ctls.git-9210868160426949823/module.modulemap /Users/AleixDiaz/Desktop/VaporProject/LaSalleChat/.build/x86_64-apple-macosx10.10/debug/CHTTP.build/module.modulemap /Users/AleixDiaz/Desktop/VaporProject/LaSalleChat/.build/x86_64-apple-macosx10.10/debug/CSQLite.build/module.modulemap /Applications/Xcode.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX10.13.sdk/usr/include/Darwin.apinotes
/Users/AleixDiaz/Desktop/VaporProject/LaSalleChat/.build/x86_64-apple-macosx10.10/debug/Vapor.build/Body+JSON~partial.swiftdoc : /Users/AleixDiaz/Desktop/VaporProject/LaSalleChat/.build/checkouts/vapor.git-5492988889259800272/Sources/Vapor/JSON/HTTP/Message+JSON.swift /Users/AleixDiaz/Desktop/VaporProject/LaSalleChat/.build/checkouts/vapor.git-5492988889259800272/Sources/Vapor/JSON/HTTP/Response+JSON.swift /Users/AleixDiaz/Desktop/VaporProject/LaSalleChat/.build/checkouts/vapor.git-5492988889259800272/Sources/Vapor/JSON/HTTP/Body+JSON.swift /Users/AleixDiaz/Desktop/VaporProject/LaSalleChat/.build/checkouts/vapor.git-5492988889259800272/Sources/Vapor/JSON/JSON.swift /Users/AleixDiaz/Desktop/VaporProject/LaSalleChat/.build/checkouts/vapor.git-5492988889259800272/Sources/Vapor/Multipart/Request+FormData.swift /Users/AleixDiaz/Desktop/VaporProject/LaSalleChat/.build/checkouts/vapor.git-5492988889259800272/Sources/Vapor/View/ViewData.swift /Users/AleixDiaz/Desktop/VaporProject/LaSalleChat/.build/checkouts/vapor.git-5492988889259800272/Sources/Vapor/Multipart/FormData+Polymorphic.swift /Users/AleixDiaz/Desktop/VaporProject/LaSalleChat/.build/checkouts/vapor.git-5492988889259800272/Sources/Vapor/FormURLEncoded/StructuredData+FormURLEncoded.swift /Users/AleixDiaz/Desktop/VaporProject/LaSalleChat/.build/checkouts/vapor.git-5492988889259800272/Sources/Vapor/FormURLEncoded/Request+FormURLEncoded.swift /Users/AleixDiaz/Desktop/VaporProject/LaSalleChat/.build/checkouts/vapor.git-5492988889259800272/Sources/Vapor/Commands/Config+Command.swift /Users/AleixDiaz/Desktop/VaporProject/LaSalleChat/.build/checkouts/vapor.git-5492988889259800272/Sources/Vapor/Log/Log+Convenience.swift /Users/AleixDiaz/Desktop/VaporProject/LaSalleChat/.build/checkouts/vapor.git-5492988889259800272/Sources/Vapor/Utilities/StringCharacterSequence.swift /Users/AleixDiaz/Desktop/VaporProject/LaSalleChat/.build/checkouts/vapor.git-5492988889259800272/Sources/Vapor/Routing/Resource.swift /Users/AleixDiaz/Desktop/VaporProject/LaSalleChat/.build/checkouts/vapor.git-5492988889259800272/Sources/Vapor/HTTP/HTTP+Node.swift /Users/AleixDiaz/Desktop/VaporProject/LaSalleChat/.build/checkouts/vapor.git-5492988889259800272/Sources/Vapor/HTTP/AcceptLanguage.swift /Users/AleixDiaz/Desktop/VaporProject/LaSalleChat/.build/checkouts/vapor.git-5492988889259800272/Sources/Vapor/Cache/Config+Cache.swift /Users/AleixDiaz/Desktop/VaporProject/LaSalleChat/.build/checkouts/vapor.git-5492988889259800272/Sources/Vapor/JSON/HTTP/Message+Codable.swift /Users/AleixDiaz/Desktop/VaporProject/LaSalleChat/.build/checkouts/vapor.git-5492988889259800272/Sources/Vapor/JSON/HTTP/Response+Codable.swift /Users/AleixDiaz/Desktop/VaporProject/LaSalleChat/.build/checkouts/vapor.git-5492988889259800272/Sources/Vapor/Config/Configurable.swift /Users/AleixDiaz/Desktop/VaporProject/LaSalleChat/.build/checkouts/vapor.git-5492988889259800272/Sources/Vapor/JSON/JSONRepresentable.swift /Users/AleixDiaz/Desktop/VaporProject/LaSalleChat/.build/checkouts/vapor.git-5492988889259800272/Sources/Vapor/Utilities/StringInitializable.swift /Users/AleixDiaz/Desktop/VaporProject/LaSalleChat/.build/checkouts/vapor.git-5492988889259800272/Sources/Vapor/HTTP/RequestInitializable.swift /Users/AleixDiaz/Desktop/VaporProject/LaSalleChat/.build/checkouts/vapor.git-5492988889259800272/Sources/Vapor/Commands/Config+Console.swift /Users/AleixDiaz/Desktop/VaporProject/LaSalleChat/.build/checkouts/vapor.git-5492988889259800272/Sources/Vapor/Commands/Vapor+Console.swift /Users/AleixDiaz/Desktop/VaporProject/LaSalleChat/.build/checkouts/vapor.git-5492988889259800272/Sources/Vapor/Content/MediaType.swift /Users/AleixDiaz/Desktop/VaporProject/LaSalleChat/.build/checkouts/vapor.git-5492988889259800272/Sources/Vapor/Middleware/Config+Middleware.swift /Users/AleixDiaz/Desktop/VaporProject/LaSalleChat/.build/checkouts/vapor.git-5492988889259800272/Sources/Vapor/CORS/CORSMiddleware.swift /Users/AleixDiaz/Desktop/VaporProject/LaSalleChat/.build/checkouts/vapor.git-5492988889259800272/Sources/Vapor/File/FileMiddleware.swift /Users/AleixDiaz/Desktop/VaporProject/LaSalleChat/.build/checkouts/vapor.git-5492988889259800272/Sources/Vapor/Date/DateMiddleware.swift /Users/AleixDiaz/Desktop/VaporProject/LaSalleChat/.build/checkouts/vapor.git-5492988889259800272/Sources/Vapor/Error/ErrorMiddleware.swift /Users/AleixDiaz/Desktop/VaporProject/LaSalleChat/.build/checkouts/vapor.git-5492988889259800272/Sources/Vapor/File/File+Response.swift /Users/AleixDiaz/Desktop/VaporProject/LaSalleChat/.build/checkouts/vapor.git-5492988889259800272/Sources/Vapor/Config/Resolve.swift /Users/AleixDiaz/Desktop/VaporProject/LaSalleChat/.build/checkouts/vapor.git-5492988889259800272/Sources/Vapor/Serve/Serve.swift /Users/AleixDiaz/Desktop/VaporProject/LaSalleChat/.build/checkouts/vapor.git-5492988889259800272/Sources/Vapor/Commands/DumpConfig.swift /Users/AleixDiaz/Desktop/VaporProject/LaSalleChat/.build/checkouts/vapor.git-5492988889259800272/Sources/Vapor/Serve/Config+ServerConfig.swift /Users/AleixDiaz/Desktop/VaporProject/LaSalleChat/.build/checkouts/vapor.git-5492988889259800272/Sources/Vapor/Serve/ServerConfig.swift /Users/AleixDiaz/Desktop/VaporProject/LaSalleChat/.build/checkouts/vapor.git-5492988889259800272/Sources/Vapor/Cipher/CryptoEncoding.swift /Users/AleixDiaz/Desktop/VaporProject/LaSalleChat/.build/checkouts/vapor.git-5492988889259800272/Sources/Vapor/Middleware/Chaining.swift /Users/AleixDiaz/Desktop/VaporProject/LaSalleChat/.build/checkouts/vapor.git-5492988889259800272/Sources/Vapor/Routing/Droplet+Routing.swift /Users/AleixDiaz/Desktop/VaporProject/LaSalleChat/.build/checkouts/vapor.git-5492988889259800272/Sources/Vapor/Log/Config+Log.swift /Users/AleixDiaz/Desktop/VaporProject/LaSalleChat/.build/checkouts/vapor.git-5492988889259800272/Sources/Vapor/Routing/RoutesLog.swift /Users/AleixDiaz/Desktop/VaporProject/LaSalleChat/.build/checkouts/vapor.git-5492988889259800272/Sources/Vapor/Hash/Config+Hash.swift /Users/AleixDiaz/Desktop/VaporProject/LaSalleChat/.build/checkouts/vapor.git-5492988889259800272/Sources/Vapor/Log/LogLevel.swift /Users/AleixDiaz/Desktop/VaporProject/LaSalleChat/.build/checkouts/vapor.git-5492988889259800272/Sources/Vapor/Mail/Config+Mail.swift /Users/AleixDiaz/Desktop/VaporProject/LaSalleChat/.build/checkouts/vapor.git-5492988889259800272/Sources/Vapor/Mail/Mail.swift /Users/AleixDiaz/Desktop/VaporProject/LaSalleChat/.build/checkouts/vapor.git-5492988889259800272/Sources/Vapor/Provider/ProviderInstall.swift /Users/AleixDiaz/Desktop/VaporProject/LaSalleChat/.build/checkouts/vapor.git-5492988889259800272/Sources/Vapor/Log/LogProtocol.swift /Users/AleixDiaz/Desktop/VaporProject/LaSalleChat/.build/checkouts/vapor.git-5492988889259800272/Sources/Vapor/Hash/HashProtocol.swift /Users/AleixDiaz/Desktop/VaporProject/LaSalleChat/.build/checkouts/vapor.git-5492988889259800272/Sources/Vapor/Cipher/CipherProtocol.swift /Users/AleixDiaz/Desktop/VaporProject/LaSalleChat/.build/checkouts/vapor.git-5492988889259800272/Sources/Vapor/Engine/Server/ServerProtocol.swift /Users/AleixDiaz/Desktop/VaporProject/LaSalleChat/.build/checkouts/vapor.git-5492988889259800272/Sources/Vapor/Engine/Client/ClientProtocol.swift /Users/AleixDiaz/Desktop/VaporProject/LaSalleChat/.build/checkouts/vapor.git-5492988889259800272/Sources/Vapor/Engine/Server/ServerFactoryProtocol.swift /Users/AleixDiaz/Desktop/VaporProject/LaSalleChat/.build/checkouts/vapor.git-5492988889259800272/Sources/Vapor/Engine/Client/ClientFactoryProtocol.swift /Users/AleixDiaz/Desktop/VaporProject/LaSalleChat/.build/checkouts/vapor.git-5492988889259800272/Sources/Vapor/Hash/Int+Random.swift /Users/AleixDiaz/Desktop/VaporProject/LaSalleChat/.build/checkouts/vapor.git-5492988889259800272/Sources/Vapor/Commands/Version.swift /Users/AleixDiaz/Desktop/VaporProject/LaSalleChat/.build/checkouts/vapor.git-5492988889259800272/Sources/Vapor/CORS/CORSConfiguration.swift /Users/AleixDiaz/Desktop/VaporProject/LaSalleChat/.build/checkouts/vapor.git-5492988889259800272/Sources/Vapor/Routing/RouteCollection.swift /Users/AleixDiaz/Desktop/VaporProject/LaSalleChat/.build/checkouts/vapor.git-5492988889259800272/Sources/Vapor/Event/Subscription.swift /Users/AleixDiaz/Desktop/VaporProject/LaSalleChat/.build/checkouts/vapor.git-5492988889259800272/Sources/Vapor/Droplet/Droplet+Run.swift /Users/AleixDiaz/Desktop/VaporProject/LaSalleChat/.build/checkouts/vapor.git-5492988889259800272/Sources/Vapor/Mail/Mailgun.swift /Users/AleixDiaz/Desktop/VaporProject/LaSalleChat/.build/checkouts/vapor.git-5492988889259800272/Sources/Vapor/Provider/Config+Provider.swift /Users/AleixDiaz/Desktop/VaporProject/LaSalleChat/.build/checkouts/vapor.git-5492988889259800272/Sources/Vapor/Provider/Provider.swift /Users/AleixDiaz/Desktop/VaporProject/LaSalleChat/.build/checkouts/vapor.git-5492988889259800272/Sources/Vapor/Droplet/Droplet+Responder.swift /Users/AleixDiaz/Desktop/VaporProject/LaSalleChat/.build/checkouts/vapor.git-5492988889259800272/Sources/Vapor/File/FileManager.swift /Users/AleixDiaz/Desktop/VaporProject/LaSalleChat/.build/checkouts/vapor.git-5492988889259800272/Sources/Vapor/Log/ConsoleLogger.swift /Users/AleixDiaz/Desktop/VaporProject/LaSalleChat/.build/checkouts/vapor.git-5492988889259800272/Sources/Vapor/Cipher/Config+Cipher.swift /Users/AleixDiaz/Desktop/VaporProject/LaSalleChat/.build/checkouts/vapor.git-5492988889259800272/Sources/Vapor/Cipher/CryptoCipher.swift /Users/AleixDiaz/Desktop/VaporProject/LaSalleChat/.build/checkouts/vapor.git-5492988889259800272/Sources/Vapor/Hash/CryptoHasher.swift /Users/AleixDiaz/Desktop/VaporProject/LaSalleChat/.build/checkouts/vapor.git-5492988889259800272/Sources/Vapor/Hash/BCryptHasher.swift /Users/AleixDiaz/Desktop/VaporProject/LaSalleChat/.build/checkouts/vapor.git-5492988889259800272/Sources/Vapor/View/ViewRenderer.swift /Users/AleixDiaz/Desktop/VaporProject/LaSalleChat/.build/checkouts/vapor.git-5492988889259800272/Sources/Vapor/View/StaticViewRenderer.swift /Users/AleixDiaz/Desktop/VaporProject/LaSalleChat/.build/checkouts/vapor.git-5492988889259800272/Sources/Vapor/Engine/Server/EngineServer.swift /Users/AleixDiaz/Desktop/VaporProject/LaSalleChat/.build/checkouts/vapor.git-5492988889259800272/Sources/Vapor/Engine/SecurityLayer.swift /Users/AleixDiaz/Desktop/VaporProject/LaSalleChat/.build/checkouts/vapor.git-5492988889259800272/Sources/Vapor/Error/AbortError.swift /Users/AleixDiaz/Desktop/VaporProject/LaSalleChat/.build/checkouts/vapor.git-5492988889259800272/Sources/Vapor/Provider/Provider+Resources.swift /Users/AleixDiaz/Desktop/VaporProject/LaSalleChat/.build/checkouts/vapor.git-5492988889259800272/Sources/Vapor/Config/Directories.swift /Users/AleixDiaz/Desktop/VaporProject/LaSalleChat/.build/checkouts/vapor.git-5492988889259800272/Sources/Vapor/Utilities/Bytes.swift /Users/AleixDiaz/Desktop/VaporProject/LaSalleChat/.build/checkouts/vapor.git-5492988889259800272/Sources/Vapor/Utilities/InitProtocols.swift /Users/AleixDiaz/Desktop/VaporProject/LaSalleChat/.build/checkouts/vapor.git-5492988889259800272/Sources/Vapor/Sessions/Config+Sessions.swift /Users/AleixDiaz/Desktop/VaporProject/LaSalleChat/.build/checkouts/vapor.git-5492988889259800272/Sources/Vapor/Engine/Client/Responder+Helpers.swift /Users/AleixDiaz/Desktop/VaporProject/LaSalleChat/.build/checkouts/vapor.git-5492988889259800272/Sources/Vapor/WebSockets/WebSockets.swift /Users/AleixDiaz/Desktop/VaporProject/LaSalleChat/.build/checkouts/vapor.git-5492988889259800272/Sources/Vapor/Utilities/Exports.swift /Users/AleixDiaz/Desktop/VaporProject/LaSalleChat/.build/checkouts/vapor.git-5492988889259800272/Sources/Vapor/Droplet/Droplet.swift /Users/AleixDiaz/Desktop/VaporProject/LaSalleChat/.build/checkouts/vapor.git-5492988889259800272/Sources/Vapor/Engine/Client/EngineClient.swift /Users/AleixDiaz/Desktop/VaporProject/LaSalleChat/.build/checkouts/vapor.git-5492988889259800272/Sources/Vapor/Engine/Client/FoundationClient.swift /Users/AleixDiaz/Desktop/VaporProject/LaSalleChat/.build/checkouts/vapor.git-5492988889259800272/Sources/Vapor/Content/Response+Content.swift /Users/AleixDiaz/Desktop/VaporProject/LaSalleChat/.build/checkouts/vapor.git-5492988889259800272/Sources/Vapor/Content/Request+Content.swift /Users/AleixDiaz/Desktop/VaporProject/LaSalleChat/.build/checkouts/vapor.git-5492988889259800272/Sources/Vapor/Content/Content.swift /Users/AleixDiaz/Desktop/VaporProject/LaSalleChat/.build/checkouts/vapor.git-5492988889259800272/Sources/Vapor/Event/Event.swift /Users/AleixDiaz/Desktop/VaporProject/LaSalleChat/.build/checkouts/vapor.git-5492988889259800272/Sources/Vapor/HTTP/Accept.swift /Users/AleixDiaz/Desktop/VaporProject/LaSalleChat/.build/checkouts/vapor.git-5492988889259800272/Sources/Vapor/Multipart/Request+Multipart.swift /Users/AleixDiaz/Desktop/VaporProject/LaSalleChat/.build/checkouts/vapor.git-5492988889259800272/Sources/Vapor/Error/Abort.swift /Users/AleixDiaz/Desktop/VaporProject/LaSalleChat/.build/checkouts/vapor.git-5492988889259800272/Sources/Vapor/View/ViewRenderer+Request.swift /Users/AleixDiaz/Desktop/VaporProject/LaSalleChat/.build/checkouts/vapor.git-5492988889259800272/Sources/Vapor/View/Config+View.swift /Users/AleixDiaz/Desktop/VaporProject/LaSalleChat/.build/checkouts/vapor.git-5492988889259800272/Sources/Vapor/View/View.swift /Users/AleixDiaz/Desktop/VaporProject/LaSalleChat/.build/checkouts/vapor.git-5492988889259800272/Sources/Vapor/Error/ErrorView.swift /Users/AleixDiaz/Desktop/VaporProject/LaSalleChat/.build/checkouts/vapor.git-5492988889259800272/Sources/Vapor/Engine/Server/Config+ServerFactory.swift /Users/AleixDiaz/Desktop/VaporProject/LaSalleChat/.build/checkouts/vapor.git-5492988889259800272/Sources/Vapor/Engine/Server/ServerFactory.swift /Users/AleixDiaz/Desktop/VaporProject/LaSalleChat/.build/checkouts/vapor.git-5492988889259800272/Sources/Vapor/Engine/Client/Config+ClientFactory.swift /Users/AleixDiaz/Desktop/VaporProject/LaSalleChat/.build/checkouts/vapor.git-5492988889259800272/Sources/Vapor/Engine/Client/ClientFactory.swift /Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/lib/swift/macosx/x86_64/Dispatch.apinotesc /Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/lib/swift/macosx/x86_64/ObjectiveC.swiftmodule /Users/AleixDiaz/Desktop/VaporProject/LaSalleChat/.build/x86_64-apple-macosx10.10/debug/URI.swiftmodule /Users/AleixDiaz/Desktop/VaporProject/LaSalleChat/.build/x86_64-apple-macosx10.10/debug/JSON.swiftmodule /Users/AleixDiaz/Desktop/VaporProject/LaSalleChat/.build/x86_64-apple-macosx10.10/debug/SMTP.swiftmodule /Users/AleixDiaz/Desktop/VaporProject/LaSalleChat/.build/x86_64-apple-macosx10.10/debug/HTTP.swiftmodule /Users/AleixDiaz/Desktop/VaporProject/LaSalleChat/.build/x86_64-apple-macosx10.10/debug/TLS.swiftmodule /Users/AleixDiaz/Desktop/VaporProject/LaSalleChat/.build/x86_64-apple-macosx10.10/debug/FormData.swiftmodule /Users/AleixDiaz/Desktop/VaporProject/LaSalleChat/.build/x86_64-apple-macosx10.10/debug/libc.swiftmodule /Users/AleixDiaz/Desktop/VaporProject/LaSalleChat/.build/x86_64-apple-macosx10.10/debug/Node.swiftmodule /Users/AleixDiaz/Desktop/VaporProject/LaSalleChat/.build/x86_64-apple-macosx10.10/debug/Cache.swiftmodule /Users/AleixDiaz/Desktop/VaporProject/LaSalleChat/.build/x86_64-apple-macosx10.10/debug/PathIndexable.swiftmodule /Users/AleixDiaz/Desktop/VaporProject/LaSalleChat/.build/x86_64-apple-macosx10.10/debug/Console.swiftmodule /Users/AleixDiaz/Desktop/VaporProject/LaSalleChat/.build/x86_64-apple-macosx10.10/debug/Core.swiftmodule /Users/AleixDiaz/Desktop/VaporProject/LaSalleChat/.build/x86_64-apple-macosx10.10/debug/Debugging.swiftmodule /Users/AleixDiaz/Desktop/VaporProject/LaSalleChat/.build/x86_64-apple-macosx10.10/debug/Routing.swiftmodule /Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/lib/swift/macosx/x86_64/Dispatch.swiftmodule /Users/AleixDiaz/Desktop/VaporProject/LaSalleChat/.build/x86_64-apple-macosx10.10/debug/Random.swiftmodule /Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/lib/swift/macosx/x86_64/Darwin.swiftmodule /Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/lib/swift/macosx/x86_64/Foundation.swiftmodule /Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/lib/swift/macosx/x86_64/CoreFoundation.swiftmodule /Users/AleixDiaz/Desktop/VaporProject/LaSalleChat/.build/x86_64-apple-macosx10.10/debug/Crypto.swiftmodule /Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/lib/swift/macosx/x86_64/CoreGraphics.swiftmodule /Users/AleixDiaz/Desktop/VaporProject/LaSalleChat/.build/x86_64-apple-macosx10.10/debug/Branches.swiftmodule /Users/AleixDiaz/Desktop/VaporProject/LaSalleChat/.build/x86_64-apple-macosx10.10/debug/Cookies.swiftmodule /Users/AleixDiaz/Desktop/VaporProject/LaSalleChat/.build/x86_64-apple-macosx10.10/debug/Configs.swiftmodule /Users/AleixDiaz/Desktop/VaporProject/LaSalleChat/.build/x86_64-apple-macosx10.10/debug/Sessions.swiftmodule /Users/AleixDiaz/Desktop/VaporProject/LaSalleChat/.build/x86_64-apple-macosx10.10/debug/Sockets.swiftmodule /Users/AleixDiaz/Desktop/VaporProject/LaSalleChat/.build/x86_64-apple-macosx10.10/debug/WebSockets.swiftmodule /Users/AleixDiaz/Desktop/VaporProject/LaSalleChat/.build/x86_64-apple-macosx10.10/debug/Bits.swiftmodule /Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/lib/swift/macosx/x86_64/Swift.swiftmodule /Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/lib/swift/macosx/x86_64/IOKit.swiftmodule /Users/AleixDiaz/Desktop/VaporProject/LaSalleChat/.build/x86_64-apple-macosx10.10/debug/BCrypt.swiftmodule /Users/AleixDiaz/Desktop/VaporProject/LaSalleChat/.build/x86_64-apple-macosx10.10/debug/Multipart.swiftmodule /Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/lib/swift/macosx/x86_64/SwiftOnoneSupport.swiftmodule /Users/AleixDiaz/Desktop/VaporProject/LaSalleChat/.build/x86_64-apple-macosx10.10/debug/Transport.swiftmodule /Users/AleixDiaz/Desktop/VaporProject/LaSalleChat/.build/checkouts/engine.git-3311994267206676365/Sources/CHTTP/include/http_parser.h /Users/AleixDiaz/Desktop/VaporProject/LaSalleChat/.build/checkouts/ctls.git-9210868160426949823/module.modulemap /Users/AleixDiaz/Desktop/VaporProject/LaSalleChat/.build/x86_64-apple-macosx10.10/debug/CHTTP.build/module.modulemap /Users/AleixDiaz/Desktop/VaporProject/LaSalleChat/.build/x86_64-apple-macosx10.10/debug/CSQLite.build/module.modulemap /Applications/Xcode.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX10.13.sdk/usr/include/Darwin.apinotes
| D |
import std.stdio, std.algorithm, std.conv, std.array, std.string, std.math, std.typecons, std.numeric, std.container, std.range;
void get(Args...)(ref Args args)
{
import std.traits, std.meta, std.typecons;
static if (Args.length == 1) {
alias Arg = Args[0];
static if (isArray!Arg) {
static if (isSomeChar!(ElementType!Arg)) {
args[0] = readln.chomp.to!Arg;
} else {
args[0] = readln.split.to!Arg;
}
} else static if (isTuple!Arg) {
auto input = readln.split;
static foreach (i; 0..Fields!Arg.length) {
args[0][i] = input[i].to!(Fields!Arg[i]);
}
} else {
args[0] = readln.chomp.to!Arg;
}
} else {
auto input = readln.split;
assert(input.length == Args.length);
static foreach (i; 0..Args.length) {
args[i] = input[i].to!(Args[i]);
}
}
}
void get_lines(Args...)(size_t N, ref Args args)
{
import std.traits, std.range;
static foreach (i; 0..Args.length) {
static assert(isArray!(Args[i]));
args[i].length = N;
}
foreach (i; 0..N) {
static if (Args.length == 1) {
get(args[0][i]);
} else {
auto input = readln.split;
static foreach (j; 0..Args.length) {
args[j][i] = input[j].to!(ElementType!(Args[j]));
}
}
}
}
void main()
{
int N, K; get(N, K);
int[string] wm;
foreach (_; 0..N) {
string S; get(S);
++wm[S];
}
alias W = Tuple!(string, "w", int, "c");
W[] ws;
foreach (k, v; wm) ws ~= W(k, v);
sort!"a.c > b.c"(ws);
--K;
if ((K == 0 || ws[K].c != ws[K-1].c) && (K == ws.length || ws[K].c != ws[K+1].c)) {
writeln(ws[K].w);
} else {
writeln("AMBIGUOUS");
}
} | D |
.hd st_profile "statement-level profile" 03/25/82
st_profile [ <count_file> ] <source_code_file>
.ds
'St_profile' is used to convert the profiling information generated
by a Ratfor program processed with the "-c" option into a readable
report.
The optional <count_file> argument is the name of a statement_level
profile data file generated by a profiled program; if omitted,
the default name of "_st_profile" is assumed.
The <source_code_file> argument is the name of the file containing
the Ratfor source code for the program being profiled.
.es
st_profile rp.r
st_profile guide_profile fmt.r
.fl
_st_profile is the default <count_file>.
.me
"Usage: st_profile ..." if no arguments given.
.br
"can't open" if files are inaccessible.
.bu
See Reference Manual entry for 'rp'.
.sp
Seems to leave out the last line of source code.
.sa
rp (1), profile (1), c$init (6), c$incr (6), c$end (6)
| D |
module UnrealScript.TribesGame.TrCamera_SpectatorBookmark;
import ScriptClasses;
import UnrealScript.Helpers;
import UnrealScript.Engine.CameraActor;
extern(C++) interface TrCamera_SpectatorBookmark : CameraActor
{
public extern(D):
private static __gshared ScriptClass mStaticClass;
@property final static ScriptClass StaticClass() { mixin(MGSCC("Class TribesGame.TrCamera_SpectatorBookmark")); }
private static __gshared TrCamera_SpectatorBookmark mDefaultProperties;
@property final static TrCamera_SpectatorBookmark DefaultProperties() { mixin(MGDPC("TrCamera_SpectatorBookmark", "TrCamera_SpectatorBookmark TribesGame.Default__TrCamera_SpectatorBookmark")); }
static struct Functions
{
private static __gshared
{
ScriptFunction mGetDescription;
ScriptFunction mGetSpectatorName;
}
public @property static final
{
ScriptFunction GetDescription() { mixin(MGF("mGetDescription", "Function TribesGame.TrCamera_SpectatorBookmark.GetDescription")); }
ScriptFunction GetSpectatorName() { mixin(MGF("mGetSpectatorName", "Function TribesGame.TrCamera_SpectatorBookmark.GetSpectatorName")); }
}
}
enum ESpectatorBookmark : ubyte
{
Bookmark_BEBase = 0,
Bookmark_DSBase = 1,
Bookmark_CTFBEGeneratorRoom = 2,
Bookmark_CTFDSGeneratorRoom = 3,
Bookmark_CTFBEMidfield = 4,
Bookmark_CTFDSMidfield = 5,
Bookmark_CTFMapOverhead = 6,
Bookmark_CTFBEVehiclePad = 7,
Bookmark_CTFDSVehiclePad = 8,
Bookmark_CTFBESpawn = 9,
Bookmark_CTFDSSpawn = 10,
Bookmark_CTFBESensor = 11,
Bookmark_CTFDSSensor = 12,
Bookmark_CTFBETurretA = 13,
Bookmark_CTFBETurretB = 14,
Bookmark_CTFBETurretC = 15,
Bookmark_CTFDSTurretA = 16,
Bookmark_CTFDSTurretB = 17,
Bookmark_CTFDSTurretC = 18,
Bookmark_CTFBEBackRoute = 19,
Bookmark_CTFDSBackRoute = 20,
Bookmark_TDMEast = 21,
Bookmark_TDMWest = 22,
Bookmark_TDMNorth = 23,
Bookmark_TDMSouth = 24,
Bookmark_TDMCenter = 25,
Bookmark_TDMMapOverhead = 26,
Bookmark_DdDryHigh = 27,
Bookmark_DdDryLow = 28,
Bookmark_DdBEWide = 29,
Bookmark_DdDSWide = 30,
Bookmark_DdDockHigh = 31,
Bookmark_DdDockLow = 32,
Bookmark_DdBEBunker = 33,
Bookmark_DdDSBunker = 34,
Bookmark_DdBEBackEntrance = 35,
Bookmark_DdDSBackEntrance = 36,
Bookmark_DNFish = 37,
Bookmark_XFBSW = 38,
Bookmark_XFRSW = 39,
Bookmark_XFBERed = 40,
Bookmark_XFDSRed = 41,
Bookmark_XFBEBlue = 42,
Bookmark_XFDSBlue = 43,
Bookmark_XFBEBackstop = 44,
Bookmark_XFDSBackstop = 45,
Bookmark_XFBECRoom = 46,
Bookmark_XFDSCRoom = 47,
Bookmark_NKTower = 48,
Bookmark_NKTunnel = 49,
Bookmark_NKWhalebones = 50,
Bookmark_NKMountainView = 51,
Bookmark_NKMountainSide = 52,
Bookmark_BTBase = 53,
Bookmark_BTBaseInterior = 54,
Bookmark_BTTunnelEast = 55,
Bookmark_BTTunnelWest = 56,
Bookmark_GenericCamera = 57,
Bookmark_MAX = 58,
}
@property final auto ref
{
TrCamera_SpectatorBookmark.ESpectatorBookmark m_BookmarkDescription() { mixin(MGPC("TrCamera_SpectatorBookmark.ESpectatorBookmark", 1416)); }
ScriptString BEBase() { mixin(MGPC("ScriptString", 720)); }
ScriptString GenericCamera() { mixin(MGPC("ScriptString", 1404)); }
ScriptString BTTunnelWest() { mixin(MGPC("ScriptString", 1392)); }
ScriptString BTTunnelEast() { mixin(MGPC("ScriptString", 1380)); }
ScriptString BTBaseInterior() { mixin(MGPC("ScriptString", 1368)); }
ScriptString BTBase() { mixin(MGPC("ScriptString", 1356)); }
ScriptString NKMountainSide() { mixin(MGPC("ScriptString", 1344)); }
ScriptString NKMountainView() { mixin(MGPC("ScriptString", 1332)); }
ScriptString NKWhalebones() { mixin(MGPC("ScriptString", 1320)); }
ScriptString NKTunnel() { mixin(MGPC("ScriptString", 1308)); }
ScriptString NKTower() { mixin(MGPC("ScriptString", 1296)); }
ScriptString XFDSCRoom() { mixin(MGPC("ScriptString", 1284)); }
ScriptString XFBECRoom() { mixin(MGPC("ScriptString", 1272)); }
ScriptString XFDSBackstop() { mixin(MGPC("ScriptString", 1260)); }
ScriptString XFBEBackstop() { mixin(MGPC("ScriptString", 1248)); }
ScriptString XFDSBlue() { mixin(MGPC("ScriptString", 1236)); }
ScriptString XFBEBlue() { mixin(MGPC("ScriptString", 1224)); }
ScriptString XFDSRed() { mixin(MGPC("ScriptString", 1212)); }
ScriptString XFBERed() { mixin(MGPC("ScriptString", 1200)); }
ScriptString XFRSW() { mixin(MGPC("ScriptString", 1188)); }
ScriptString XFBSW() { mixin(MGPC("ScriptString", 1176)); }
ScriptString DNFish() { mixin(MGPC("ScriptString", 1164)); }
ScriptString DdDSBackEntrance() { mixin(MGPC("ScriptString", 1152)); }
ScriptString DdBEBackEntrance() { mixin(MGPC("ScriptString", 1140)); }
ScriptString DdDSBunker() { mixin(MGPC("ScriptString", 1128)); }
ScriptString DdBEBunker() { mixin(MGPC("ScriptString", 1116)); }
ScriptString DdDockLow() { mixin(MGPC("ScriptString", 1104)); }
ScriptString DdDockHigh() { mixin(MGPC("ScriptString", 1092)); }
ScriptString DdDSWide() { mixin(MGPC("ScriptString", 1080)); }
ScriptString DdBEWide() { mixin(MGPC("ScriptString", 1068)); }
ScriptString DdDryLow() { mixin(MGPC("ScriptString", 1056)); }
ScriptString DdDryHigh() { mixin(MGPC("ScriptString", 1044)); }
ScriptString TDMMapOverhead() { mixin(MGPC("ScriptString", 1032)); }
ScriptString TDMCenter() { mixin(MGPC("ScriptString", 1020)); }
ScriptString TDMSouth() { mixin(MGPC("ScriptString", 1008)); }
ScriptString TDMNorth() { mixin(MGPC("ScriptString", 996)); }
ScriptString TDMWest() { mixin(MGPC("ScriptString", 984)); }
ScriptString TDMEast() { mixin(MGPC("ScriptString", 972)); }
ScriptString CTFDSBackRoute() { mixin(MGPC("ScriptString", 960)); }
ScriptString CTFBEBackRoute() { mixin(MGPC("ScriptString", 948)); }
ScriptString CTFDSTurretC() { mixin(MGPC("ScriptString", 936)); }
ScriptString CTFDSTurretB() { mixin(MGPC("ScriptString", 924)); }
ScriptString CTFDSTurretA() { mixin(MGPC("ScriptString", 912)); }
ScriptString CTFBETurretC() { mixin(MGPC("ScriptString", 900)); }
ScriptString CTFBETurretB() { mixin(MGPC("ScriptString", 888)); }
ScriptString CTFBETurretA() { mixin(MGPC("ScriptString", 876)); }
ScriptString CTFDSSensor() { mixin(MGPC("ScriptString", 864)); }
ScriptString CTFBESensor() { mixin(MGPC("ScriptString", 852)); }
ScriptString CTFDSSpawn() { mixin(MGPC("ScriptString", 840)); }
ScriptString CTFBESpawn() { mixin(MGPC("ScriptString", 828)); }
ScriptString CTFDSVehiclePad() { mixin(MGPC("ScriptString", 816)); }
ScriptString CTFBEVehiclePad() { mixin(MGPC("ScriptString", 804)); }
ScriptString CTFDSMidfield() { mixin(MGPC("ScriptString", 792)); }
ScriptString CTFBEMidfield() { mixin(MGPC("ScriptString", 780)); }
ScriptString CTFMapOverhead() { mixin(MGPC("ScriptString", 768)); }
ScriptString CTFDSGeneratorRoom() { mixin(MGPC("ScriptString", 756)); }
ScriptString CTFBEGeneratorRoom() { mixin(MGPC("ScriptString", 744)); }
ScriptString DSBase() { mixin(MGPC("ScriptString", 732)); }
}
final:
ScriptString GetDescription()
{
ubyte params[12];
params[] = 0;
(cast(ScriptObject)this).ProcessEvent(Functions.GetDescription, params.ptr, cast(void*)0);
return *cast(ScriptString*)params.ptr;
}
ScriptString GetSpectatorName()
{
ubyte params[12];
params[] = 0;
(cast(ScriptObject)this).ProcessEvent(Functions.GetSpectatorName, params.ptr, cast(void*)0);
return *cast(ScriptString*)params.ptr;
}
}
| D |
/substrate-node-template/target/debug/build/failure_derive-b136b0ef0ca4c56c/build_script_build-b136b0ef0ca4c56c: /root/.cargo/registry/src/github.com-1ecc6299db9ec823/failure_derive-0.1.8/build.rs
/substrate-node-template/target/debug/build/failure_derive-b136b0ef0ca4c56c/build_script_build-b136b0ef0ca4c56c.d: /root/.cargo/registry/src/github.com-1ecc6299db9ec823/failure_derive-0.1.8/build.rs
/root/.cargo/registry/src/github.com-1ecc6299db9ec823/failure_derive-0.1.8/build.rs:
| D |
be hungry
die of food deprivation
deprive of food
have a craving, appetite, or great desire for
deprive of a necessity and cause suffering
| D |
/**
* Compiler implementation of the
* $(LINK2 http://www.dlang.org, D programming language).
*
* Copyright: Copyright (c) 1999-2017 by Digital Mars, All Rights Reserved
* Authors: $(LINK2 http://www.digitalmars.com, Walter Bright)
* License: $(LINK2 http://www.boost.org/LICENSE_1_0.txt, Boost License 1.0)
* Source: $(LINK2 https://github.com/dlang/dmd/blob/master/src/ddmd/semantic.d, _semantic.d)
*/
module ddmd.semantic;
// Online documentation: https://dlang.org/phobos/ddmd_semantic.html
import ddmd.arraytypes;
import ddmd.dsymbol;
import ddmd.dscope;
import ddmd.dtemplate;
import ddmd.expression;
import ddmd.globals;
import ddmd.init;
import ddmd.mtype;
import ddmd.statement;
import ddmd.initsem;
import ddmd.dsymbolsem;
import ddmd.expressionsem;
import ddmd.statementsem;
import ddmd.templateparamsem;
import ddmd.typesem;
/*************************************
* Does semantic analysis on the public face of declarations.
*/
extern(C++) void semantic(Dsymbol dsym, Scope* sc)
{
scope v = new DsymbolSemanticVisitor(sc);
dsym.accept(v);
}
// entrypoint for semantic ExpressionSemanticVisitor
extern(C++) Expression semantic(Expression e, Scope* sc)
{
scope v = new ExpressionSemanticVisitor(sc);
e.accept(v);
return v.result;
}
/******************************************
* Perform semantic analysis on init.
* Params:
* init = Initializer AST node
* sc = context
* t = type that the initializer needs to become
* needInterpret = if CTFE needs to be run on this,
* such as if it is the initializer for a const declaration
* Returns:
* `Initializer` with completed semantic analysis, `ErrorInitializer` if errors
* were encountered
*/
extern(C++) Initializer semantic(Initializer init, Scope* sc, Type t, NeedInterpret needInterpret)
{
scope v = new InitializerSemanticVisitor(sc, t, needInterpret);
init.accept(v);
return v.result;
}
// Performs semantic analisys in Statement AST nodes
extern(C++) Statement semantic(Statement s, Scope* sc)
{
scope v = new StatementSemanticVisitor(sc);
s.accept(v);
return v.result;
}
/******************************************
* Perform semantic analysis on a type.
* Params:
* t = Type AST node
* loc = the location of the type
* sc = context
* Returns:
* `Type` with completed semantic analysis, `Terror` if errors
* were encountered
*/
extern(C++) Type semantic(Type t, Loc loc, Scope* sc)
{
scope v = new TypeSemanticVisitor(loc, sc);
t.accept(v);
return v.result;
}
void semantic(Catch c, Scope* sc)
{
semanticWrapper(c, sc);
}
/*************************************
* Does semantic analysis on initializers and members of aggregates.
*/
extern(C++) void semantic2(Dsymbol dsym, Scope* sc)
{
scope v = new Semantic2Visitor(sc);
dsym.accept(v);
}
/*************************************
* Does semantic analysis on function bodies.
*/
extern(C++) void semantic3(Dsymbol dsym, Scope* sc)
{
scope v = new Semantic3Visitor(sc);
dsym.accept(v);
}
| D |
/home/knoldus/IdeaProjects/assignment_thirteen/target/debug/deps/assignment_thirteen-fe4558825a5d7b3c: src/main.rs
/home/knoldus/IdeaProjects/assignment_thirteen/target/debug/deps/assignment_thirteen-fe4558825a5d7b3c.d: src/main.rs
src/main.rs:
| D |
module android.java.javax.security.cert.CertificateExpiredException;
public import android.java.javax.security.cert.CertificateExpiredException_d_interface;
import arsd.jni : ImportExportImpl;
mixin ImportExportImpl!CertificateExpiredException;
import import4 = android.java.java.lang.Class;
import import3 = android.java.java.lang.StackTraceElement;
import import0 = android.java.java.lang.JavaThrowable;
| D |
/**
* A depth-first visitor for expressions.
*
* Copyright: Copyright (C) 1999-2023 by The D Language Foundation, All Rights Reserved
* Authors: $(LINK2 https://www.digitalmars.com, Walter Bright)
* License: $(LINK2 https://www.boost.org/LICENSE_1_0.txt, Boost License 1.0)
* Source: $(LINK2 https://github.com/dlang/dmd/blob/master/src/dmd/apply.d, _apply.d)
* Documentation: https://dlang.org/phobos/dmd_apply.html
* Coverage: https://codecov.io/gh/dlang/dmd/src/master/src/dmd/apply.d
*/
module dmd.postordervisitor;
import dmd.arraytypes;
import dmd.dtemplate;
import dmd.expression;
import dmd.root.array;
import dmd.visitor;
bool walkPostorder(Expression e, StoppableVisitor v)
{
scope PostorderExpressionVisitor pv = new PostorderExpressionVisitor(v);
e.accept(pv);
return v.stop;
}
/**************************************
* An Expression tree walker that will visit each Expression e in the tree,
* in depth-first evaluation order, and call fp(e,param) on it.
* fp() signals whether the walking continues with its return value:
* Returns:
* 0 continue
* 1 done
* It's a bit slower than using virtual functions, but more encapsulated and less brittle.
* Creating an iterator for this would be much more complex.
*/
private extern (C++) final class PostorderExpressionVisitor : StoppableVisitor
{
alias visit = typeof(super).visit;
public:
StoppableVisitor v;
extern (D) this(StoppableVisitor v) scope
{
this.v = v;
}
bool doCond(Expression e)
{
if (!stop && e)
e.accept(this);
return stop;
}
extern(D) bool doCond(Expression[] e)
{
for (size_t i = 0; i < e.length && !stop; i++)
doCond(e[i]);
return stop;
}
bool applyTo(Expression e)
{
e.accept(v);
stop = v.stop;
return true;
}
override void visit(Expression e)
{
applyTo(e);
}
override void visit(NewExp e)
{
//printf("NewExp::apply(): %s\n", toChars());
doCond(e.thisexp) || doCond(e.arguments.peekSlice()) || applyTo(e);
}
override void visit(NewAnonClassExp e)
{
//printf("NewAnonClassExp::apply(): %s\n", toChars());
doCond(e.thisexp) || doCond(e.arguments.peekSlice()) || applyTo(e);
}
override void visit(TypeidExp e)
{
doCond(isExpression(e.obj)) || applyTo(e);
}
override void visit(UnaExp e)
{
doCond(e.e1) || applyTo(e);
}
override void visit(BinExp e)
{
doCond(e.e1) || doCond(e.e2) || applyTo(e);
}
override void visit(AssertExp e)
{
//printf("CallExp::apply(apply_fp_t fp, void *param): %s\n", toChars());
doCond(e.e1) || doCond(e.msg) || applyTo(e);
}
override void visit(CallExp e)
{
//printf("CallExp::apply(apply_fp_t fp, void *param): %s\n", toChars());
doCond(e.e1) || doCond(e.arguments.peekSlice()) || applyTo(e);
}
override void visit(ArrayExp e)
{
//printf("ArrayExp::apply(apply_fp_t fp, void *param): %s\n", toChars());
doCond(e.e1) || doCond(e.arguments.peekSlice()) || applyTo(e);
}
override void visit(SliceExp e)
{
doCond(e.e1) || doCond(e.lwr) || doCond(e.upr) || applyTo(e);
}
override void visit(ArrayLiteralExp e)
{
doCond(e.basis) || doCond(e.elements.peekSlice()) || applyTo(e);
}
override void visit(AssocArrayLiteralExp e)
{
doCond(e.keys.peekSlice()) || doCond(e.values.peekSlice()) || applyTo(e);
}
override void visit(StructLiteralExp e)
{
if (e.stageflags & stageApply)
return;
const old = e.stageflags;
e.stageflags |= stageApply;
doCond(e.elements.peekSlice()) || applyTo(e);
e.stageflags = old;
}
override void visit(TupleExp e)
{
doCond(e.e0) || doCond(e.exps.peekSlice()) || applyTo(e);
}
override void visit(CondExp e)
{
doCond(e.econd) || doCond(e.e1) || doCond(e.e2) || applyTo(e);
}
}
| D |
module temple.vibe;
version(Have_vibe_d):
pragma(msg, "Compiling Temple with Vibed support");
private {
import temple;
import vibe.http.server;
import vibe.textfilter.html;
import std.stdio;
import std.variant;
}
struct TempleHtmlFilter {
private static struct SafeString {
const string payload;
}
static void temple_filter(ref TempleOutputStream stream, string unsafe) {
filterHTMLEscape(stream, unsafe);
}
static void temple_filter(ref TempleOutputStream stream, Variant variant) {
temple_filter(stream, variant.toString);
}
static string temple_filter(SafeString safe) {
return safe.payload;
}
static SafeString safe(string str) {
return SafeString(str);
}
static SafeString safe(Variant variant) {
return SafeString(variant.toString);
}
}
private enum SetupContext = q{
static if(is(Ctx == HTTPServerRequest)) {
TempleContext context = new TempleContext();
copyContextParams(context, req);
}
else {
TempleContext context = req;
}
};
private template isSupportedCtx(Ctx) {
enum isSupportedCtx = is(Ctx : HTTPServerRequest) || is(Ctx == TempleContext);
}
void renderTemple(string temple, Ctx = TempleContext)
(HTTPServerResponse res, Ctx req = null)
if(isSupportedCtx!Ctx)
{
mixin(SetupContext);
auto t = compile_temple!(temple, TempleHtmlFilter);
t.render(res.bodyWriter, context);
}
void renderTempleFile(string file, Ctx = TempleContext)
(HTTPServerResponse res, Ctx req = null)
if(isSupportedCtx!Ctx)
{
mixin(SetupContext);
auto t = compile_temple_file!(file, TempleHtmlFilter);
t.render(res.bodyWriter, context);
}
void renderTempleLayoutFile(string layout_file, string partial_file, Ctx = TempleContext)
(HTTPServerResponse res, Ctx req = null)
if(isSupportedCtx!Ctx)
{
mixin(SetupContext);
auto layout = compile_temple_file!(layout_file, TempleHtmlFilter);
auto partial = compile_temple_file!(partial_file, TempleHtmlFilter);
auto composed = layout.layout(&partial);
composed.render(res.bodyWriter, context);
}
private void copyContextParams(ref TempleContext ctx, ref HTTPServerRequest req) {
if(!req || !(req.params))
return;
foreach(key, val; req.params) {
ctx[key] = val;
}
}
| D |
module dcrypt.random.fortuna.sources.rdrand;
import dcrypt.random.rdrand;
import dcrypt.random.fortuna.entropysource;
import dcrypt.random.fortuna.fortuna: addEntropy;
/// Generate entropy data with intel rdrand instruction.
@safe
public class RDRandEntropySource: EntropySource
{
private {
uint delay = 250;
RDRand rdrand;
}
override void collectEntropy() nothrow {
ubyte[32] buf;
if(rdrand.isSupported) {
rdrand.nextBytes(buf);
} else {
// not supported
delay = 0;
}
sendEntropyEvent(buf);
}
@nogc @property nothrow
override public string name() {
return "RDRand";
}
@safe @nogc nothrow
override uint scheduleNext() {
return delay;
}
} | D |
(colloquial) the application of maximum thrust
(computing) a security system consisting of a combination of hardware and software that limits the exposure of a computer or computer network to attack from crackers
a fireproof (or fire-resistant) wall designed to prevent the spread of fire through a building or a vehicle
| D |
/Users/freebird/Desktop/Work/wokinprogress/Bump/Bump/build/Bump.build/Debug-iphonesimulator/Bump.build/Objects-normal/x86_64/SwitchCell.o : /Users/freebird/Desktop/Work/wokinprogress/Bump/Bump/Bump/ViewController/CameraVC.swift /Users/freebird/Desktop/Work/wokinprogress/Bump/Bump/Bump/ViewController/NameVC.swift /Users/freebird/Desktop/Work/wokinprogress/Bump/Bump/Bump/ViewController/HomeVC.swift /Users/freebird/Desktop/Work/wokinprogress/Bump/Bump/Bump/ViewController/ShareVC.swift /Users/freebird/Desktop/Work/wokinprogress/Bump/Bump/Bump/ViewController/PurchaseVC.swift /Users/freebird/Desktop/Work/wokinprogress/Bump/Bump/Bump/ViewController/Setting/SettingVC.swift /Users/freebird/Desktop/Work/wokinprogress/Bump/Bump/Bump/ViewController/AccountDetailVC.swift /Users/freebird/Desktop/Work/wokinprogress/Bump/Bump/Bump/ViewController/ConfirmVC.swift /Users/freebird/Desktop/Work/wokinprogress/Bump/Bump/Bump/ViewController/SignVC.swift /Users/freebird/Desktop/Work/wokinprogress/Bump/Bump/Bump/ViewController/Notification/BumpVC.swift /Users/freebird/Desktop/Work/wokinprogress/Bump/Bump/Bump/ViewController/GenderVC.swift /Users/freebird/Desktop/Work/wokinprogress/Bump/Bump/Bump/ViewController/PhotoFilterVC.swift /Users/freebird/Desktop/Work/wokinprogress/Bump/Bump/Bump/ViewController/TermsVC.swift /Users/freebird/Desktop/Work/wokinprogress/Bump/Bump/Bump/ViewController/ContactVC.swift /Users/freebird/Desktop/Work/wokinprogress/Bump/Bump/Bump/ViewController/DeleteAccountVC.swift /Users/freebird/Desktop/Work/wokinprogress/Bump/Bump/Bump/ViewController/PrivacyPolicyVC.swift /Users/freebird/Desktop/Work/wokinprogress/Bump/Bump/Bump/SceneDelegate.swift /Users/freebird/Desktop/Work/wokinprogress/Bump/Bump/Bump/AppDelegate.swift /Users/freebird/Desktop/Work/wokinprogress/Bump/Bump/Bump/ViewController/Setting/DisclosureCell.swift /Users/freebird/Desktop/Work/wokinprogress/Bump/Bump/Bump/ViewController/Setting/SwitchCell.swift /Users/freebird/Desktop/Work/wokinprogress/Bump/Bump/Bump/ViewController/Notification/NotificationCell.swift /Users/freebird/Desktop/Work/wokinprogress/Bump/Bump/Bump/ViewController/Setting/ProfilePhotoCell.swift /Users/freebird/Desktop/Work/wokinprogress/Bump/Bump/Bump/ViewController/Setting/DeleteAccountCell.swift /Users/freebird/Desktop/Work/wokinprogress/Bump/Bump/Bump/ViewController/ImageCollectionViewCell.swift /Users/freebird/Desktop/Work/wokinprogress/Bump/Bump/Bump/ViewController/UICollectionViewPagingFlowLayout.swift /Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/lib/swift/iphonesimulator/prebuilt-modules/ObjectiveC.swiftmodule/x86_64.swiftmodule /Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/lib/swift/iphonesimulator/prebuilt-modules/CoreMIDI.swiftmodule/x86_64.swiftmodule /Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/lib/swift/iphonesimulator/prebuilt-modules/CoreMedia.swiftmodule/x86_64.swiftmodule /Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/lib/swift/iphonesimulator/prebuilt-modules/simd.swiftmodule/x86_64.swiftmodule /Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/lib/swift/iphonesimulator/prebuilt-modules/CoreImage.swiftmodule/x86_64.swiftmodule /Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/lib/swift/iphonesimulator/prebuilt-modules/QuartzCore.swiftmodule/x86_64.swiftmodule /Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/lib/swift/iphonesimulator/prebuilt-modules/Dispatch.swiftmodule/x86_64.swiftmodule /Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/lib/swift/iphonesimulator/prebuilt-modules/Metal.swiftmodule/x86_64.swiftmodule /Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/lib/swift/iphonesimulator/prebuilt-modules/Darwin.swiftmodule/x86_64.swiftmodule /Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/lib/swift/iphonesimulator/prebuilt-modules/Foundation.swiftmodule/x86_64.swiftmodule /Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/lib/swift/iphonesimulator/prebuilt-modules/AVFoundation.swiftmodule/x86_64.swiftmodule /Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/lib/swift/iphonesimulator/prebuilt-modules/CoreFoundation.swiftmodule/x86_64.swiftmodule /Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/lib/swift/iphonesimulator/prebuilt-modules/CoreAudio.swiftmodule/x86_64.swiftmodule /Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/lib/swift/iphonesimulator/prebuilt-modules/CoreGraphics.swiftmodule/x86_64.swiftmodule /Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/lib/swift/iphonesimulator/prebuilt-modules/Swift.swiftmodule/x86_64.swiftmodule /Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/lib/swift/iphonesimulator/prebuilt-modules/UIKit.swiftmodule/x86_64.swiftmodule /Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/lib/swift/iphonesimulator/prebuilt-modules/SwiftOnoneSupport.swiftmodule/x86_64.swiftmodule /Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/lib/swift/iphonesimulator/prebuilt-modules/Combine.swiftmodule/x86_64-apple-ios-simulator.swiftmodule /Users/freebird/Desktop/Work/wokinprogress/Bump/Bump/build/Debug-iphonesimulator/Gemini/Gemini.framework/Modules/Gemini.swiftmodule/x86_64-apple-ios-simulator.swiftmodule /Users/freebird/Desktop/Work/wokinprogress/Bump/Bump/build/Debug-iphonesimulator/KeyboardObserver/KeyboardObserver.framework/Modules/KeyboardObserver.swiftmodule/x86_64-apple-ios-simulator.swiftmodule /Users/freebird/Desktop/Work/wokinprogress/Bump/Bump/build/Debug-iphonesimulator/Gemini/Gemini.framework/Headers/Gemini-umbrella.h /Users/freebird/Desktop/Work/wokinprogress/Bump/Bump/build/Debug-iphonesimulator/KeyboardObserver/KeyboardObserver.framework/Headers/KeyboardObserver-umbrella.h /Users/freebird/Desktop/Work/wokinprogress/Bump/Bump/build/Debug-iphonesimulator/Gemini/Gemini.framework/Headers/Gemini-Swift.h /Users/freebird/Desktop/Work/wokinprogress/Bump/Bump/build/Debug-iphonesimulator/KeyboardObserver/KeyboardObserver.framework/Headers/KeyboardObserver-Swift.h /Users/freebird/Desktop/Work/wokinprogress/Bump/Bump/build/Debug-iphonesimulator/Gemini/Gemini.framework/Modules/module.modulemap /Users/freebird/Desktop/Work/wokinprogress/Bump/Bump/build/Debug-iphonesimulator/KeyboardObserver/KeyboardObserver.framework/Modules/module.modulemap /Applications/Xcode.app/Contents/Developer/Platforms/iPhoneSimulator.platform/Developer/SDKs/iPhoneSimulator13.5.sdk/usr/include/objc/ObjectiveC.apinotes /Applications/Xcode.app/Contents/Developer/Platforms/iPhoneSimulator.platform/Developer/SDKs/iPhoneSimulator13.5.sdk/System/Library/Frameworks/OpenGLES.framework/Headers/OpenGLES.apinotes /Applications/Xcode.app/Contents/Developer/Platforms/iPhoneSimulator.platform/Developer/SDKs/iPhoneSimulator13.5.sdk/System/Library/Frameworks/CoreMedia.framework/Headers/CoreMedia.apinotes /Applications/Xcode.app/Contents/Developer/Platforms/iPhoneSimulator.platform/Developer/SDKs/iPhoneSimulator13.5.sdk/System/Library/Frameworks/CoreImage.framework/Headers/CoreImage.apinotes /Applications/Xcode.app/Contents/Developer/Platforms/iPhoneSimulator.platform/Developer/SDKs/iPhoneSimulator13.5.sdk/System/Library/Frameworks/QuartzCore.framework/Headers/QuartzCore.apinotes /Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/lib/swift/apinotes/Dispatch.apinotes /Applications/Xcode.app/Contents/Developer/Platforms/iPhoneSimulator.platform/Developer/SDKs/iPhoneSimulator13.5.sdk/System/Library/Frameworks/Metal.framework/Headers/Metal.apinotes /Applications/Xcode.app/Contents/Developer/Platforms/iPhoneSimulator.platform/Developer/SDKs/iPhoneSimulator13.5.sdk/usr/include/Darwin.apinotes /Applications/Xcode.app/Contents/Developer/Platforms/iPhoneSimulator.platform/Developer/SDKs/iPhoneSimulator13.5.sdk/System/Library/Frameworks/Foundation.framework/Headers/Foundation.apinotes /Applications/Xcode.app/Contents/Developer/Platforms/iPhoneSimulator.platform/Developer/SDKs/iPhoneSimulator13.5.sdk/System/Library/Frameworks/AVFoundation.framework/Headers/AVFoundation.apinotes /Applications/Xcode.app/Contents/Developer/Platforms/iPhoneSimulator.platform/Developer/SDKs/iPhoneSimulator13.5.sdk/System/Library/Frameworks/CoreGraphics.framework/Headers/CoreGraphics.apinotes /Applications/Xcode.app/Contents/Developer/Platforms/iPhoneSimulator.platform/Developer/SDKs/iPhoneSimulator13.5.sdk/System/Library/Frameworks/CoreAudioTypes.framework/Headers/CoreAudioTypes.apinotes /Applications/Xcode.app/Contents/Developer/Platforms/iPhoneSimulator.platform/Developer/SDKs/iPhoneSimulator13.5.sdk/System/Library/Frameworks/UserNotifications.framework/Headers/UserNotifications.apinotes /Applications/Xcode.app/Contents/Developer/Platforms/iPhoneSimulator.platform/Developer/SDKs/iPhoneSimulator13.5.sdk/System/Library/Frameworks/UIKit.framework/Headers/UIKit.apinotes /Applications/Xcode.app/Contents/Developer/Platforms/iPhoneSimulator.platform/Developer/SDKs/iPhoneSimulator13.5.sdk/System/Library/Frameworks/WebKit.framework/Headers/WebKit.apinotes /Applications/Xcode.app/Contents/Developer/Platforms/iPhoneSimulator.platform/Developer/SDKs/iPhoneSimulator13.5.sdk/System/Library/Frameworks/CoreText.framework/Headers/CoreText.apinotes /Applications/Xcode.app/Contents/Developer/Platforms/iPhoneSimulator.platform/Developer/SDKs/iPhoneSimulator13.5.sdk/System/Library/Frameworks/MediaToolbox.framework/Headers/MediaToolbox.apinotes /Applications/Xcode.app/Contents/Developer/Platforms/iPhoneSimulator.platform/Developer/SDKs/iPhoneSimulator13.5.sdk/System/Library/Frameworks/AudioToolbox.framework/Headers/AudioToolbox.apinotes /Applications/Xcode.app/Contents/Developer/Platforms/iPhoneSimulator.platform/Developer/SDKs/iPhoneSimulator13.5.sdk/System/Library/Frameworks/Security.framework/Headers/Security.apinotes
/Users/freebird/Desktop/Work/wokinprogress/Bump/Bump/build/Bump.build/Debug-iphonesimulator/Bump.build/Objects-normal/x86_64/SwitchCell~partial.swiftmodule : /Users/freebird/Desktop/Work/wokinprogress/Bump/Bump/Bump/ViewController/CameraVC.swift /Users/freebird/Desktop/Work/wokinprogress/Bump/Bump/Bump/ViewController/NameVC.swift /Users/freebird/Desktop/Work/wokinprogress/Bump/Bump/Bump/ViewController/HomeVC.swift /Users/freebird/Desktop/Work/wokinprogress/Bump/Bump/Bump/ViewController/ShareVC.swift /Users/freebird/Desktop/Work/wokinprogress/Bump/Bump/Bump/ViewController/PurchaseVC.swift /Users/freebird/Desktop/Work/wokinprogress/Bump/Bump/Bump/ViewController/Setting/SettingVC.swift /Users/freebird/Desktop/Work/wokinprogress/Bump/Bump/Bump/ViewController/AccountDetailVC.swift /Users/freebird/Desktop/Work/wokinprogress/Bump/Bump/Bump/ViewController/ConfirmVC.swift /Users/freebird/Desktop/Work/wokinprogress/Bump/Bump/Bump/ViewController/SignVC.swift /Users/freebird/Desktop/Work/wokinprogress/Bump/Bump/Bump/ViewController/Notification/BumpVC.swift /Users/freebird/Desktop/Work/wokinprogress/Bump/Bump/Bump/ViewController/GenderVC.swift /Users/freebird/Desktop/Work/wokinprogress/Bump/Bump/Bump/ViewController/PhotoFilterVC.swift /Users/freebird/Desktop/Work/wokinprogress/Bump/Bump/Bump/ViewController/TermsVC.swift /Users/freebird/Desktop/Work/wokinprogress/Bump/Bump/Bump/ViewController/ContactVC.swift /Users/freebird/Desktop/Work/wokinprogress/Bump/Bump/Bump/ViewController/DeleteAccountVC.swift /Users/freebird/Desktop/Work/wokinprogress/Bump/Bump/Bump/ViewController/PrivacyPolicyVC.swift /Users/freebird/Desktop/Work/wokinprogress/Bump/Bump/Bump/SceneDelegate.swift /Users/freebird/Desktop/Work/wokinprogress/Bump/Bump/Bump/AppDelegate.swift /Users/freebird/Desktop/Work/wokinprogress/Bump/Bump/Bump/ViewController/Setting/DisclosureCell.swift /Users/freebird/Desktop/Work/wokinprogress/Bump/Bump/Bump/ViewController/Setting/SwitchCell.swift /Users/freebird/Desktop/Work/wokinprogress/Bump/Bump/Bump/ViewController/Notification/NotificationCell.swift /Users/freebird/Desktop/Work/wokinprogress/Bump/Bump/Bump/ViewController/Setting/ProfilePhotoCell.swift /Users/freebird/Desktop/Work/wokinprogress/Bump/Bump/Bump/ViewController/Setting/DeleteAccountCell.swift /Users/freebird/Desktop/Work/wokinprogress/Bump/Bump/Bump/ViewController/ImageCollectionViewCell.swift /Users/freebird/Desktop/Work/wokinprogress/Bump/Bump/Bump/ViewController/UICollectionViewPagingFlowLayout.swift /Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/lib/swift/iphonesimulator/prebuilt-modules/ObjectiveC.swiftmodule/x86_64.swiftmodule /Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/lib/swift/iphonesimulator/prebuilt-modules/CoreMIDI.swiftmodule/x86_64.swiftmodule /Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/lib/swift/iphonesimulator/prebuilt-modules/CoreMedia.swiftmodule/x86_64.swiftmodule /Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/lib/swift/iphonesimulator/prebuilt-modules/simd.swiftmodule/x86_64.swiftmodule /Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/lib/swift/iphonesimulator/prebuilt-modules/CoreImage.swiftmodule/x86_64.swiftmodule /Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/lib/swift/iphonesimulator/prebuilt-modules/QuartzCore.swiftmodule/x86_64.swiftmodule /Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/lib/swift/iphonesimulator/prebuilt-modules/Dispatch.swiftmodule/x86_64.swiftmodule /Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/lib/swift/iphonesimulator/prebuilt-modules/Metal.swiftmodule/x86_64.swiftmodule /Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/lib/swift/iphonesimulator/prebuilt-modules/Darwin.swiftmodule/x86_64.swiftmodule /Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/lib/swift/iphonesimulator/prebuilt-modules/Foundation.swiftmodule/x86_64.swiftmodule /Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/lib/swift/iphonesimulator/prebuilt-modules/AVFoundation.swiftmodule/x86_64.swiftmodule /Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/lib/swift/iphonesimulator/prebuilt-modules/CoreFoundation.swiftmodule/x86_64.swiftmodule /Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/lib/swift/iphonesimulator/prebuilt-modules/CoreAudio.swiftmodule/x86_64.swiftmodule /Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/lib/swift/iphonesimulator/prebuilt-modules/CoreGraphics.swiftmodule/x86_64.swiftmodule /Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/lib/swift/iphonesimulator/prebuilt-modules/Swift.swiftmodule/x86_64.swiftmodule /Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/lib/swift/iphonesimulator/prebuilt-modules/UIKit.swiftmodule/x86_64.swiftmodule /Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/lib/swift/iphonesimulator/prebuilt-modules/SwiftOnoneSupport.swiftmodule/x86_64.swiftmodule /Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/lib/swift/iphonesimulator/prebuilt-modules/Combine.swiftmodule/x86_64-apple-ios-simulator.swiftmodule /Users/freebird/Desktop/Work/wokinprogress/Bump/Bump/build/Debug-iphonesimulator/Gemini/Gemini.framework/Modules/Gemini.swiftmodule/x86_64-apple-ios-simulator.swiftmodule /Users/freebird/Desktop/Work/wokinprogress/Bump/Bump/build/Debug-iphonesimulator/KeyboardObserver/KeyboardObserver.framework/Modules/KeyboardObserver.swiftmodule/x86_64-apple-ios-simulator.swiftmodule /Users/freebird/Desktop/Work/wokinprogress/Bump/Bump/build/Debug-iphonesimulator/Gemini/Gemini.framework/Headers/Gemini-umbrella.h /Users/freebird/Desktop/Work/wokinprogress/Bump/Bump/build/Debug-iphonesimulator/KeyboardObserver/KeyboardObserver.framework/Headers/KeyboardObserver-umbrella.h /Users/freebird/Desktop/Work/wokinprogress/Bump/Bump/build/Debug-iphonesimulator/Gemini/Gemini.framework/Headers/Gemini-Swift.h /Users/freebird/Desktop/Work/wokinprogress/Bump/Bump/build/Debug-iphonesimulator/KeyboardObserver/KeyboardObserver.framework/Headers/KeyboardObserver-Swift.h /Users/freebird/Desktop/Work/wokinprogress/Bump/Bump/build/Debug-iphonesimulator/Gemini/Gemini.framework/Modules/module.modulemap /Users/freebird/Desktop/Work/wokinprogress/Bump/Bump/build/Debug-iphonesimulator/KeyboardObserver/KeyboardObserver.framework/Modules/module.modulemap /Applications/Xcode.app/Contents/Developer/Platforms/iPhoneSimulator.platform/Developer/SDKs/iPhoneSimulator13.5.sdk/usr/include/objc/ObjectiveC.apinotes /Applications/Xcode.app/Contents/Developer/Platforms/iPhoneSimulator.platform/Developer/SDKs/iPhoneSimulator13.5.sdk/System/Library/Frameworks/OpenGLES.framework/Headers/OpenGLES.apinotes /Applications/Xcode.app/Contents/Developer/Platforms/iPhoneSimulator.platform/Developer/SDKs/iPhoneSimulator13.5.sdk/System/Library/Frameworks/CoreMedia.framework/Headers/CoreMedia.apinotes /Applications/Xcode.app/Contents/Developer/Platforms/iPhoneSimulator.platform/Developer/SDKs/iPhoneSimulator13.5.sdk/System/Library/Frameworks/CoreImage.framework/Headers/CoreImage.apinotes /Applications/Xcode.app/Contents/Developer/Platforms/iPhoneSimulator.platform/Developer/SDKs/iPhoneSimulator13.5.sdk/System/Library/Frameworks/QuartzCore.framework/Headers/QuartzCore.apinotes /Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/lib/swift/apinotes/Dispatch.apinotes /Applications/Xcode.app/Contents/Developer/Platforms/iPhoneSimulator.platform/Developer/SDKs/iPhoneSimulator13.5.sdk/System/Library/Frameworks/Metal.framework/Headers/Metal.apinotes /Applications/Xcode.app/Contents/Developer/Platforms/iPhoneSimulator.platform/Developer/SDKs/iPhoneSimulator13.5.sdk/usr/include/Darwin.apinotes /Applications/Xcode.app/Contents/Developer/Platforms/iPhoneSimulator.platform/Developer/SDKs/iPhoneSimulator13.5.sdk/System/Library/Frameworks/Foundation.framework/Headers/Foundation.apinotes /Applications/Xcode.app/Contents/Developer/Platforms/iPhoneSimulator.platform/Developer/SDKs/iPhoneSimulator13.5.sdk/System/Library/Frameworks/AVFoundation.framework/Headers/AVFoundation.apinotes /Applications/Xcode.app/Contents/Developer/Platforms/iPhoneSimulator.platform/Developer/SDKs/iPhoneSimulator13.5.sdk/System/Library/Frameworks/CoreGraphics.framework/Headers/CoreGraphics.apinotes /Applications/Xcode.app/Contents/Developer/Platforms/iPhoneSimulator.platform/Developer/SDKs/iPhoneSimulator13.5.sdk/System/Library/Frameworks/CoreAudioTypes.framework/Headers/CoreAudioTypes.apinotes /Applications/Xcode.app/Contents/Developer/Platforms/iPhoneSimulator.platform/Developer/SDKs/iPhoneSimulator13.5.sdk/System/Library/Frameworks/UserNotifications.framework/Headers/UserNotifications.apinotes /Applications/Xcode.app/Contents/Developer/Platforms/iPhoneSimulator.platform/Developer/SDKs/iPhoneSimulator13.5.sdk/System/Library/Frameworks/UIKit.framework/Headers/UIKit.apinotes /Applications/Xcode.app/Contents/Developer/Platforms/iPhoneSimulator.platform/Developer/SDKs/iPhoneSimulator13.5.sdk/System/Library/Frameworks/WebKit.framework/Headers/WebKit.apinotes /Applications/Xcode.app/Contents/Developer/Platforms/iPhoneSimulator.platform/Developer/SDKs/iPhoneSimulator13.5.sdk/System/Library/Frameworks/CoreText.framework/Headers/CoreText.apinotes /Applications/Xcode.app/Contents/Developer/Platforms/iPhoneSimulator.platform/Developer/SDKs/iPhoneSimulator13.5.sdk/System/Library/Frameworks/MediaToolbox.framework/Headers/MediaToolbox.apinotes /Applications/Xcode.app/Contents/Developer/Platforms/iPhoneSimulator.platform/Developer/SDKs/iPhoneSimulator13.5.sdk/System/Library/Frameworks/AudioToolbox.framework/Headers/AudioToolbox.apinotes /Applications/Xcode.app/Contents/Developer/Platforms/iPhoneSimulator.platform/Developer/SDKs/iPhoneSimulator13.5.sdk/System/Library/Frameworks/Security.framework/Headers/Security.apinotes
/Users/freebird/Desktop/Work/wokinprogress/Bump/Bump/build/Bump.build/Debug-iphonesimulator/Bump.build/Objects-normal/x86_64/SwitchCell~partial.swiftdoc : /Users/freebird/Desktop/Work/wokinprogress/Bump/Bump/Bump/ViewController/CameraVC.swift /Users/freebird/Desktop/Work/wokinprogress/Bump/Bump/Bump/ViewController/NameVC.swift /Users/freebird/Desktop/Work/wokinprogress/Bump/Bump/Bump/ViewController/HomeVC.swift /Users/freebird/Desktop/Work/wokinprogress/Bump/Bump/Bump/ViewController/ShareVC.swift /Users/freebird/Desktop/Work/wokinprogress/Bump/Bump/Bump/ViewController/PurchaseVC.swift /Users/freebird/Desktop/Work/wokinprogress/Bump/Bump/Bump/ViewController/Setting/SettingVC.swift /Users/freebird/Desktop/Work/wokinprogress/Bump/Bump/Bump/ViewController/AccountDetailVC.swift /Users/freebird/Desktop/Work/wokinprogress/Bump/Bump/Bump/ViewController/ConfirmVC.swift /Users/freebird/Desktop/Work/wokinprogress/Bump/Bump/Bump/ViewController/SignVC.swift /Users/freebird/Desktop/Work/wokinprogress/Bump/Bump/Bump/ViewController/Notification/BumpVC.swift /Users/freebird/Desktop/Work/wokinprogress/Bump/Bump/Bump/ViewController/GenderVC.swift /Users/freebird/Desktop/Work/wokinprogress/Bump/Bump/Bump/ViewController/PhotoFilterVC.swift /Users/freebird/Desktop/Work/wokinprogress/Bump/Bump/Bump/ViewController/TermsVC.swift /Users/freebird/Desktop/Work/wokinprogress/Bump/Bump/Bump/ViewController/ContactVC.swift /Users/freebird/Desktop/Work/wokinprogress/Bump/Bump/Bump/ViewController/DeleteAccountVC.swift /Users/freebird/Desktop/Work/wokinprogress/Bump/Bump/Bump/ViewController/PrivacyPolicyVC.swift /Users/freebird/Desktop/Work/wokinprogress/Bump/Bump/Bump/SceneDelegate.swift /Users/freebird/Desktop/Work/wokinprogress/Bump/Bump/Bump/AppDelegate.swift /Users/freebird/Desktop/Work/wokinprogress/Bump/Bump/Bump/ViewController/Setting/DisclosureCell.swift /Users/freebird/Desktop/Work/wokinprogress/Bump/Bump/Bump/ViewController/Setting/SwitchCell.swift /Users/freebird/Desktop/Work/wokinprogress/Bump/Bump/Bump/ViewController/Notification/NotificationCell.swift /Users/freebird/Desktop/Work/wokinprogress/Bump/Bump/Bump/ViewController/Setting/ProfilePhotoCell.swift /Users/freebird/Desktop/Work/wokinprogress/Bump/Bump/Bump/ViewController/Setting/DeleteAccountCell.swift /Users/freebird/Desktop/Work/wokinprogress/Bump/Bump/Bump/ViewController/ImageCollectionViewCell.swift /Users/freebird/Desktop/Work/wokinprogress/Bump/Bump/Bump/ViewController/UICollectionViewPagingFlowLayout.swift /Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/lib/swift/iphonesimulator/prebuilt-modules/ObjectiveC.swiftmodule/x86_64.swiftmodule /Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/lib/swift/iphonesimulator/prebuilt-modules/CoreMIDI.swiftmodule/x86_64.swiftmodule /Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/lib/swift/iphonesimulator/prebuilt-modules/CoreMedia.swiftmodule/x86_64.swiftmodule /Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/lib/swift/iphonesimulator/prebuilt-modules/simd.swiftmodule/x86_64.swiftmodule /Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/lib/swift/iphonesimulator/prebuilt-modules/CoreImage.swiftmodule/x86_64.swiftmodule /Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/lib/swift/iphonesimulator/prebuilt-modules/QuartzCore.swiftmodule/x86_64.swiftmodule /Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/lib/swift/iphonesimulator/prebuilt-modules/Dispatch.swiftmodule/x86_64.swiftmodule /Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/lib/swift/iphonesimulator/prebuilt-modules/Metal.swiftmodule/x86_64.swiftmodule /Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/lib/swift/iphonesimulator/prebuilt-modules/Darwin.swiftmodule/x86_64.swiftmodule /Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/lib/swift/iphonesimulator/prebuilt-modules/Foundation.swiftmodule/x86_64.swiftmodule /Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/lib/swift/iphonesimulator/prebuilt-modules/AVFoundation.swiftmodule/x86_64.swiftmodule /Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/lib/swift/iphonesimulator/prebuilt-modules/CoreFoundation.swiftmodule/x86_64.swiftmodule /Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/lib/swift/iphonesimulator/prebuilt-modules/CoreAudio.swiftmodule/x86_64.swiftmodule /Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/lib/swift/iphonesimulator/prebuilt-modules/CoreGraphics.swiftmodule/x86_64.swiftmodule /Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/lib/swift/iphonesimulator/prebuilt-modules/Swift.swiftmodule/x86_64.swiftmodule /Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/lib/swift/iphonesimulator/prebuilt-modules/UIKit.swiftmodule/x86_64.swiftmodule /Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/lib/swift/iphonesimulator/prebuilt-modules/SwiftOnoneSupport.swiftmodule/x86_64.swiftmodule /Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/lib/swift/iphonesimulator/prebuilt-modules/Combine.swiftmodule/x86_64-apple-ios-simulator.swiftmodule /Users/freebird/Desktop/Work/wokinprogress/Bump/Bump/build/Debug-iphonesimulator/Gemini/Gemini.framework/Modules/Gemini.swiftmodule/x86_64-apple-ios-simulator.swiftmodule /Users/freebird/Desktop/Work/wokinprogress/Bump/Bump/build/Debug-iphonesimulator/KeyboardObserver/KeyboardObserver.framework/Modules/KeyboardObserver.swiftmodule/x86_64-apple-ios-simulator.swiftmodule /Users/freebird/Desktop/Work/wokinprogress/Bump/Bump/build/Debug-iphonesimulator/Gemini/Gemini.framework/Headers/Gemini-umbrella.h /Users/freebird/Desktop/Work/wokinprogress/Bump/Bump/build/Debug-iphonesimulator/KeyboardObserver/KeyboardObserver.framework/Headers/KeyboardObserver-umbrella.h /Users/freebird/Desktop/Work/wokinprogress/Bump/Bump/build/Debug-iphonesimulator/Gemini/Gemini.framework/Headers/Gemini-Swift.h /Users/freebird/Desktop/Work/wokinprogress/Bump/Bump/build/Debug-iphonesimulator/KeyboardObserver/KeyboardObserver.framework/Headers/KeyboardObserver-Swift.h /Users/freebird/Desktop/Work/wokinprogress/Bump/Bump/build/Debug-iphonesimulator/Gemini/Gemini.framework/Modules/module.modulemap /Users/freebird/Desktop/Work/wokinprogress/Bump/Bump/build/Debug-iphonesimulator/KeyboardObserver/KeyboardObserver.framework/Modules/module.modulemap /Applications/Xcode.app/Contents/Developer/Platforms/iPhoneSimulator.platform/Developer/SDKs/iPhoneSimulator13.5.sdk/usr/include/objc/ObjectiveC.apinotes /Applications/Xcode.app/Contents/Developer/Platforms/iPhoneSimulator.platform/Developer/SDKs/iPhoneSimulator13.5.sdk/System/Library/Frameworks/OpenGLES.framework/Headers/OpenGLES.apinotes /Applications/Xcode.app/Contents/Developer/Platforms/iPhoneSimulator.platform/Developer/SDKs/iPhoneSimulator13.5.sdk/System/Library/Frameworks/CoreMedia.framework/Headers/CoreMedia.apinotes /Applications/Xcode.app/Contents/Developer/Platforms/iPhoneSimulator.platform/Developer/SDKs/iPhoneSimulator13.5.sdk/System/Library/Frameworks/CoreImage.framework/Headers/CoreImage.apinotes /Applications/Xcode.app/Contents/Developer/Platforms/iPhoneSimulator.platform/Developer/SDKs/iPhoneSimulator13.5.sdk/System/Library/Frameworks/QuartzCore.framework/Headers/QuartzCore.apinotes /Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/lib/swift/apinotes/Dispatch.apinotes /Applications/Xcode.app/Contents/Developer/Platforms/iPhoneSimulator.platform/Developer/SDKs/iPhoneSimulator13.5.sdk/System/Library/Frameworks/Metal.framework/Headers/Metal.apinotes /Applications/Xcode.app/Contents/Developer/Platforms/iPhoneSimulator.platform/Developer/SDKs/iPhoneSimulator13.5.sdk/usr/include/Darwin.apinotes /Applications/Xcode.app/Contents/Developer/Platforms/iPhoneSimulator.platform/Developer/SDKs/iPhoneSimulator13.5.sdk/System/Library/Frameworks/Foundation.framework/Headers/Foundation.apinotes /Applications/Xcode.app/Contents/Developer/Platforms/iPhoneSimulator.platform/Developer/SDKs/iPhoneSimulator13.5.sdk/System/Library/Frameworks/AVFoundation.framework/Headers/AVFoundation.apinotes /Applications/Xcode.app/Contents/Developer/Platforms/iPhoneSimulator.platform/Developer/SDKs/iPhoneSimulator13.5.sdk/System/Library/Frameworks/CoreGraphics.framework/Headers/CoreGraphics.apinotes /Applications/Xcode.app/Contents/Developer/Platforms/iPhoneSimulator.platform/Developer/SDKs/iPhoneSimulator13.5.sdk/System/Library/Frameworks/CoreAudioTypes.framework/Headers/CoreAudioTypes.apinotes /Applications/Xcode.app/Contents/Developer/Platforms/iPhoneSimulator.platform/Developer/SDKs/iPhoneSimulator13.5.sdk/System/Library/Frameworks/UserNotifications.framework/Headers/UserNotifications.apinotes /Applications/Xcode.app/Contents/Developer/Platforms/iPhoneSimulator.platform/Developer/SDKs/iPhoneSimulator13.5.sdk/System/Library/Frameworks/UIKit.framework/Headers/UIKit.apinotes /Applications/Xcode.app/Contents/Developer/Platforms/iPhoneSimulator.platform/Developer/SDKs/iPhoneSimulator13.5.sdk/System/Library/Frameworks/WebKit.framework/Headers/WebKit.apinotes /Applications/Xcode.app/Contents/Developer/Platforms/iPhoneSimulator.platform/Developer/SDKs/iPhoneSimulator13.5.sdk/System/Library/Frameworks/CoreText.framework/Headers/CoreText.apinotes /Applications/Xcode.app/Contents/Developer/Platforms/iPhoneSimulator.platform/Developer/SDKs/iPhoneSimulator13.5.sdk/System/Library/Frameworks/MediaToolbox.framework/Headers/MediaToolbox.apinotes /Applications/Xcode.app/Contents/Developer/Platforms/iPhoneSimulator.platform/Developer/SDKs/iPhoneSimulator13.5.sdk/System/Library/Frameworks/AudioToolbox.framework/Headers/AudioToolbox.apinotes /Applications/Xcode.app/Contents/Developer/Platforms/iPhoneSimulator.platform/Developer/SDKs/iPhoneSimulator13.5.sdk/System/Library/Frameworks/Security.framework/Headers/Security.apinotes
/Users/freebird/Desktop/Work/wokinprogress/Bump/Bump/build/Bump.build/Debug-iphonesimulator/Bump.build/Objects-normal/x86_64/SwitchCell~partial.swiftsourceinfo : /Users/freebird/Desktop/Work/wokinprogress/Bump/Bump/Bump/ViewController/CameraVC.swift /Users/freebird/Desktop/Work/wokinprogress/Bump/Bump/Bump/ViewController/NameVC.swift /Users/freebird/Desktop/Work/wokinprogress/Bump/Bump/Bump/ViewController/HomeVC.swift /Users/freebird/Desktop/Work/wokinprogress/Bump/Bump/Bump/ViewController/ShareVC.swift /Users/freebird/Desktop/Work/wokinprogress/Bump/Bump/Bump/ViewController/PurchaseVC.swift /Users/freebird/Desktop/Work/wokinprogress/Bump/Bump/Bump/ViewController/Setting/SettingVC.swift /Users/freebird/Desktop/Work/wokinprogress/Bump/Bump/Bump/ViewController/AccountDetailVC.swift /Users/freebird/Desktop/Work/wokinprogress/Bump/Bump/Bump/ViewController/ConfirmVC.swift /Users/freebird/Desktop/Work/wokinprogress/Bump/Bump/Bump/ViewController/SignVC.swift /Users/freebird/Desktop/Work/wokinprogress/Bump/Bump/Bump/ViewController/Notification/BumpVC.swift /Users/freebird/Desktop/Work/wokinprogress/Bump/Bump/Bump/ViewController/GenderVC.swift /Users/freebird/Desktop/Work/wokinprogress/Bump/Bump/Bump/ViewController/PhotoFilterVC.swift /Users/freebird/Desktop/Work/wokinprogress/Bump/Bump/Bump/ViewController/TermsVC.swift /Users/freebird/Desktop/Work/wokinprogress/Bump/Bump/Bump/ViewController/ContactVC.swift /Users/freebird/Desktop/Work/wokinprogress/Bump/Bump/Bump/ViewController/DeleteAccountVC.swift /Users/freebird/Desktop/Work/wokinprogress/Bump/Bump/Bump/ViewController/PrivacyPolicyVC.swift /Users/freebird/Desktop/Work/wokinprogress/Bump/Bump/Bump/SceneDelegate.swift /Users/freebird/Desktop/Work/wokinprogress/Bump/Bump/Bump/AppDelegate.swift /Users/freebird/Desktop/Work/wokinprogress/Bump/Bump/Bump/ViewController/Setting/DisclosureCell.swift /Users/freebird/Desktop/Work/wokinprogress/Bump/Bump/Bump/ViewController/Setting/SwitchCell.swift /Users/freebird/Desktop/Work/wokinprogress/Bump/Bump/Bump/ViewController/Notification/NotificationCell.swift /Users/freebird/Desktop/Work/wokinprogress/Bump/Bump/Bump/ViewController/Setting/ProfilePhotoCell.swift /Users/freebird/Desktop/Work/wokinprogress/Bump/Bump/Bump/ViewController/Setting/DeleteAccountCell.swift /Users/freebird/Desktop/Work/wokinprogress/Bump/Bump/Bump/ViewController/ImageCollectionViewCell.swift /Users/freebird/Desktop/Work/wokinprogress/Bump/Bump/Bump/ViewController/UICollectionViewPagingFlowLayout.swift /Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/lib/swift/iphonesimulator/prebuilt-modules/ObjectiveC.swiftmodule/x86_64.swiftmodule /Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/lib/swift/iphonesimulator/prebuilt-modules/CoreMIDI.swiftmodule/x86_64.swiftmodule /Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/lib/swift/iphonesimulator/prebuilt-modules/CoreMedia.swiftmodule/x86_64.swiftmodule /Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/lib/swift/iphonesimulator/prebuilt-modules/simd.swiftmodule/x86_64.swiftmodule /Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/lib/swift/iphonesimulator/prebuilt-modules/CoreImage.swiftmodule/x86_64.swiftmodule /Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/lib/swift/iphonesimulator/prebuilt-modules/QuartzCore.swiftmodule/x86_64.swiftmodule /Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/lib/swift/iphonesimulator/prebuilt-modules/Dispatch.swiftmodule/x86_64.swiftmodule /Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/lib/swift/iphonesimulator/prebuilt-modules/Metal.swiftmodule/x86_64.swiftmodule /Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/lib/swift/iphonesimulator/prebuilt-modules/Darwin.swiftmodule/x86_64.swiftmodule /Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/lib/swift/iphonesimulator/prebuilt-modules/Foundation.swiftmodule/x86_64.swiftmodule /Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/lib/swift/iphonesimulator/prebuilt-modules/AVFoundation.swiftmodule/x86_64.swiftmodule /Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/lib/swift/iphonesimulator/prebuilt-modules/CoreFoundation.swiftmodule/x86_64.swiftmodule /Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/lib/swift/iphonesimulator/prebuilt-modules/CoreAudio.swiftmodule/x86_64.swiftmodule /Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/lib/swift/iphonesimulator/prebuilt-modules/CoreGraphics.swiftmodule/x86_64.swiftmodule /Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/lib/swift/iphonesimulator/prebuilt-modules/Swift.swiftmodule/x86_64.swiftmodule /Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/lib/swift/iphonesimulator/prebuilt-modules/UIKit.swiftmodule/x86_64.swiftmodule /Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/lib/swift/iphonesimulator/prebuilt-modules/SwiftOnoneSupport.swiftmodule/x86_64.swiftmodule /Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/lib/swift/iphonesimulator/prebuilt-modules/Combine.swiftmodule/x86_64-apple-ios-simulator.swiftmodule /Users/freebird/Desktop/Work/wokinprogress/Bump/Bump/build/Debug-iphonesimulator/Gemini/Gemini.framework/Modules/Gemini.swiftmodule/x86_64-apple-ios-simulator.swiftmodule /Users/freebird/Desktop/Work/wokinprogress/Bump/Bump/build/Debug-iphonesimulator/KeyboardObserver/KeyboardObserver.framework/Modules/KeyboardObserver.swiftmodule/x86_64-apple-ios-simulator.swiftmodule /Users/freebird/Desktop/Work/wokinprogress/Bump/Bump/build/Debug-iphonesimulator/Gemini/Gemini.framework/Headers/Gemini-umbrella.h /Users/freebird/Desktop/Work/wokinprogress/Bump/Bump/build/Debug-iphonesimulator/KeyboardObserver/KeyboardObserver.framework/Headers/KeyboardObserver-umbrella.h /Users/freebird/Desktop/Work/wokinprogress/Bump/Bump/build/Debug-iphonesimulator/Gemini/Gemini.framework/Headers/Gemini-Swift.h /Users/freebird/Desktop/Work/wokinprogress/Bump/Bump/build/Debug-iphonesimulator/KeyboardObserver/KeyboardObserver.framework/Headers/KeyboardObserver-Swift.h /Users/freebird/Desktop/Work/wokinprogress/Bump/Bump/build/Debug-iphonesimulator/Gemini/Gemini.framework/Modules/module.modulemap /Users/freebird/Desktop/Work/wokinprogress/Bump/Bump/build/Debug-iphonesimulator/KeyboardObserver/KeyboardObserver.framework/Modules/module.modulemap /Applications/Xcode.app/Contents/Developer/Platforms/iPhoneSimulator.platform/Developer/SDKs/iPhoneSimulator13.5.sdk/usr/include/objc/ObjectiveC.apinotes /Applications/Xcode.app/Contents/Developer/Platforms/iPhoneSimulator.platform/Developer/SDKs/iPhoneSimulator13.5.sdk/System/Library/Frameworks/OpenGLES.framework/Headers/OpenGLES.apinotes /Applications/Xcode.app/Contents/Developer/Platforms/iPhoneSimulator.platform/Developer/SDKs/iPhoneSimulator13.5.sdk/System/Library/Frameworks/CoreMedia.framework/Headers/CoreMedia.apinotes /Applications/Xcode.app/Contents/Developer/Platforms/iPhoneSimulator.platform/Developer/SDKs/iPhoneSimulator13.5.sdk/System/Library/Frameworks/CoreImage.framework/Headers/CoreImage.apinotes /Applications/Xcode.app/Contents/Developer/Platforms/iPhoneSimulator.platform/Developer/SDKs/iPhoneSimulator13.5.sdk/System/Library/Frameworks/QuartzCore.framework/Headers/QuartzCore.apinotes /Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/lib/swift/apinotes/Dispatch.apinotes /Applications/Xcode.app/Contents/Developer/Platforms/iPhoneSimulator.platform/Developer/SDKs/iPhoneSimulator13.5.sdk/System/Library/Frameworks/Metal.framework/Headers/Metal.apinotes /Applications/Xcode.app/Contents/Developer/Platforms/iPhoneSimulator.platform/Developer/SDKs/iPhoneSimulator13.5.sdk/usr/include/Darwin.apinotes /Applications/Xcode.app/Contents/Developer/Platforms/iPhoneSimulator.platform/Developer/SDKs/iPhoneSimulator13.5.sdk/System/Library/Frameworks/Foundation.framework/Headers/Foundation.apinotes /Applications/Xcode.app/Contents/Developer/Platforms/iPhoneSimulator.platform/Developer/SDKs/iPhoneSimulator13.5.sdk/System/Library/Frameworks/AVFoundation.framework/Headers/AVFoundation.apinotes /Applications/Xcode.app/Contents/Developer/Platforms/iPhoneSimulator.platform/Developer/SDKs/iPhoneSimulator13.5.sdk/System/Library/Frameworks/CoreGraphics.framework/Headers/CoreGraphics.apinotes /Applications/Xcode.app/Contents/Developer/Platforms/iPhoneSimulator.platform/Developer/SDKs/iPhoneSimulator13.5.sdk/System/Library/Frameworks/CoreAudioTypes.framework/Headers/CoreAudioTypes.apinotes /Applications/Xcode.app/Contents/Developer/Platforms/iPhoneSimulator.platform/Developer/SDKs/iPhoneSimulator13.5.sdk/System/Library/Frameworks/UserNotifications.framework/Headers/UserNotifications.apinotes /Applications/Xcode.app/Contents/Developer/Platforms/iPhoneSimulator.platform/Developer/SDKs/iPhoneSimulator13.5.sdk/System/Library/Frameworks/UIKit.framework/Headers/UIKit.apinotes /Applications/Xcode.app/Contents/Developer/Platforms/iPhoneSimulator.platform/Developer/SDKs/iPhoneSimulator13.5.sdk/System/Library/Frameworks/WebKit.framework/Headers/WebKit.apinotes /Applications/Xcode.app/Contents/Developer/Platforms/iPhoneSimulator.platform/Developer/SDKs/iPhoneSimulator13.5.sdk/System/Library/Frameworks/CoreText.framework/Headers/CoreText.apinotes /Applications/Xcode.app/Contents/Developer/Platforms/iPhoneSimulator.platform/Developer/SDKs/iPhoneSimulator13.5.sdk/System/Library/Frameworks/MediaToolbox.framework/Headers/MediaToolbox.apinotes /Applications/Xcode.app/Contents/Developer/Platforms/iPhoneSimulator.platform/Developer/SDKs/iPhoneSimulator13.5.sdk/System/Library/Frameworks/AudioToolbox.framework/Headers/AudioToolbox.apinotes /Applications/Xcode.app/Contents/Developer/Platforms/iPhoneSimulator.platform/Developer/SDKs/iPhoneSimulator13.5.sdk/System/Library/Frameworks/Security.framework/Headers/Security.apinotes
| D |
import std.stdio;
import hunt.entity;
import model.UserInfo;
import model.UserApp;
import model.AppInfo;
import model.Car;
import model.IDCard;
import model.LoginInfo;
import hunt.logging;
import std.traits;
import std.format;
import std.array;
import core.stdc.stdlib;
import core.runtime;
import std.conv;
import hunt.database;
enum DO_TEST = `
logInfo("BEGIN ----------------" ~ __FUNCTION__ ~ "--------------------");
scope(success) logInfo("END ----------------" ~ __FUNCTION__ ~ "----------OK----------");
scope(failure) logError("END ----------------" ~ __FUNCTION__ ~ "----------FAIL----------");`;
void test_persist(EntityManager em)
{
mixin(DO_TEST);
UserInfo user = new UserInfo();
user.nickName = "Jame\"s Ha'Deng";
user.age = 30;
em.persist(user);
}
void test_merge(EntityManager em)
{
mixin(DO_TEST);
auto u = em.find!(UserInfo)(1);
u.age = 100;
em.merge!(UserInfo)(u);
}
void test_CriteriaQuery(EntityManager em)
{
mixin(DO_TEST);
CriteriaBuilder builder = em.getCriteriaBuilder();
CriteriaQuery!UserInfo criteriaQuery = builder.createQuery!(UserInfo);
Root!UserInfo root = criteriaQuery.from();
string name = "tom";
Predicate c1 = builder.equal(root.UserInfo.nickName, name);
Predicate c2 = builder.gt(root.UserInfo.age, 0);
criteriaQuery.orderBy(builder.asc(root.UserInfo.age), builder.asc(root.UserInfo.id));
TypedQuery!UserInfo typedQuery = em.createQuery(criteriaQuery.select(root)
.where(builder.or(c1, c2)));
auto uinfos = typedQuery.getResultList();
foreach (u; uinfos)
{
logDebug("Uinfo( %s , %s , %s ) ".format(u.id, u.nickName, u.age));
}
}
void test_comparison(EntityManager em)
{
mixin(DO_TEST);
auto rep = new EntityRepository!(UserInfo, int)(em);
string name = "Ha'Deng";
auto uinfos = rep.findAll(new Expr().eq("nickname", name));
foreach (u; uinfos)
{
logDebug("Uinfo( %s , %s , %s ) ".format(u.id, u.nickName, u.age));
}
}
void test_delete(EntityManager em)
{
mixin(DO_TEST);
CriteriaBuilder builder = em.getCriteriaBuilder();
CriteriaDelete!UserInfo criteriaDelete = builder.createCriteriaDelete!(UserInfo);
Root!UserInfo root = criteriaDelete.from();
string name = "Jame\"s Ha'Deng";
Predicate c1 = builder.equal(root.UserInfo.nickName, name);
Query!UserInfo query = em.createQuery(criteriaDelete.where(c1));
auto res = query.executeUpdate();
logDebug("exec delete : ", res);
}
void test_nativeQuery(EntityManager em)
{
mixin(DO_TEST);
auto nativeQuery = em.createNativeQuery(" select * from UserInfo;");
logDebug("nativeQuery ResultSet : ", nativeQuery.getResultList());
}
void test_create_eql_by_queryBuilder(EntityManager em)
{
mixin(DO_TEST);
auto queryBuider = new QueryBuilder(em.getDatabase());
queryBuider.from("UserInfo", "u");
queryBuider.select("u");
queryBuider.where(" u.id > :id").setParameter("id", 4);
queryBuider.orderBy("u.id desc");
assert("SELECT u\n" ~ "FROM UserInfo u\n" ~ "WHERE u.id > 4\n"
~ "ORDER BY u.id DESC" == queryBuider.toString);
}
void test_OneToOne(EntityManager em)
{
mixin(DO_TEST);
auto uinfo = em.find!(UserInfo)(1);
logDebug("Uinfo.IDCard is Lazy load : %s ".format(uinfo.card));
auto card = uinfo.getCard;
logDebug("Card( %s , %s ) ".format(card.id, card.desc));
auto card2 = em.find!(IDCard)(1);
logDebug("Uinfo( %s , %s ) ".format(card2.user.id, card2.user.nickName));
}
void test_OneToMany(EntityManager em)
{
mixin(DO_TEST);
auto uinfo = em.find!(UserInfo)(1);
auto cars = uinfo.getCars();
foreach (car; cars)
{
logDebug("Car( %s , %s ) ".format(car.id, car.name));
}
}
void test_ManyToOne(EntityManager em)
{
mixin(DO_TEST);
auto car = em.find!(Car)(2);
logDebug("Uinfo( %s , %s , %s ) ".format(car.user.id, car.user.nickName, car.user.age));
}
void test_ManyToMany(EntityManager em)
{
mixin(DO_TEST);
auto app = em.find!(AppInfo)(1);
auto uinfos = app.getUinfos();
logDebug("AppInfo( %s , %s , %s ) ".format(app.id, app.name, app.desc));
foreach (uinfo; uinfos)
logDebug("AppInfo.UserInfo( %s , %s , %s ) ".format(uinfo.id, uinfo.nickName, uinfo.age));
auto uinfo = em.find!(UserInfo)(1);
auto apps = uinfo.getApps();
logDebug("UserInfo( %s , %s , %s) ".format(uinfo.id, uinfo.nickName, uinfo.age));
foreach (app2; apps)
logDebug("UserInfo.AppInfo( %s , %s , %s ) ".format(app2.id, app2.name, app2.desc));
}
void test_eql_select(EntityManager em)
{
mixin(DO_TEST);
auto query1 = em.createQuery!(UserInfo)(
" select a from UserInfo a where a.nickName = :name ;");
// FIXME: Needing refactor or cleanup -@zhangxueping at 4/11/2019, 5:21:44 PM
//
// query1.setParameter("name", "tom's");
query1.setParameter("name", "toms");
foreach (d; query1.getResultList())
{
logDebug("UserInfo( %s , %s , %s ) ".format(d.id, d.nickName, d.age));
}
auto query2 = em.createQuery!(LoginInfo)(
" select a,b from LoginInfo a left join a.uinfo b ;");
foreach (d; query2.getResultList())
{
logDebug("LoginInfo.UserInfo( %s , %s , %s ) ".format(d.uinfo.id,
d.uinfo.nickName, d.uinfo.age));
logDebug("LoginInfo( %s , %s , %s ) ".format(d.id, d.create_time, d.update_time));
}
auto query3 = em.createQuery!(LoginInfo)(" select b from LoginInfo a left join a.uinfo b ;");
foreach (d; query3.getResultList())
{
logDebug("LoginInfo.UserInfo( %s , %s , %s ) ".format(d.uinfo.id,
d.uinfo.nickName, d.uinfo.age));
}
auto query4 = em.createQuery!(LoginInfo)(" select a.id, a.create_time ,b.nickName from LoginInfo a left join a.uinfo b where a.id in (? , ? ) order by a.id desc LIMIT 1 OFFSET 1 ;");
query4.setParameter(1, 2).setParameter(2, 1);
foreach (d; query4.getResultList())
{
logDebug("Mixed Results( %s , %s , %s ) ".format(d.id, d.create_time, d.uinfo.nickName));
}
auto query5 = em.createQuery!(LoginInfo)(
" select a, b ,c from LoginInfo a left join a.uinfo b join a.app c where a.id = 2 order by a.id desc;");
query5.setParameter(1, 2);
foreach (d; query5.getResultList())
{
logDebug("LoginInfo.UserInfo( %s , %s , %s ) ".format(d.uinfo.id,
d.uinfo.nickName, d.uinfo.age));
logDebug("LoginInfo.AppInfo( %s , %s , %s ) ".format(d.app.id, d.app.name, d.app.desc));
logDebug("LoginInfo( %s , %s , %s ) ".format(d.id, d.create_time, d.update_time));
}
auto query6 = em.createQuery!(UserInfo,
AppInfo)(" select a , b from UserInfo a left join AppInfo b on a.id = b.id ;");
foreach (d; query6.getResultList())
{
logDebug("UserInfo( %s , %s , %s ) ".format(d.id, d.nickName, d.age));
}
auto query7 = em.createQuery!(UserInfo)(
" select a.nickName as name ,count(*) as num from UserInfo a group by a.nickName;");
logDebug("UserInfo( %s ) ".format(query7.getNativeResult()));
auto query8 = em.createQuery!(IDCard)(
" select distinct b from IDCard a join a.user b where b.id = 2;");
foreach (d; query8.getResultList())
{
logDebug("IDCard.UserInfo( %s , %s , %s ) ".format(d.user.id, d.user.nickName, d.user.age));
}
}
void test_statement(EntityManager em)
{
mixin(DO_TEST);
auto db = em.getDatabase();
Statement statement = db.prepare(
`INSERT INTO users ( age , email, first_name, last_name) VALUES ( :age, :email, :firstName, :lastName )`);
statement.setParameter(`age`, 16);
statement.setParameter(`email`, "me@example.com");
statement.setParameter(`firstName`, "John");
statement.setParameter(`lastName`, "Doe");
assert("INSERT INTO users ( age , email, first_name, last_name) VALUES ( 16, 'me@example.com', 'John', 'Doe' )"
== statement.sql);
}
void test_pagination(EntityManager em)
{
mixin(DO_TEST);
auto query = em.createQuery!(UserInfo)(" select a from UserInfo a where a.age > :age order by a.id ",
new Pageable(0, 2)).setParameter("age", 10);
auto page = query.getPageResult();
logDebug("UserInfo -- Page(PageNo : %s ,size of Page : %s ,Total Pages: %s,Total : %s)".format(page.getNumber(),
page.getSize(), page.getTotalPages(), page.getTotalElements()));
foreach (d; page.getContent())
{
logDebug("UserInfo( %s , %s , %s ) ".format(d.id, d.nickName, d.age));
}
}
void test_pagination_1(EntityManager em)
{
mixin(DO_TEST);
auto query = em.createQuery!(UserInfo)(" select a from UserInfo a ")
.setFirstResult(1).setMaxResults(2);
foreach (d; query.getResultList())
{
logDebug("UserInfo( %s , %s , %s ) ".format(d.id, d.nickName, d.age));
}
}
void test_count(EntityManager em)
{
mixin(DO_TEST);
auto query = em.createQuery!(UserInfo)(" select count(UserInfo.id) as num from UserInfo a ");
logDebug("UserInfo( %s ) ".format(query.getNativeResult()));
}
void test_eql_insert(EntityManager em)
{
mixin(DO_TEST);
/// insert statement
auto insert = em.createQuery!(UserInfo)(
" INSERT INTO UserInfo u(u.nickName,u.age) values (:name,:age)");
insert.setParameter("name", "momomo");
insert.setParameter("age", 666);
logDebug(" insert result : ", insert.exec());
}
void test_eql_insert2(EntityManager em)
{
mixin(DO_TEST);
/// insert statement
auto insert = em.createQuery!(UserInfo)(
" INSERT INTO UserInfo u(u.nickName,u.age) values (?,?)");
insert.setParameter(1, "Jons");
insert.setParameter(2, 2355);
logDebug(" insert result : ", insert.exec());
}
void test_eql_update(EntityManager em)
{
mixin(DO_TEST);
import std.random;
/// update statement
auto sql = em.createQuery!(UserInfo)(
" UPDATE UserInfo u set u.nickName = ?, u.age = ? WHERE u.id = ?");
sql.setParameter(1, "Jons");
sql.setParameter(2, uniform(1, 100));
sql.setParameter(3, 1);
// int a = sql.exec();
trace(" Update result : ", sql.exec());
}
void test_eql_delete(EntityManager em)
{
mixin(DO_TEST);
/// del statement
auto del = em.createQuery!(UserInfo)(" DELETE FROM UserInfo u where u.nickName = ?");
del.setParameter(1, "momomo");
logDebug(" del result : ", del.exec());
}
void test_eql_function_DISTINCT(EntityManager em)
{
mixin(DO_TEST);
/// func statement
auto sql = em.createQuery!(UserInfo)(
"SELECT DISTINCT(u.nickName) as nickname FROM UserInfo u");
ResultSet rs = sql.getNativeResult();
if (rs is null || rs.empty()) {
warning("no return");
} else {
// Row r = rs.front;
// int count = r.getAs!int(0);
// tracef("count: %s", count);
}
}
void test_eql_function_count(EntityManager em)
{
mixin(DO_TEST);
/// delete statement
auto sql = em.createQuery!(UserInfo)("SELECT COUNT(u.nickName) FROM UserInfo u ");
ResultSet rs = sql.getNativeResult();
if (rs is null || rs.empty()) {
warning("no return");
} else {
Row r = rs.front;
int count = r.getAs!int(0);
tracef("count: %s", count);
}
}
void main()
{
EntityOption option = new EntityOption();
option.database.driver = "postgresql";
option.database.host = "10.1.11.34";
option.database.port = 5432;
option.database.database = "exampledb";
option.database.username = "postgres";
option.database.password = "123456";
EntityManagerFactory entityManagerFactory = Persistence.createEntityManagerFactory(
"postgresql", option);
EntityManager em = entityManagerFactory.createEntityManager();
CriteriaBuilder builder = em.getCriteriaBuilder();
test_OneToOne(em);
test_OneToMany(em);
test_ManyToOne(em);
test_ManyToMany(em);
test_merge(em);
test_persist(em);
test_comparison(em);
test_delete(em);
test_CriteriaQuery(em);
test_nativeQuery(em);
test_create_eql_by_queryBuilder(em);
test_statement(em);
test_pagination(em);
test_pagination_1(em);
test_eql_select(em);
test_eql_insert(em);
test_eql_insert2(em);
test_eql_update(em);
test_eql_delete(em);
test_eql_function_count(em);
test_eql_function_DISTINCT(em);
getchar();
}
| D |
// D import file generated from 'sqlite3\sqlite3.d'
module sqlite3.sqlite3;
extern (C)
{
version (Tango)
{
import tango.stdc.stdarg;
import tango.stdc.inttypes;
}
else
{
import std.c.stdarg;
import std.stdint;
}
version (build)
{
pragma (link, "sqlite3");
}
const char[] SQLITE_VERSION = "3.5.1";
const SQLITE_VERSION_NUMBER = 3005001;
char* sqlite3_version;
char* sqlite3_libversion();
int sqlite3_libversion_number();
int sqlite3_threadsafe();
struct sqlite3;
alias int64_t sqlite3_int64;
alias uint64_t sqlite3_uint64;
int sqlite3_close(sqlite3*);
alias int function(void*, int, char**, char**) sqlite3_callback;
int sqlite3_exec(sqlite3*, char* sql, int function(void*, int, char**, char**) callback, void*, char** errmsg);
const SQLITE_OK = 0;
const SQLITE_ERROR = 1;
const SQLITE_INTERNAL = 2;
const SQLITE_PERM = 3;
const SQLITE_ABORT = 4;
const SQLITE_BUSY = 5;
const SQLITE_LOCKED = 6;
const SQLITE_NOMEM = 7;
const SQLITE_READONLY = 8;
const SQLITE_INTERRUPT = 9;
const SQLITE_IOERR = 10;
const SQLITE_CORRUPT = 11;
const SQLITE_NOTFOUND = 12;
const SQLITE_FULL = 13;
const SQLITE_CANTOPEN = 14;
const SQLITE_PROTOCOL = 15;
const SQLITE_EMPTY = 16;
const SQLITE_SCHEMA = 17;
const SQLITE_TOOBIG = 18;
const SQLITE_CONSTRAINT = 19;
const SQLITE_MISMATCH = 20;
const SQLITE_MISUSE = 21;
const SQLITE_NOLFS = 22;
const SQLITE_AUTH = 23;
const SQLITE_FORMAT = 24;
const SQLITE_RANGE = 25;
const SQLITE_NOTADB = 26;
const SQLITE_ROW = 100;
const SQLITE_DONE = 101;
const SQLITE_IOERR_READ = SQLITE_IOERR | 1 << 8;
const SQLITE_IOERR_SHORT_READ = SQLITE_IOERR | 2 << 8;
const SQLITE_IOERR_WRITE = SQLITE_IOERR | 3 << 8;
const SQLITE_IOERR_FSYNC = SQLITE_IOERR | 4 << 8;
const SQLITE_IOERR_DIR_FSYNC = SQLITE_IOERR | 5 << 8;
const SQLITE_IOERR_TRUNCATE = SQLITE_IOERR | 6 << 8;
const SQLITE_IOERR_FSTAT = SQLITE_IOERR | 7 << 8;
const SQLITE_IOERR_UNLOCK = SQLITE_IOERR | 8 << 8;
const SQLITE_IOERR_RDLOCK = SQLITE_IOERR | 9 << 8;
const SQLITE_IOERR_DELETE = SQLITE_IOERR | 10 << 8;
const SQLITE_IOERR_BLOCKED = SQLITE_IOERR | 11 << 8;
const SQLITE_IOERR_NOMEM = SQLITE_IOERR | 12 << 8;
const SQLITE_OPEN_READONLY = 1;
const SQLITE_OPEN_READWRITE = 2;
const SQLITE_OPEN_CREATE = 4;
const SQLITE_OPEN_DELETEONCLOSE = 8;
const SQLITE_OPEN_EXCLUSIVE = 16;
const SQLITE_OPEN_MAIN_DB = 256;
const SQLITE_OPEN_TEMP_DB = 512;
const SQLITE_OPEN_TRANSIENT_DB = 1024;
const SQLITE_OPEN_MAIN_JOURNAL = 2048;
const SQLITE_OPEN_TEMP_JOURNAL = 4096;
const SQLITE_OPEN_SUBJOURNAL = 8192;
const SQLITE_OPEN_MASTER_JOURNAL = 16384;
const SQLITE_IOCAP_ATOMIC = 1;
const SQLITE_IOCAP_ATOMIC512 = 2;
const SQLITE_IOCAP_ATOMIC1K = 4;
const SQLITE_IOCAP_ATOMIC2K = 8;
const SQLITE_IOCAP_ATOMIC4K = 16;
const SQLITE_IOCAP_ATOMIC8K = 32;
const SQLITE_IOCAP_ATOMIC16K = 64;
const SQLITE_IOCAP_ATOMIC32K = 128;
const SQLITE_IOCAP_ATOMIC64K = 256;
const SQLITE_IOCAP_SAFE_APPEND = 512;
const SQLITE_IOCAP_SEQUENTIAL = 1024;
const SQLITE_LOCK_NONE = 0;
const SQLITE_LOCK_SHARED = 1;
const SQLITE_LOCK_RESERVED = 2;
const SQLITE_LOCK_PENDING = 3;
const SQLITE_LOCK_EXCLUSIVE = 4;
const SQLITE_SYNC_NORMAL = 2;
const SQLITE_SYNC_FULL = 3;
const SQLITE_SYNC_DATAONLY = 16;
struct sqlite3_file
{
sqlite3_io_methods* pMethods;
}
struct sqlite3_io_methods
{
int iVersion;
int function(sqlite3_file*) xClose;
int function(sqlite3_file*, void*, int iAmt, sqlite3_int64 iOfst) xRead;
int function(sqlite3_file*, void*, int iAmt, sqlite3_int64 iOfst) xWrite;
int function(sqlite3_file*, sqlite3_int64 size) xTruncate;
int function(sqlite3_file*, int flags) xSync;
int function(sqlite3_file*, sqlite3_int64* pSize) xFileSize;
int function(sqlite3_file*, int) xLock;
int function(sqlite3_file*, int) xUnlock;
int function(sqlite3_file*) xCheckReservedLock;
int function(sqlite3_file*, int op, void* pArg) xFileControl;
int function(sqlite3_file*) xSectorSize;
int function(sqlite3_file*) xDeviceCharacteristics;
}
const SQLITE_FCNTL_LOCKSTATE = 1;
struct sqlite3_mutex;
struct sqlite3_vfs
{
int iVersion;
int szOsFile;
int mxPathname;
sqlite3_vfs* pNext;
char* zName;
void* pAppData;
int function(sqlite3_vfs*, char* zName, sqlite3_file*, int flags, int* pOutFlags) xOpen;
int function(sqlite3_vfs*, char* zName, int syncDir) xDelete;
int function(sqlite3_vfs*, char* zName, int flags) xAccess;
int function(sqlite3_vfs*, int nOut, char* zOut) xGetTempName;
int function(sqlite3_vfs*, char* zName, int nOut, char* zOut) xFullPathname;
void* function(sqlite3_vfs*, char* zFileName) xDlOpen;
void* function(sqlite3_vfs*, int nByte, char* zErrMsg) xDlError;
void* function(sqlite3_vfs*, void*, char* zSymbol) xDlSym;
void function(sqlite3_vfs*, void*) xDlClose;
int function(sqlite3_vfs*, int nByte, char* zOut) xRandomness;
int function(sqlite3_vfs*, int microseconds) xSleep;
int function(sqlite3_vfs, double*) xCurrentTime;
}
const SQLITE_ACCESS_EXISTS = 0;
const SQLITE_ACCESS_READWRITE = 1;
const SQLITE_ACCESS_READ = 2;
int sqlite3_extended_result_codes(sqlite3*, int onoff);
sqlite3_int64 sqlite3_last_insert_rowid(sqlite3*);
int sqlite3_changes(sqlite3*);
int sqlite3_total_changes(sqlite3*);
void sqlite3_interrupt(sqlite3*);
int sqlite3_complete(char* sql);
int sqlite3_complete16(void* sql);
int sqlite3_busy_handler(sqlite3*, int function(void*, int), void*);
int sqlite3_busy_timeout(sqlite3*, int ms);
int sqlite3_get_table(sqlite3*, char* sql, char*** resultp, int* nrow, int* ncolumn, char** errmsg);
void sqlite3_free_table(char** result);
char* sqlite3_mprintf(char*,...);
char* sqlite3_vmprintf(char*, va_list);
char* sqlite3_snprintf(int, char*, char*,...);
void* sqlite3_malloc(int);
void* sqlite3_realloc(void*, int);
void sqlite3_free(void*);
sqlite3_int64 sqlite3_memory_used();
sqlite3_int64 sqlite3_memory_highwater(int resetFlag);
int sqlite3_memory_alarm(void function(void* pArg, sqlite3_int64 used, int N) xCallback, void* pArg, sqlite3_int64 iThreshold);
int sqlite3_set_authorizer(sqlite3*, int function(void*, int, char*, char*, char*, char*) xAuth, void* pUserData);
const SQLITE_DENY = 1;
const SQLITE_IGNORE = 2;
const SQLITE_CREATE_INDEX = 1;
const SQLITE_CREATE_TABLE = 2;
const SQLITE_CREATE_TEMP_INDEX = 3;
const SQLITE_CREATE_TEMP_TABLE = 4;
const SQLITE_CREATE_TEMP_TRIGGER = 5;
const SQLITE_CREATE_TEMP_VIEW = 6;
const SQLITE_CREATE_TRIGGER = 7;
const SQLITE_CREATE_VIEW = 8;
const SQLITE_DELETE = 9;
const SQLITE_DROP_INDEX = 10;
const SQLITE_DROP_TABLE = 11;
const SQLITE_DROP_TEMP_INDEX = 12;
const SQLITE_DROP_TEMP_TABLE = 13;
const SQLITE_DROP_TEMP_TRIGGER = 14;
const SQLITE_DROP_TEMP_VIEW = 15;
const SQLITE_DROP_TRIGGER = 16;
const SQLITE_DROP_VIEW = 17;
const SQLITE_INSERT = 18;
const SQLITE_PRAGMA = 19;
const SQLITE_READ = 20;
const SQLITE_SELECT = 21;
const SQLITE_TRANSACTION = 22;
const SQLITE_UPDATE = 23;
const SQLITE_ATTACH = 24;
const SQLITE_DETACH = 25;
const SQLITE_ALTER_TABLE = 26;
const SQLITE_REINDEX = 27;
const SQLITE_ANALYZE = 28;
const SQLITE_CREATE_VTABLE = 29;
const SQLITE_DROP_VTABLE = 30;
const SQLITE_FUNCTION = 31;
const SQLITE_COPY = 0;
void* sqlite3_trace(sqlite3*, void function(void*, char*) xTrace, void*);
void* sqlite3_profile(sqlite3*, void function(void*, char*, sqlite3_uint64) xProfile, void*);
void sqlite3_progress_handler(sqlite3*, int, int function(void*), void*);
int sqlite3_open(char* filename, sqlite3** ppDb);
int sqlite3_open16(void* filename, sqlite3** ppDb);
int sqlite3_open_v2(char* filename, sqlite3** ppDb, int flags, char* zVfs);
int sqlite3_errcode(sqlite3* db);
char* sqlite3_errmsg(sqlite3*);
void* sqlite3_errmsg16(sqlite3*);
struct sqlite3_stmt;
int sqlite3_prepare(sqlite3* db, char* zSql, int nByte, sqlite3_stmt** ppStmt, char** pzTail);
int sqlite3_prepare_v2(sqlite3* db, char* zSql, int nByte, sqlite3_stmt** ppStmt, char** pzTail);
int sqlite3_prepare16(sqlite3* db, void* zSql, int nByte, sqlite3_stmt** ppStmt, void** pzTail);
int sqlite3_prepare16_v2(sqlite3* db, void* zSql, int nByte, sqlite3_stmt** ppStmt, void** pzTail);
struct sqlite3_value;
struct sqlite3_context;
int sqlite3_bind_blob(sqlite3_stmt*, int, void*, int n, void function(void*));
int sqlite3_bind_double(sqlite3_stmt*, int, double);
int sqlite3_bind_int(sqlite3_stmt*, int, int);
int sqlite3_bind_int64(sqlite3_stmt*, int, sqlite3_int64);
int sqlite3_bind_null(sqlite3_stmt*, int);
int sqlite3_bind_text(sqlite3_stmt*, int, char*, int n, void function(void*));
int sqlite3_bind_text16(sqlite3_stmt*, int, void*, int, void function(void*));
int sqlite3_bind_value(sqlite3_stmt*, int, sqlite3_value*);
int sqlite3_bind_zeroblob(sqlite3_stmt*, int, int n);
int sqlite3_bind_parameter_count(sqlite3_stmt*);
char* sqlite3_bind_parameter_name(sqlite3_stmt*, int);
int sqlite3_bind_parameter_index(sqlite3_stmt*, char* zName);
int sqlite3_clear_bindings(sqlite3_stmt*);
int sqlite3_column_count(sqlite3_stmt* pStmt);
char* sqlite3_column_name(sqlite3_stmt*, int N);
void* sqlite3_column_name16(sqlite3_stmt*, int N);
char* sqlite3_column_database_name(sqlite3_stmt*, int);
void* sqlite3_column_database_name16(sqlite3_stmt*, int);
char* sqlite3_column_table_name(sqlite3_stmt*, int);
void* sqlite3_column_table_name16(sqlite3_stmt*, int);
char* sqlite3_column_origin_name(sqlite3_stmt*, int);
void* sqlite3_column_origin_name16(sqlite3_stmt*, int);
char* sqlite3_column_decltype(sqlite3_stmt*, int i);
void* sqlite3_column_decltype16(sqlite3_stmt*, int);
int sqlite3_step(sqlite3_stmt*);
int sqlite3_data_count(sqlite3_stmt* pStmt);
const SQLITE_INTEGER = 1;
const SQLITE_FLOAT = 2;
const SQLITE_BLOB = 4;
const SQLITE_NULL = 5;
const SQLITE_TEXT = 3;
const SQLITE3_TEXT = 3;
void* sqlite3_column_blob(sqlite3_stmt*, int iCol);
int sqlite3_column_bytes(sqlite3_stmt*, int iCol);
int sqlite3_column_bytes16(sqlite3_stmt*, int iCol);
double sqlite3_column_double(sqlite3_stmt*, int iCol);
int sqlite3_column_int(sqlite3_stmt*, int iCol);
sqlite3_int64 sqlite3_column_int64(sqlite3_stmt*, int iCol);
char* sqlite3_column_text(sqlite3_stmt*, int iCol);
void* sqlite3_column_text16(sqlite3_stmt*, int iCol);
int sqlite3_column_type(sqlite3_stmt*, int iCol);
sqlite3_value* sqlite3_column_value(sqlite3_stmt*, int iCol);
int sqlite3_finalize(sqlite3_stmt* pStmt);
int sqlite3_reset(sqlite3_stmt* pStmt);
int sqlite3_create_function(sqlite3*, char* zFunctionName, int nArg, int eTextRep, void*, void function(sqlite3_context*, int, sqlite3_value**) xFunc, void function(sqlite3_context*, int, sqlite3_value**) xStep, void function(sqlite3_context*) xFinal);
int sqlite3_create_function16(sqlite3*, void* zFunctionName, int nArg, int eTextRep, void*, void function(sqlite3_context*, int, sqlite3_value**) xFunc, void function(sqlite3_context*, int, sqlite3_value**) xStep, void function(sqlite3_context*) xFinal);
const SQLITE_UTF8 = 1;
const SQLITE_UTF16LE = 2;
const SQLITE_UTF16BE = 3;
const SQLITE_UTF16 = 4;
const SQLITE_ANY = 5;
const SQLITE_UTF16_ALIGNED = 8;
int sqlite3_aggregate_count(sqlite3_context*);
int sqlite3_expired(sqlite3_stmt*);
int sqlite3_transfer_bindings(sqlite3_stmt*, sqlite3_stmt*);
int sqlite3_global_recover();
void sqlite3_thread_cleanup();
void* sqlite3_value_blob(sqlite3_value*);
int sqlite3_value_bytes(sqlite3_value*);
int sqlite3_value_bytes16(sqlite3_value*);
double sqlite3_value_double(sqlite3_value*);
int sqlite3_value_int(sqlite3_value*);
sqlite3_int64 sqlite3_value_int64(sqlite3_value*);
char* sqlite3_value_text(sqlite3_value*);
void* sqlite3_value_text16(sqlite3_value*);
void* sqlite3_value_text16le(sqlite3_value*);
void* sqlite3_value_text16be(sqlite3_value*);
int sqlite3_value_type(sqlite3_value*);
int sqlite3_value_numeric_type(sqlite3_value*);
void* sqlite3_aggregate_context(sqlite3_context*, int nBytes);
void* sqlite3_user_data(sqlite3_context*);
void* sqlite3_get_auxdata(sqlite3_context*, int);
void sqlite3_set_auxdata(sqlite3_context*, int, void*, void function(void*));
alias void function(void*) sqlite3_destructor_type;
const SQLITE_STATIC = cast(sqlite3_destructor_type)0;
const SQLITE_TRANSIENT = cast(sqlite3_destructor_type)-1;
void sqlite3_result_blob(sqlite3_context*, void*, int, void function(void*));
void sqlite3_result_double(sqlite3_context*, double);
void sqlite3_result_error(sqlite3_context*, char*, int);
void sqlite3_result_error16(sqlite3_context*, void*, int);
void sqlite3_result_error_toobig(sqlite3_context*);
void sqlite3_result_error_nomem(sqlite3_context*);
void sqlite3_result_int(sqlite3_context*, int);
void sqlite3_result_int64(sqlite3_context*, sqlite3_int64);
void sqlite3_result_null(sqlite3_context*);
void sqlite3_result_text(sqlite3_context*, char*, int, void function(void*));
void sqlite3_result_text16(sqlite3_context*, void*, int, void function(void*));
void sqlite3_result_text16le(sqlite3_context*, void*, int, void function(void*));
void sqlite3_result_text16be(sqlite3_context*, void*, int, void function(void*));
void sqlite3_result_value(sqlite3_context*, sqlite3_value*);
void sqlite3_result_zeroblob(sqlite3_context*, int n);
int sqlite3_create_collation(sqlite3*, char* zName, int eTextRep, void*, int function(void*, int, void*, int, void*) xCompare);
int sqlite3_create_collation_v2(sqlite3*, char* zName, int eTextRep, void*, int function(void*, int, void*, int, void*) xCompare, void function(void*) xDestroy);
int sqlite3_create_collation16(sqlite3*, char* zName, int eTextRep, void*, int function(void*, int, void*, int, void*) xCompare);
int sqlite3_collation_needed(sqlite3*, void*, void function(void*, sqlite3*, int eTextRep, char*));
int sqlite3_collation_needed16(sqlite3*, void*, void function(void*, sqlite3*, int eTextRep, void*));
int sqlite3_key(sqlite3* db, void* pKey, int nKey);
int sqlite3_rekey(sqlite3* db, void* pKey, int nKey);
int sqlite3_sleep(int);
char* sqlite3_temp_directory;
int sqlite3_get_autocommit(sqlite3*);
sqlite3* sqlite3_db_handle(sqlite3_stmt*);
void* sqlite3_commit_hook(sqlite3*, int function(void*), void*);
void* sqlite3_rollback_hook(sqlite3*, void function(void*), void*);
void* sqlite3_update_hook(sqlite3*, void function(void*, int, char*, char*, sqlite3_int64), void*);
int sqlite3_enable_shared_cache(int);
int sqlite3_release_memory(int);
void sqlite3_soft_heap_limit(int);
int sqlite3_table_column_metadata(sqlite3* db, char* zDbName, char* zTableName, char* zColumnName, char** pzDataType, char** pzCollSeq, int* pNotNull, int* pPrimaryKey, int* pAutoinc);
int sqlite3_load_extension(sqlite3* db, char* zFile, char* zProc, char** pzErrMsg);
int sqlite3_enable_load_extension(sqlite3* db, int onoff);
int sqlite3_auto_extension(void* xEntryPoint);
void sqlite3_reset_auto_extension();
struct sqlite3_module
{
int iVersion;
int function(sqlite3*, void* pAux, int argc, char** argv, sqlite3_vtab** ppVTab, char**) xCreate;
int function(sqlite3*, void* pAux, int argc, char** argv, sqlite3_vtab** ppVTab, char**) xConnect;
int function(sqlite3_vtab* pVTab, sqlite3_index_info*) xBestIndex;
int function(sqlite3_vtab* pVTab) xDisconnect;
int function(sqlite3_vtab* pVTab) xDestroy;
int function(sqlite3_vtab* pVTab, sqlite3_vtab_cursor** ppCursor) xOpen;
int function(sqlite3_vtab_cursor*) xClose;
int function(sqlite3_vtab_cursor*, int idxNum, char* idxStr, int argc, sqlite3_value** argv) xFilter;
int function(sqlite3_vtab_cursor*) xNext;
int function(sqlite3_vtab_cursor*) xEof;
int function(sqlite3_vtab_cursor*, sqlite3_context*, int) xColumn;
int function(sqlite3_vtab_cursor*, sqlite3_int64* pRowid) xRowid;
int function(sqlite3_vtab*, int, sqlite3_value**, sqlite3_int64*) xUpdate;
int function(sqlite3_vtab* pVTab) xBegin;
int function(sqlite3_vtab* pVTab) xSync;
int function(sqlite3_vtab* pVTab) xCommit;
int function(sqlite3_vtab* pVTab) xRollback;
int function(sqlite3_vtab* pVtab, int nArg, char* zName, void function(sqlite3_context*, int, sqlite3_value**)* pxFunc, void** ppArg) xFindFunction;
int function(sqlite3_vtab* pVtab, char* zNew) xRename;
}
struct sqlite3_index_info
{
int nConstraint;
struct sqlite3_index_constraint
{
int iColumn;
ubyte op;
ubyte usable;
int iTermOffset;
}
sqlite3_index_constraint* aConstraint;
int nOrderBy;
struct sqlite3_index_orderby
{
int iColumn;
ubyte desc;
}
sqlite3_index_orderby* aOrderBy;
struct sqlite3_index_constraint_usage
{
int argvIndex;
ubyte omit;
}
sqlite3_index_constraint_usage* aConstraintUsage;
int idxNum;
char* idxStr;
int needToFreeIdxStr;
int orderByConsumed;
double estimatedCost;
}
const SQLITE_INDEX_CONSTRAINT_EQ = 2;
const SQLITE_INDEX_CONSTRAINT_GT = 4;
const SQLITE_INDEX_CONSTRAINT_LE = 8;
const SQLITE_INDEX_CONSTRAINT_LT = 16;
const SQLITE_INDEX_CONSTRAINT_GE = 32;
const SQLITE_INDEX_CONSTRAINT_MATCH = 64;
int sqlite3_create_module(sqlite3* db, char* zName, sqlite3_module*, void*);
int sqlite3_create_module_v2(sqlite3* db, char* zName, sqlite3_module*, void*, void function(void*) xDestroy);
struct sqlite3_vtab
{
sqlite3_module* pModule;
int nRef;
char* zErrMsg;
}
struct sqlite3_vtab_cursor
{
sqlite3_vtab* pVtab;
}
int sqlite3_declare_vtab(sqlite3*, char* zCreateTable);
int sqlite3_overload_function(sqlite3*, char* zFuncName, int nArg);
struct sqlite3_blob;
int sqlite3_blob_open(sqlite3*, char* zDb, char* zTable, char* zColumn, sqlite3_int64 iRow, int flags, sqlite3_blob** ppBlob);
int sqlite3_blob_close(sqlite3_blob*);
int sqlite3_blob_bytes(sqlite3_blob*);
int sqlite3_blob_read(sqlite3_blob*, void* z, int n, int iOffset);
int sqlite3_blob_write(sqlite3_blob*, void* z, int n, int iOffset);
sqlite3_vfs* sqlite3_vfs_find(char* zVfsName);
int sqlite3_vfs_register(sqlite3_vfs*, int makeDflt);
int sqlite3_vfs_unregister(sqlite3_vfs*);
sqlite3_mutex* sqlite3_mutex_alloc(int);
void sqlite3_mutex_free(sqlite3_mutex*);
void sqlite3_mutex_enter(sqlite3_mutex*);
int sqlite3_mutex_try(sqlite3_mutex*);
void sqlite3_mutex_leave(sqlite3_mutex*);
int sqlite3_mutex_held(sqlite3_mutex*);
int sqlite3_mutex_notheld(sqlite3_mutex*);
const SQLITE_MUTEX_FAST = 0;
const SQLITE_MUTEX_RECURSIVE = 1;
const SQLITE_MUTEX_STATIC_MASTER = 2;
const SQLITE_MUTEX_STATIC_MEM = 3;
const SQLITE_MUTEX_STATIC_MEM2 = 4;
const SQLITE_MUTEX_STATIC_PRNG = 5;
const SQLITE_MUTEX_STATIC_LRU = 6;
int sqlite3_file_control(sqlite3*, char* zDbName, int op, void*);
}
| D |
// Written in the D programming language.
/**
JavaScript Object Notation
Copyright: Copyright Jeremie Pelletier 2008 - 2009.
License: <a href="http://www.boost.org/LICENSE_1_0.txt">Boost License 1.0</a>.
Authors: Jeremie Pelletier, David Herberth
References: $(LINK http://json.org/)
Source: $(PHOBOSSRC std/_json.d)
*/
/*
Copyright Jeremie Pelletier 2008 - 2009.
Distributed under the Boost Software License, Version 1.0.
(See accompanying file LICENSE_1_0.txt or copy at
http://www.boost.org/LICENSE_1_0.txt)
*/
module std.json;
import std.ascii;
import std.conv;
import std.range;
import std.utf;
import std.traits;
import std.exception;
private
{
// Prevent conflicts from these generic names
alias UTFStride = std.utf.stride;
alias toUnicode = std.utf.decode;
}
/**
JSON type enumeration
*/
enum JSON_TYPE : byte
{
/// Indicates the type of a $(D JSONValue).
STRING,
INTEGER, /// ditto
UINTEGER,/// ditto
FLOAT, /// ditto
OBJECT, /// ditto
ARRAY, /// ditto
TRUE, /// ditto
FALSE, /// ditto
NULL /// ditto
}
/**
JSON value node
*/
struct JSONValue
{
union Store
{
string str;
long integer;
ulong uinteger;
double floating;
JSONValue[string] object;
JSONValue[] array;
}
private Store store;
private JSON_TYPE type_tag;
/// Specifies the _type of the value stored in this structure.
@property JSON_TYPE type() const
{
return type_tag;
}
/**
$(RED Deprecated. Instead, please assign the value with the adequate
type to $(D JSONValue) directly. This will be removed in
June 2015.)
Sets the _type of this $(D JSONValue). Previous content is cleared.
*/
deprecated("Please assign the value with the adequate type to JSONValue directly.")
@property JSON_TYPE type(JSON_TYPE newType)
{
if (type_tag != newType
&& ((type_tag != JSON_TYPE.INTEGER && type_tag != JSON_TYPE.UINTEGER)
|| (newType != JSON_TYPE.INTEGER && newType != JSON_TYPE.UINTEGER)))
{
final switch (newType)
{
case JSON_TYPE.STRING:
store.str = store.str.init;
break;
case JSON_TYPE.INTEGER:
store.integer = store.integer.init;
break;
case JSON_TYPE.UINTEGER:
store.uinteger = store.uinteger.init;
break;
case JSON_TYPE.FLOAT:
store.floating = store.floating.init;
break;
case JSON_TYPE.OBJECT:
store.object = store.object.init;
break;
case JSON_TYPE.ARRAY:
store.array = store.array.init;
break;
case JSON_TYPE.TRUE:
case JSON_TYPE.FALSE:
case JSON_TYPE.NULL:
break;
}
}
return type_tag = newType;
}
/// Value getter/setter for $(D JSON_TYPE.STRING).
/// Throws $(D JSONException) for read access if $(D type) is not $(D JSON_TYPE.STRING).
@property inout(string) str() inout
{
enforce!JSONException(type == JSON_TYPE.STRING,
"JSONValue is not a string");
return store.str;
}
/// ditto
@property string str(string v)
{
assign(v);
return store.str;
}
/// Value getter/setter for $(D JSON_TYPE.INTEGER).
/// Throws $(D JSONException) for read access if $(D type) is not $(D JSON_TYPE.INTEGER).
@property inout(long) integer() inout
{
enforce!JSONException(type == JSON_TYPE.INTEGER,
"JSONValue is not an integer");
return store.integer;
}
/// ditto
@property long integer(long v)
{
assign(v);
return store.integer;
}
/// Value getter/setter for $(D JSON_TYPE.UINTEGER).
/// Throws $(D JSONException) for read access if $(D type) is not $(D JSON_TYPE.UINTEGER).
@property inout(ulong) uinteger() inout
{
enforce!JSONException(type == JSON_TYPE.UINTEGER,
"JSONValue is not an unsigned integer");
return store.uinteger;
}
/// ditto
@property ulong uinteger(ulong v)
{
assign(v);
return store.uinteger;
}
/// Value getter/setter for $(D JSON_TYPE.FLOAT).
/// Throws $(D JSONException) for read access if $(D type) is not $(D JSON_TYPE.FLOAT).
@property inout(double) floating() inout
{
enforce!JSONException(type == JSON_TYPE.FLOAT,
"JSONValue is not a floating type");
return store.floating;
}
/// ditto
@property double floating(double v)
{
assign(v);
return store.floating;
}
/// Value getter/setter for $(D JSON_TYPE.OBJECT).
/// Throws $(D JSONException) for read access if $(D type) is not $(D JSON_TYPE.OBJECT).
@property ref inout(JSONValue[string]) object() inout
{
enforce!JSONException(type == JSON_TYPE.OBJECT,
"JSONValue is not an object");
return store.object;
}
/// ditto
@property JSONValue[string] object(JSONValue[string] v)
{
assign(v);
return store.object;
}
/// Value getter/setter for $(D JSON_TYPE.ARRAY).
/// Throws $(D JSONException) for read access if $(D type) is not $(D JSON_TYPE.ARRAY).
@property ref inout(JSONValue[]) array() inout
{
enforce!JSONException(type == JSON_TYPE.ARRAY,
"JSONValue is not an array");
return store.array;
}
/// ditto
@property JSONValue[] array(JSONValue[] v)
{
assign(v);
return store.array;
}
private void assign(T)(T arg)
{
static if(is(T : typeof(null)))
{
type_tag = JSON_TYPE.NULL;
}
else static if(is(T : string))
{
type_tag = JSON_TYPE.STRING;
store.str = arg;
}
else static if(is(T : bool))
{
type_tag = arg ? JSON_TYPE.TRUE : JSON_TYPE.FALSE;
}
else static if(is(T : ulong) && isUnsigned!T)
{
type_tag = JSON_TYPE.UINTEGER;
store.uinteger = arg;
}
else static if(is(T : long))
{
type_tag = JSON_TYPE.INTEGER;
store.integer = arg;
}
else static if(isFloatingPoint!T)
{
type_tag = JSON_TYPE.FLOAT;
store.floating = arg;
}
else static if(is(T : Value[Key], Key, Value))
{
static assert(is(Key : string), "AA key must be string");
type_tag = JSON_TYPE.OBJECT;
static if(is(Value : JSONValue)) {
store.object = arg;
}
else
{
JSONValue[string] aa;
foreach(key, value; arg)
aa[key] = JSONValue(value);
store.object = aa;
}
}
else static if(isArray!T)
{
type_tag = JSON_TYPE.ARRAY;
static if(is(ElementEncodingType!T : JSONValue))
{
store.array = arg;
}
else
{
JSONValue[] new_arg = new JSONValue[arg.length];
foreach(i, e; arg)
new_arg[i] = JSONValue(e);
store.array = new_arg;
}
}
else static if(is(T : JSONValue))
{
type_tag = arg.type;
store = arg.store;
}
else
{
static assert(false, text(`unable to convert type "`, T.stringof, `" to json`));
}
}
private void assignRef(T)(ref T arg) if(isStaticArray!T)
{
type_tag = JSON_TYPE.ARRAY;
static if(is(ElementEncodingType!T : JSONValue))
{
store.array = arg;
}
else
{
JSONValue[] new_arg = new JSONValue[arg.length];
foreach(i, e; arg)
new_arg[i] = JSONValue(e);
store.array = new_arg;
}
}
/**
* Constructor for $(D JSONValue). If $(D arg) is a $(D JSONValue)
* its value and type will be copied to the new $(D JSONValue).
* Note that this is a shallow copy: if type is $(D JSON_TYPE.OBJECT)
* or $(D JSON_TYPE.ARRAY) then only the reference to the data will
* be copied.
* Otherwise, $(D arg) must be implicitly convertible to one of the
* following types: $(D typeof(null)), $(D string), $(D ulong),
* $(D long), $(D double), an associative array $(D V[K]) for any $(D V)
* and $(D K) i.e. a JSON object, any array or $(D bool). The type will
* be set accordingly.
*/
this(T)(T arg) if(!isStaticArray!T)
{
assign(arg);
}
/// Ditto
this(T)(ref T arg) if(isStaticArray!T)
{
assignRef(arg);
}
/// Ditto
this(T : JSONValue)(inout T arg) inout
{
store = arg.store;
type_tag = arg.type;
}
void opAssign(T)(T arg) if(!isStaticArray!T && !is(T : JSONValue))
{
assign(arg);
}
void opAssign(T)(ref T arg) if(isStaticArray!T)
{
assignRef(arg);
}
/// Array syntax for json arrays.
/// Throws $(D JSONException) if $(D type) is not $(D JSON_TYPE.ARRAY).
ref inout(JSONValue) opIndex(size_t i) inout
{
enforce!JSONException(type == JSON_TYPE.ARRAY,
"JSONValue is not an array");
enforceEx!JSONException(i < store.array.length,
"JSONValue array index is out of range");
return store.array[i];
}
/// Hash syntax for json objects.
/// Throws $(D JSONException) if $(D type) is not $(D JSON_TYPE.OBJECT).
ref inout(JSONValue) opIndex(string k) inout
{
enforce!JSONException(type == JSON_TYPE.OBJECT,
"JSONValue is not an object");
return *enforce!JSONException(k in store.object,
"Key not found: " ~ k);
}
void opIndexAssign(T)(T arg, size_t i)
{
enforceEx!JSONException(type == JSON_TYPE.ARRAY,
"JSONValue is not an array");
enforceEx!JSONException(i < store.array.length,
"JSONValue array index is out of range");
store.array[i] = arg;
}
void opIndexAssign(T)(T arg, string k)
{
enforceEx!JSONException(type == JSON_TYPE.OBJECT,
"JSONValue is not an object");
store.object[k] = arg;
}
JSONValue opBinary(string op : "~", T)(T arg)
{
enforceEx!JSONException(type == JSON_TYPE.ARRAY,
"JSONValue is not an array");
static if(isArray!T)
{
JSONValue newArray = JSONValue(this.store.array.dup);
newArray.store.array ~= JSONValue(arg).store.array;
return newArray;
}
else static if(is(T : JSONValue))
{
enforceEx!JSONException(arg.type == JSON_TYPE.ARRAY,
"JSONValue is not an array");
JSONValue newArray = JSONValue(this.store.array.dup);
newArray.store.array ~= arg.store.array;
return newArray;
}
else
{
static assert(false, "argument is not an array or a JSONValue array");
}
}
void opOpAssign(string op : "~", T)(T arg)
{
enforceEx!JSONException(type == JSON_TYPE.ARRAY,
"JSONValue is not an array");
static if(isArray!T)
{
store.array ~= JSONValue(arg).store.array;
}
else static if(is(T : JSONValue))
{
enforceEx!JSONException(arg.type == JSON_TYPE.ARRAY,
"JSONValue is not an array");
store.array ~= arg.store.array;
}
else
{
static assert(false, "argument is not an array or a JSONValue array");
}
}
auto opBinaryRight(string op : "in")(string k) const
{
enforce!JSONException(type == JSON_TYPE.OBJECT,
"JSONValue is not an object");
return k in store.object;
}
/// Implements the foreach $(D opApply) interface for json arrays.
int opApply(int delegate(size_t index, ref JSONValue) dg)
{
enforce!JSONException(type == JSON_TYPE.ARRAY,
"JSONValue is not an array");
int result;
foreach(size_t index, ref value; store.array)
{
result = dg(index, value);
if(result)
break;
}
return result;
}
/// Implements the foreach $(D opApply) interface for json objects.
int opApply(int delegate(string key, ref JSONValue) dg)
{
enforce!JSONException(type == JSON_TYPE.OBJECT,
"JSONValue is not an object");
int result;
foreach(string key, ref value; store.object)
{
result = dg(key, value);
if(result)
break;
}
return result;
}
/// Implicitly calls $(D toJSON) on this JSONValue.
string toString() const
{
return toJSON(&this);
}
/// Implicitly calls $(D toJSON) on this JSONValue, like $(D toString), but
/// also passes $(I true) as $(I pretty) argument.
string toPrettyString() const
{
return toJSON(&this, true);
}
}
/**
Parses a serialized string and returns a tree of JSON values.
*/
JSONValue parseJSON(T)(T json, int maxDepth = -1) if(isInputRange!T)
{
JSONValue root = void;
root.type_tag = JSON_TYPE.NULL;
if(json.empty) return root;
int depth = -1;
dchar next = 0;
int line = 1, pos = 1;
void error(string msg)
{
throw new JSONException(msg, line, pos);
}
dchar peekChar()
{
if(!next)
{
if(json.empty) return '\0';
next = json.front;
json.popFront();
}
return next;
}
void skipWhitespace()
{
while(isWhite(peekChar())) next = 0;
}
dchar getChar(bool SkipWhitespace = false)()
{
static if(SkipWhitespace) skipWhitespace();
dchar c = void;
if(next)
{
c = next;
next = 0;
}
else
{
if(json.empty) error("Unexpected end of data.");
c = json.front;
json.popFront();
}
if(c == '\n' || (c == '\r' && peekChar() != '\n'))
{
line++;
pos = 1;
}
else
{
pos++;
}
return c;
}
void checkChar(bool SkipWhitespace = true, bool CaseSensitive = true)(char c)
{
static if(SkipWhitespace) skipWhitespace();
auto c2 = getChar();
static if(!CaseSensitive) c2 = toLower(c2);
if(c2 != c) error(text("Found '", c2, "' when expecting '", c, "'."));
}
bool testChar(bool SkipWhitespace = true, bool CaseSensitive = true)(char c)
{
static if(SkipWhitespace) skipWhitespace();
auto c2 = peekChar();
static if (!CaseSensitive) c2 = toLower(c2);
if(c2 != c) return false;
getChar();
return true;
}
string parseString()
{
auto str = appender!string();
Next:
switch(peekChar())
{
case '"':
getChar();
break;
case '\\':
getChar();
auto c = getChar();
switch(c)
{
case '"': str.put('"'); break;
case '\\': str.put('\\'); break;
case '/': str.put('/'); break;
case 'b': str.put('\b'); break;
case 'f': str.put('\f'); break;
case 'n': str.put('\n'); break;
case 'r': str.put('\r'); break;
case 't': str.put('\t'); break;
case 'u':
dchar val = 0;
foreach_reverse(i; 0 .. 4)
{
auto hex = toUpper(getChar());
if(!isHexDigit(hex)) error("Expecting hex character");
val += (isDigit(hex) ? hex - '0' : hex - ('A' - 10)) << (4 * i);
}
char[4] buf = void;
str.put(toUTF8(buf, val));
break;
default:
error(text("Invalid escape sequence '\\", c, "'."));
}
goto Next;
default:
auto c = getChar();
appendJSONChar(&str, c, &error);
goto Next;
}
return str.data ? str.data : "";
}
void parseValue(JSONValue* value)
{
depth++;
if(maxDepth != -1 && depth > maxDepth) error("Nesting too deep.");
auto c = getChar!true();
switch(c)
{
case '{':
value.type_tag = JSON_TYPE.OBJECT;
value.store.object = null;
if(testChar('}')) break;
do
{
checkChar('"');
string name = parseString();
checkChar(':');
JSONValue member = void;
parseValue(&member);
value.store.object[name] = member;
}
while(testChar(','));
checkChar('}');
break;
case '[':
value.type_tag = JSON_TYPE.ARRAY;
if(testChar(']'))
{
value.store.array = cast(JSONValue[]) "";
break;
}
value.store.array = null;
do
{
JSONValue element = void;
parseValue(&element);
value.store.array ~= element;
}
while(testChar(','));
checkChar(']');
break;
case '"':
value.type_tag = JSON_TYPE.STRING;
value.store.str = parseString();
break;
case '0': .. case '9':
case '-':
auto number = appender!string();
bool isFloat, isNegative;
void readInteger()
{
if(!isDigit(c)) error("Digit expected");
Next: number.put(c);
if(isDigit(peekChar()))
{
c = getChar();
goto Next;
}
}
if(c == '-')
{
number.put('-');
c = getChar();
isNegative = true;
}
readInteger();
if(testChar('.'))
{
isFloat = true;
number.put('.');
c = getChar();
readInteger();
}
if(testChar!(false, false)('e'))
{
isFloat = true;
number.put('e');
if(testChar('+')) number.put('+');
else if(testChar('-')) number.put('-');
c = getChar();
readInteger();
}
string data = number.data;
if(isFloat)
{
value.type_tag = JSON_TYPE.FLOAT;
value.store.floating = parse!double(data);
}
else
{
if (isNegative)
value.store.integer = parse!long(data);
else
value.store.uinteger = parse!ulong(data);
value.type_tag = !isNegative && value.store.uinteger & (1UL << 63) ? JSON_TYPE.UINTEGER : JSON_TYPE.INTEGER;
}
break;
case 't':
case 'T':
value.type_tag = JSON_TYPE.TRUE;
checkChar!(false, false)('r');
checkChar!(false, false)('u');
checkChar!(false, false)('e');
break;
case 'f':
case 'F':
value.type_tag = JSON_TYPE.FALSE;
checkChar!(false, false)('a');
checkChar!(false, false)('l');
checkChar!(false, false)('s');
checkChar!(false, false)('e');
break;
case 'n':
case 'N':
value.type_tag = JSON_TYPE.NULL;
checkChar!(false, false)('u');
checkChar!(false, false)('l');
checkChar!(false, false)('l');
break;
default:
error(text("Unexpected character '", c, "'."));
}
depth--;
}
parseValue(&root);
return root;
}
/**
Takes a tree of JSON values and returns the serialized string.
Any Object types will be serialized in a key-sorted order.
If $(D pretty) is false no whitespaces are generated.
If $(D pretty) is true serialized string is formatted to be human-readable.
*/
string toJSON(in JSONValue* root, in bool pretty = false)
{
auto json = appender!string();
void toString(string str)
{
json.put('"');
foreach (dchar c; str)
{
switch(c)
{
case '"': json.put("\\\""); break;
case '\\': json.put("\\\\"); break;
case '/': json.put("\\/"); break;
case '\b': json.put("\\b"); break;
case '\f': json.put("\\f"); break;
case '\n': json.put("\\n"); break;
case '\r': json.put("\\r"); break;
case '\t': json.put("\\t"); break;
default:
appendJSONChar(&json, c,
(msg) { throw new JSONException(msg); });
}
}
json.put('"');
}
void toValue(in JSONValue* value, ulong indentLevel)
{
void putTabs(ulong additionalIndent = 0)
{
if(pretty)
foreach(i; 0 .. indentLevel + additionalIndent)
json.put(" ");
}
void putEOL()
{
if(pretty)
json.put('\n');
}
void putCharAndEOL(char ch)
{
json.put(ch);
putEOL();
}
final switch(value.type)
{
case JSON_TYPE.OBJECT:
if(!value.store.object.length)
{
json.put("{}");
}
else
{
putCharAndEOL('{');
bool first = true;
void emit(R)(R names)
{
foreach (name; names)
{
auto member = value.store.object[name];
if(!first)
putCharAndEOL(',');
first = false;
putTabs(1);
toString(name);
json.put(':');
if(pretty)
json.put(' ');
toValue(&member, indentLevel + 1);
}
}
import std.algorithm : sort;
auto names = value.store.object.keys;
sort(names);
emit(names);
putEOL();
putTabs();
json.put('}');
}
break;
case JSON_TYPE.ARRAY:
if(value.store.array.empty)
{
json.put("[]");
}
else
{
putCharAndEOL('[');
foreach (i, ref el; value.store.array)
{
if(i)
putCharAndEOL(',');
putTabs(1);
toValue(&el, indentLevel + 1);
}
putEOL();
putTabs();
json.put(']');
}
break;
case JSON_TYPE.STRING:
toString(value.store.str);
break;
case JSON_TYPE.INTEGER:
json.put(to!string(value.store.integer));
break;
case JSON_TYPE.UINTEGER:
json.put(to!string(value.store.uinteger));
break;
case JSON_TYPE.FLOAT:
json.put(to!string(value.store.floating));
break;
case JSON_TYPE.TRUE:
json.put("true");
break;
case JSON_TYPE.FALSE:
json.put("false");
break;
case JSON_TYPE.NULL:
json.put("null");
break;
}
}
toValue(root, 0);
return json.data;
}
private void appendJSONChar(Appender!string* dst, dchar c,
scope void delegate(string) error)
{
import std.uni : isControl;
if(isControl(c))
error("Illegal control character.");
dst.put(c);
}
/**
Exception thrown on JSON errors
*/
class JSONException : Exception
{
this(string msg, int line = 0, int pos = 0)
{
if(line)
super(text(msg, " (Line ", line, ":", pos, ")"));
else
super(msg);
}
this(string msg, string file, size_t line)
{
super(msg, file, line);
}
}
unittest
{
JSONValue jv = "123";
assert(jv.type == JSON_TYPE.STRING);
assertNotThrown(jv.str);
assertThrown!JSONException(jv.integer);
assertThrown!JSONException(jv.uinteger);
assertThrown!JSONException(jv.floating);
assertThrown!JSONException(jv.object);
assertThrown!JSONException(jv.array);
assertThrown!JSONException(jv["aa"]);
assertThrown!JSONException(jv[2]);
jv = -3;
assert(jv.type == JSON_TYPE.INTEGER);
assertNotThrown(jv.integer);
jv = cast(uint)3;
assert(jv.type == JSON_TYPE.UINTEGER);
assertNotThrown(jv.uinteger);
jv = 3.0f;
assert(jv.type == JSON_TYPE.FLOAT);
assertNotThrown(jv.floating);
jv = ["key" : "value"];
assert(jv.type == JSON_TYPE.OBJECT);
assertNotThrown(jv.object);
assertNotThrown(jv["key"]);
assert("key" in jv);
assert("notAnElement" !in jv);
assertThrown!JSONException(jv["notAnElement"]);
const cjv = jv;
assert("key" in cjv);
assertThrown!JSONException(cjv["notAnElement"]);
foreach(string key, value; jv)
{
static assert(is(typeof(value) == JSONValue));
assert(key == "key");
assert(value.type == JSON_TYPE.STRING);
assertNotThrown(value.str);
assert(value.str == "value");
}
jv = [3, 4, 5];
assert(jv.type == JSON_TYPE.ARRAY);
assertNotThrown(jv.array);
assertNotThrown(jv[2]);
foreach(size_t index, value; jv)
{
static assert(is(typeof(value) == JSONValue));
assert(value.type == JSON_TYPE.INTEGER);
assertNotThrown(value.integer);
assert(index == (value.integer-3));
}
jv = JSONValue("value");
assert(jv.type == JSON_TYPE.STRING);
assert(jv.str == "value");
JSONValue jv2 = JSONValue("value");
assert(jv2.type == JSON_TYPE.STRING);
assert(jv2.str == "value");
}
unittest
{
// Bugzilla 11504
JSONValue jv = 1;
assert(jv.type == JSON_TYPE.INTEGER);
jv.str = "123";
assert(jv.type == JSON_TYPE.STRING);
assert(jv.str == "123");
jv.integer = 1;
assert(jv.type == JSON_TYPE.INTEGER);
assert(jv.integer == 1);
jv.uinteger = 2u;
assert(jv.type == JSON_TYPE.UINTEGER);
assert(jv.uinteger == 2u);
jv.floating = 1.5f;
assert(jv.type == JSON_TYPE.FLOAT);
assert(jv.floating == 1.5f);
jv.object = ["key" : JSONValue("value")];
assert(jv.type == JSON_TYPE.OBJECT);
assert(jv.object == ["key" : JSONValue("value")]);
jv.array = [JSONValue(1), JSONValue(2), JSONValue(3)];
assert(jv.type == JSON_TYPE.ARRAY);
assert(jv.array == [JSONValue(1), JSONValue(2), JSONValue(3)]);
jv = true;
assert(jv.type == JSON_TYPE.TRUE);
jv = false;
assert(jv.type == JSON_TYPE.FALSE);
enum E{True = true}
jv = E.True;
assert(jv.type == JSON_TYPE.TRUE);
}
unittest
{
// Adding new json element via array() / object() directly
JSONValue jarr = JSONValue([10]);
foreach (i; 0..9)
jarr.array ~= JSONValue(i);
assert(jarr.array.length == 10);
JSONValue jobj = JSONValue(["key" : JSONValue("value")]);
foreach (i; 0..9)
jobj.object[text("key", i)] = JSONValue(text("value", i));
assert(jobj.object.length == 10);
}
unittest
{
// Adding new json element without array() / object() access
JSONValue jarr = JSONValue([10]);
foreach (i; 0..9)
jarr ~= [JSONValue(i)];
assert(jarr.array.length == 10);
JSONValue jobj = JSONValue(["key" : JSONValue("value")]);
foreach (i; 0..9)
jobj[text("key", i)] = JSONValue(text("value", i));
assert(jobj.object.length == 10);
// No array alias
auto jarr2 = jarr ~ [1,2,3];
jarr2[0] = 999;
assert(jarr[0] == JSONValue(10));
}
unittest
{
// An overly simple test suite, if it can parse a serializated string and
// then use the resulting values tree to generate an identical
// serialization, both the decoder and encoder works.
auto jsons = [
`null`,
`true`,
`false`,
`0`,
`123`,
`-4321`,
`0.23`,
`-0.23`,
`""`,
`"hello\nworld"`,
`"\"\\\/\b\f\n\r\t"`,
`[]`,
`[12,"foo",true,false]`,
`{}`,
`{"a":1,"b":null}`,
`{"goodbye":[true,"or",false,["test",42,{"nested":{"a":23.54,"b":0.0012}}]],"hello":{"array":[12,null,{}],"json":"is great"}}`,
];
version (MinGW)
jsons ~= `1.223e+024`;
else
jsons ~= `1.223e+24`;
JSONValue val;
string result;
foreach (json; jsons)
{
try
{
val = parseJSON(json);
enum pretty = false;
result = toJSON(&val, pretty);
assert(result == json, text(result, " should be ", json));
}
catch (JSONException e)
{
import std.stdio : writefln;
writefln(text(json, "\n", e.toString()));
}
}
// Should be able to correctly interpret unicode entities
val = parseJSON(`"\u003C\u003E"`);
assert(toJSON(&val) == "\"\<\>\"");
assert(val.to!string() == "\"\<\>\"");
val = parseJSON(`"\u0391\u0392\u0393"`);
assert(toJSON(&val) == "\"\Α\Β\Γ\"");
assert(val.to!string() == "\"\Α\Β\Γ\"");
val = parseJSON(`"\u2660\u2666"`);
assert(toJSON(&val) == "\"\♠\♦\"");
assert(val.to!string() == "\"\♠\♦\"");
//0x7F is a control character (see Unicode spec)
assertThrown(parseJSON(`{ "foo": "` ~ "\u007F" ~ `"}`));
with(parseJSON(`""`))
assert(str == "" && str !is null);
with(parseJSON(`[]`))
assert(!array.length && array !is null);
// Formatting
val = parseJSON(`{"a":[null,{"x":1},{},[]]}`);
assert(toJSON(&val, true) == `{
"a": [
null,
{
"x": 1
},
{},
[]
]
}`);
}
unittest {
auto json = `"hello\nworld"`;
const jv = parseJSON(json);
assert(jv.toString == json);
assert(jv.toPrettyString == json);
}
deprecated unittest
{
// Bugzilla 12332
JSONValue jv;
jv.type = JSON_TYPE.INTEGER;
jv = 1;
assert(jv.type == JSON_TYPE.INTEGER);
assert(jv.integer == 1);
jv.type = JSON_TYPE.UINTEGER;
assert(jv.uinteger == 1);
jv.type = JSON_TYPE.STRING;
assertThrown!JSONException(jv.integer == 1);
assert(jv.str is null);
jv.str = "123";
assert(jv.str == "123");
jv.type = JSON_TYPE.STRING;
assert(jv.str == "123");
jv.type = JSON_TYPE.TRUE;
assert(jv.type == JSON_TYPE.TRUE);
}
| D |
/home/ubuntu/rustex/ch11/target/debug/deps/ch11-2ac1aaab98b70a3a.rmeta: src/lib.rs
/home/ubuntu/rustex/ch11/target/debug/deps/libch11-2ac1aaab98b70a3a.rlib: src/lib.rs
/home/ubuntu/rustex/ch11/target/debug/deps/ch11-2ac1aaab98b70a3a.d: src/lib.rs
src/lib.rs:
| D |
version https://git-lfs.github.com/spec/v1
oid sha256:b333bf70f4ebe06194bd4215982096b0abeac62e1d3cfd2fab78fccaa06470f9
size 2490
| D |
import vibe.d;
void getVersion(HTTPServerRequest req, HTTPServerResponse res)
{
res.writeBody("0.0.1");
}
| D |
/**
* Authors: Frank Benoit <keinfarbton@googlemail.com>
*/
module dwt.dwthelper.ByteArrayOutputStream;
public import dwt.dwthelper.OutputStream;
import dwt.dwthelper.utils;
import tango.io.device.Array;
public class ByteArrayOutputStream : dwt.dwthelper.OutputStream.OutputStream
{
protected Array buffer;
/+
public this ()
{
buffer = new Array();
}
+/
public this ( int par_size )
{
buffer = new Array(par_size);
}
public synchronized override void write( int b )
{
byte[1] a;
a[0] = b & 0xFF;
buffer.append(a);
}
public synchronized override void write( byte[] b, int off, int len )
{
buffer.append( b[ off .. off + len ]);
}
public synchronized override void write( byte[] b )
{
buffer.append( b );
}
public synchronized void writeTo( dwt.dwthelper.OutputStream.OutputStream out_KEYWORDESCAPE )
{
implMissing( __FILE__, __LINE__ );
}
public synchronized void reset()
{
implMissing( __FILE__, __LINE__ );
}
public synchronized byte[] toByteArray()
{
return cast(byte[])buffer.slice();
}
public int size()
{
implMissing( __FILE__, __LINE__ );
return 0;
}
public override String toString()
{
implMissing( __FILE__, __LINE__ );
return null;
}
public String toString( String enc )
{
implMissing( __FILE__, __LINE__ );
return null;
}
public String toString( int hibyte )
{
implMissing( __FILE__, __LINE__ );
return null;
}
public override void close()
{
implMissing( __FILE__, __LINE__ );
}
}
| D |
module emul.m68k.instructions.bsr;
import emul.m68k.instructions.common;
package nothrow:
void addBsrInstructions(ref Instruction[ushort] ret) pure
{
foreach(i; 0x1..0xfe)
{
ret.addInstruction(Instruction("bsr",cast(ushort)(0x6100 | i),0x2,&bsrImpl!void));
}
ret.addInstruction(Instruction("bsr",0x6100,0x4,&bsrImpl!short));
ret.addInstruction(Instruction("bsr",0x61ff,0x6,&bsrImpl!int));
}
private:
void bsrImpl(T)(ref Cpu cpu)
{
cpu.state.SP -= uint.sizeof;
cpu.setMemValue(cpu.state.SP,cpu.state.PC);
const offset = cpu.getInstructionData!T(cast(uint)(cpu.state.PC - T.sizeof));
cpu.state.PC += offset - T.sizeof;
}
void bsrImpl(T : void)(ref Cpu cpu)
{
cpu.state.SP -= uint.sizeof;
cpu.setMemValue(cpu.state.SP,cpu.state.PC);
const offset = cpu.getInstructionData!byte(cpu.state.PC - 0x1);
cpu.state.PC += offset;
} | D |
/home/hustccc/OS_Tutorial_Summer_of_Code/rCore_Labs/Lab5/os/target/riscv64imac-unknown-none-elf/debug/deps/buddy_system_allocator-f0fb5a3b03b906ad.rmeta: /home/hustccc/.cargo/registry/src/mirrors.ustc.edu.cn-61ef6e0cd06fb9b8/buddy_system_allocator-0.3.9/src/lib.rs /home/hustccc/.cargo/registry/src/mirrors.ustc.edu.cn-61ef6e0cd06fb9b8/buddy_system_allocator-0.3.9/src/frame.rs /home/hustccc/.cargo/registry/src/mirrors.ustc.edu.cn-61ef6e0cd06fb9b8/buddy_system_allocator-0.3.9/src/linked_list.rs
/home/hustccc/OS_Tutorial_Summer_of_Code/rCore_Labs/Lab5/os/target/riscv64imac-unknown-none-elf/debug/deps/buddy_system_allocator-f0fb5a3b03b906ad.d: /home/hustccc/.cargo/registry/src/mirrors.ustc.edu.cn-61ef6e0cd06fb9b8/buddy_system_allocator-0.3.9/src/lib.rs /home/hustccc/.cargo/registry/src/mirrors.ustc.edu.cn-61ef6e0cd06fb9b8/buddy_system_allocator-0.3.9/src/frame.rs /home/hustccc/.cargo/registry/src/mirrors.ustc.edu.cn-61ef6e0cd06fb9b8/buddy_system_allocator-0.3.9/src/linked_list.rs
/home/hustccc/.cargo/registry/src/mirrors.ustc.edu.cn-61ef6e0cd06fb9b8/buddy_system_allocator-0.3.9/src/lib.rs:
/home/hustccc/.cargo/registry/src/mirrors.ustc.edu.cn-61ef6e0cd06fb9b8/buddy_system_allocator-0.3.9/src/frame.rs:
/home/hustccc/.cargo/registry/src/mirrors.ustc.edu.cn-61ef6e0cd06fb9b8/buddy_system_allocator-0.3.9/src/linked_list.rs:
| D |
module ogre.resources.highlevelgpuprogram;
debug import std.stdio;
import ogre.materials.gpuprogram;
import ogre.singleton;
import ogre.general.common;
import ogre.general.generals;
import ogre.exception;
import ogre.resources.unifiedhighlevelgpuprogram;
import ogre.resources.resource;
import ogre.resources.resourcemanager;
import ogre.resources.datastream;
import ogre.resources.resourcegroupmanager;
import ogre.general.log;
import ogre.sharedptr;
/** Abstract base class representing a high-level program (a vertex or
fragment program).
@remarks
High-level programs are vertex and fragment programs written in a high-level
language such as Cg or HLSL, and as such do not require you to write assembler code
like GpuProgram does. However, the high-level program does eventually
get converted (compiled) into assembler and then eventually microcode which is
what runs on the GPU. As well as the convenience, some high-level languages like Cg allow
you to write a program which will operate under both Direct3D and OpenGL, something
which you cannot do with just GpuProgram (which requires you to write 2 programs and
use each in a Technique to provide cross-API compatibility). Ogre will be creating
a GpuProgram for you based on the high-level program, which is compiled specifically
for the API being used at the time, but this process is transparent.
@par
You cannot create high-level programs direct - use HighLevelGpuProgramManager instead.
Plugins can register new implementations of HighLevelGpuProgramFactory in order to add
support for new languages without requiring changes to the core Ogre API. To allow
custom parameters to be set, this class extends StringInterface - the application
can query on the available custom parameters and get/set them without having to
link specifically with it.
*/
class HighLevelGpuProgram : GpuProgram
{
public:
//Cyclic static ctor
static void initCmds()
{
UnifiedHighLevelGpuProgram.initCmds();
}
protected:
/// Whether the high-level program (and it's parameter defs) is loaded
bool mHighLevelLoaded;
/// The underlying assembler program
SharedPtr!GpuProgram mAssemblerProgram;
/// Have we built the name->index parameter map yet?
//mutable
bool mConstantDefsBuilt;
/// Internal load high-level portion if not loaded
void loadHighLevel()
{
if (!mHighLevelLoaded)
{
try
{
loadHighLevelImpl();
mHighLevelLoaded = true;
if (!mDefaultParams.isNull())
{
// Keep a reference to old ones to copy
GpuProgramParametersPtr savedParams = mDefaultParams;
// reset params to stop them being referenced in the next create
mDefaultParams.setNull();
// Create new params
mDefaultParams = createParameters();
// Copy old (matching) values across
// Don't use copyConstantsFrom since program may be different
mDefaultParams.get().copyMatchingNamedConstantsFrom(savedParams.get());
}
}
catch (Exception e)
{
// will already have been logged
LogManager.getSingleton().stream()
<< "High-level program " << mName << " encountered an error "
<< "during loading and is thus not supported.\n"
<< e;//.getFullDescription();
mCompileError = true;
}
}
}
/// Internal unload high-level portion if loaded
void unloadHighLevel()
{
if (mHighLevelLoaded)
{
unloadHighLevelImpl();
// Clear saved constant defs
mConstantDefsBuilt = false;
createParameterMappingStructures(true);
mHighLevelLoaded = false;
}
}
/** Internal load implementation, loads just the high-level portion, enough to
get parameters.
*/
void loadHighLevelImpl()
{
if (mLoadFromFile)
{
// find & load source code
DataStreamPtr stream =
ResourceGroupManager.getSingleton().openResource(
mFilename, mGroup, true, this);
mSource = stream.getAsString();
}
loadFromSource();
}
/** Internal method for creating an appropriate low-level program from this
high-level program, must be implemented by subclasses. */
abstract void createLowLevelImpl();
/// Internal unload implementation, must be implemented by subclasses
abstract void unloadHighLevelImpl();
/// Populate the passed parameters with name->index map
void populateParameterNames(GpuProgramParametersPtr params)
{
getConstantDefinitions();
params.get()._setNamedConstants(mConstantDefs);
// also set logical / physical maps for programs which use this
params.get()._setLogicalIndexes(mFloatLogicalToPhysical, mDoubleLogicalToPhysical, mIntLogicalToPhysical);
}
/** Build the constant definition map, must be overridden.
@note The implementation must fill in the (inherited) mConstantDefs field at a minimum,
and if the program requires that parameters are bound using logical
parameter indexes then the mFloatLogicalToPhysical and mIntLogicalToPhysical
maps must also be populated.
*/
abstract void buildConstantDefinitions();
/** @copydoc Resource::loadImpl */
override void loadImpl()
{
if (isSupported())
{
// load self
loadHighLevel();
// create low-level implementation
createLowLevelImpl();
// loadructed assembler program (if it exists)
if (!mAssemblerProgram.isNull() && mAssemblerProgram.getPointer() != this)
{
mAssemblerProgram.get().load();
}
}
}
/** @copydoc Resource::unloadImpl */
override void unloadImpl()
{
if (!mAssemblerProgram.isNull() && mAssemblerProgram.getPointer() != this)
{
mAssemblerProgram.get().getCreator().remove(mAssemblerProgram.get().getHandle());
mAssemblerProgram.setNull();
}
unloadHighLevel();
resetCompileError();
}
public:
/** Constructor, should be used only by factory classes. */
this(ref ResourceManager creator, string name, ResourceHandle handle,
string group, bool isManual = false, ManualResourceLoader loader = null)
{
super(creator, name, handle, group, isManual, loader);
mHighLevelLoaded = false;
mAssemblerProgram.setNull();// = null;
mConstantDefsBuilt = false;
}
~this()
{
// superclasses will trigger unload
}
override size_t calculateSize() //const
{
size_t memSize = 0;
memSize += bool.sizeof;
if(!mAssemblerProgram.isNull() && (mAssemblerProgram.getPointer() != this) )
memSize += mAssemblerProgram.calculateSize();
memSize += GpuProgram.calculateSize();
return memSize;
}
/** Creates a new parameters object compatible with this program definition.
@remarks
Unlike low-level assembly programs, parameters objects are specific to the
program and Therefore must be created from it rather than by the
HighLevelGpuProgramManager. This method creates a new instance of a parameters
object containing the definition of the parameters this program understands.
*/
override GpuProgramParametersPtr createParameters()
{
// Lock mutex before allowing this since this is a top-level method
// called outside of the load()
//OGRE_LOCK_AUTO_MUTEX
synchronized(mLock)
{
// Make sure param defs are loaded
GpuProgramParametersPtr params = GpuProgramManager.getSingleton().createParameters();
// Only populate named parameters if we can support this program
if (this.isSupported())
{
loadHighLevel();
// Errors during load may have prevented compile
if (this.isSupported())
{
populateParameterNames(params);
}
}
// Copy in default parameters if present
if (!mDefaultParams.isNull())
params.get().copyConstantsFrom(mDefaultParams.get());
return params;
}
}
/** @copydoc GpuProgram::_getBindingDelegate */
override GpuProgram _getBindingDelegate() { return mAssemblerProgram.getAs(); }
/** Get the full list of GpuConstantDefinition instances.
@note
Only available if this parameters object has named parameters.
*/
override GpuNamedConstants* getConstantDefinitions()
{
if (!mConstantDefsBuilt)
{
buildConstantDefinitions();
mConstantDefsBuilt = true;
}
return mConstantDefs.get();
}
/// Override GpuProgram::getNamedConstants to ensure built
override GpuNamedConstants getNamedConstants(){ return *getConstantDefinitions(); }
}
/** Specialisation of SharedPtr to allow SharedPtr to be assigned to SharedPtr!HighLevelGpuProgram
@note Has to be a subclass since we need operator=.
We could templatise this instead of repeating per Resource subclass,
except to do so requires a form VC6 does not support i.e.
ResourceSubclassPtr<T> : public SharedPtr<T>
*/
//alias SharedPtr!r!HighLevelGpuProgram HighLevelSharedPtr;
/** Interface definition for factories of HighLevelGpuProgram. */
interface HighLevelGpuProgramFactory //: public FactoryAlloc
{
/// Get the name of the language this factory creates programs for
string getLanguage();
HighLevelGpuProgram create(ResourceManager creator,
string name, ResourceHandle handle,
string group, bool isManual, ManualResourceLoader loader);
void destroyObj(HighLevelGpuProgram prog);
}
enum string sNullLang = "null";
class NullProgram : HighLevelGpuProgram
{
protected:
/** Internal load implementation, must be implemented by subclasses.
*/
override void loadFromSource() {}
/** Internal method for creating an appropriate low-level program from this
high-level program, must be implemented by subclasses. */
override void createLowLevelImpl() {}
/// Internal unload implementation, must be implemented by subclasses
override void unloadHighLevelImpl() {}
/// Populate the passed parameters with name->index map, must be overridden
override void populateParameterNames(GpuProgramParametersPtr params)
{
// Skip the normal implementation
// Ensure we don't complain about missing parameter names
params.get().setIgnoreMissingParams(true);
}
override void buildConstantDefinitions()
{
// do nothing
}
public:
this(ref ResourceManager creator,
string name, ResourceHandle handle,string group,
bool isManual, ManualResourceLoader loader)
{
super(creator, name, handle, group, isManual, loader);
}
~this() {}
/// Overridden from GpuProgram - never supported
override bool isSupported(){ return false; }
/// Overridden from GpuProgram
override string getLanguage(){ return sNullLang; }
override size_t calculateSize() //const
{ return 0; }
/// Overridden from StringInterface
override bool setParameter(string name,string value)
{
// always silently ignore all parameters so as not to report errors on
// unsupported platforms
return true;
}
}
class NullProgramFactory : HighLevelGpuProgramFactory
{
public:
this() {}
~this() {}
/// Get the name of the language this factory creates programs for
string getLanguage()
{
return sNullLang;
}
HighLevelGpuProgram create(ResourceManager creator,
string name, ResourceHandle handle,
string group, bool isManual, ManualResourceLoader loader)
{
return new NullProgram(creator, name, handle, group, isManual, loader);
}
void destroyObj(HighLevelGpuProgram prog)
{
destroy(prog);
}
}
/** This ResourceManager manages high-level vertex and fragment programs.
@remarks
High-level vertex and fragment programs can be used instead of assembler programs
as managed by GpuProgramManager; however they typically result in a GpuProgram
being created as a derivative of the high-level program. High-level programs are
easier to write, and can often be API-independent, unlike assembler programs.
@par
This class not only manages the programs themselves, it also manages the factory
classes which allow the creation of high-level programs using a variety of high-level
syntaxes. Plugins can be created which register themselves as high-level program
factories and as such the engine can be extended to accept virtually any kind of
program provided a plugin is written.
*/
class HighLevelGpuProgramManager : ResourceManager
{
mixin Singleton!HighLevelGpuProgramManager;
public:
//typedef map<String, HighLevelGpuProgramFactory*>::type FactoryMap;
alias HighLevelGpuProgramFactory[string] FactoryMap;
protected:
/// Factories capable of creating HighLevelGpuProgram instances
FactoryMap mFactories;
/// Factory for dealing with programs for languages we can't create
HighLevelGpuProgramFactory mNullFactory;
/// Factory for unified high-level programs
HighLevelGpuProgramFactory mUnifiedFactory;
ref HighLevelGpuProgramFactory getFactory(string language)
{
auto i = language in mFactories;
if (i is null)
{
// use the null factory to create programs that will never be supported
i = sNullLang in mFactories;
}
return *i;
}
/// @copydoc ResourceManager::createImpl
override Resource createImpl(string name, ResourceHandle handle,
string group, bool isManual, ManualResourceLoader loader,
NameValuePairList createParams)
{
string *ptr;
if (createParams is null || (ptr = "language" in createParams) is null)
{
throw new InvalidParamsError(
"You must supply a 'language' parameter",
"HighLevelGpuProgramManager.createImpl");
}
return getFactory(*ptr).create(this, name, getNextHandle(),
group, isManual, loader);
}
public:
this()
{
// Loading order
mLoadOrder = 50.0f;
// Resource type
mResourceType = "HighLevelGpuProgram";
ResourceGroupManager.getSingleton()._registerResourceManager(mResourceType, this);
mNullFactory = new NullProgramFactory();
addFactory(mNullFactory);
mUnifiedFactory = new UnifiedHighLevelGpuProgramFactory();
addFactory(mUnifiedFactory);
}
~this()
{
destroy(mUnifiedFactory);
destroy(mNullFactory);
ResourceGroupManager.getSingleton()._unregisterResourceManager(mResourceType);
}
/** Add a new factory object for high-level programs of a given language. */
void addFactory(HighLevelGpuProgramFactory factory)
{
// deliberately allow later plugins to override earlier ones
mFactories[factory.getLanguage()] = factory;
}
/** Remove a factory object for high-level programs of a given language. */
void removeFactory(HighLevelGpuProgramFactory factory)
{
// Remove only if equal to registered one, since it might overridden
// by other plugins
auto it = factory.getLanguage() in mFactories;
if (it !is null && *it == factory)
{
mFactories.remove(factory.getLanguage());
}
}
/** Returns whether a given high-level language is supported. */
bool isLanguageSupported(string lang)
{
return (lang in mFactories) !is null;
}
/** Create a new, unloaded HighLevelGpuProgram.
@par
This method creates a new program of the type specified as the second and third parameters.
You will have to call further methods on the returned program in order to
define the program fully before you can load it.
@param name The identifying name of the program
@param groupName The name of the resource group which this program is
to be a member of
@param language Code of the language to use (e.g. "cg")
@param gptype The type of program to create
*/
SharedPtr!HighLevelGpuProgram createProgram(
string name,string groupName,
string language, GpuProgramType gptype)
{
//SharedPtr!Resource prg = SharedPtr!Resource(
SharedPtr!HighLevelGpuProgram prg = SharedPtr!HighLevelGpuProgram(
getFactory(language).create(this, name, getNextHandle(),
groupName, false, null));
SharedPtr!Resource ret = prg;
//SharedPtr!HighLevelGpuProgram prg = ret;
prg.getAs().setType(gptype);
prg.getAs().setSyntaxCode(language);
addImpl(ret);
// Tell resource group manager
ResourceGroupManager.getSingleton()._notifyResourceCreated(ret);
return prg;
}
} | D |
prototype Mst_Default_Sleeper(C_Npc)
{
name[0] = "Spáč";
guild = GIL_SLF;
aivar[AIV_IMPORTANT] = ID_SLEEPER;
level = 2000;
attribute[ATR_STRENGTH] = 500;
attribute[ATR_DEXTERITY] = 500;
attribute[ATR_HITPOINTS_MAX] = 1000;
attribute[ATR_HITPOINTS] = 1000;
attribute[ATR_MANA_MAX] = 500;
attribute[ATR_MANA] = 500;
protection[PROT_BLUNT] = 500;
protection[PROT_EDGE] = 500;
protection[PROT_POINT] = 1000;
protection[PROT_FIRE] = 1000;
protection[PROT_FLY] = 1000;
protection[PROT_MAGIC] = 500;
damagetype = DAM_MAGIC;
fight_tactic = FAI_SLEEPER;
senses = SENSE_HEAR | SENSE_SEE | SENSE_SMELL;
senses_range = 2000;
aivar[AIV_FINDABLE] = PASSIVE;
aivar[AIV_PCISSTRONGER] = 1200;
aivar[AIV_BEENATTACKED] = 1000;
aivar[AIV_HIGHWAYMEN] = 700;
aivar[AIV_HAS_ERPRESSED] = 5;
aivar[AIV_BEGGAR] = 10;
aivar[AIV_OBSERVEINTRUDER] = FALSE;
daily_routine = Rtn_start_Sleeper;
};
func void Set_Sleeper_Visuals()
{
Mdl_SetVisual(self,"Sleeper.mds");
Mdl_SetVisualBody(self,"Sle_Body",DEFAULT,DEFAULT,"",DEFAULT,DEFAULT,-1);
};
instance Sleeper(Mst_Default_Sleeper)
{
Set_Sleeper_Visuals();
Npc_SetToFistMode(self);
};
func void Rtn_start_Sleeper()
{
TA_Sleeper(24,0,6,0,"TPL_395");
TA_Sleeper(6,0,24,0,"TPL_395");
};
| D |
On June 4, former Liberian president Charles Taylor will be tried by the UN-backed Special Court for Sierra Leone in The Hague, where he’s been held since last year.
He was the single most powerful figure behind a series of civil wars in Liberia and Sierra Leone from 1989-2003.
Taylor pleaded innocent to 11 charges of war crimes, crimes against humanity, and violations of international human rights.
He is specifically accused of arming and training rebel groups which murdered, enslaved, raped and mutilated thousands of civilians in Sierra Leone’s bloody 10-year civil war.
He faces a life sentence if convicted.
| D |
/**
* Support for NT exception handling
*
* Compiler implementation of the
* $(LINK2 https://www.dlang.org, D programming language).
*
* Copyright: Copyright (C) 1994-1998 by Symantec
* Copyright (C) 2000-2021 by The D Language Foundation, All Rights Reserved
* Authors: $(LINK2 https://www.digitalmars.com, Walter Bright)
* License: $(LINK2 https://www.boost.org/LICENSE_1_0.txt, Boost License 1.0)
* Source: $(LINK2 https://github.com/dlang/dmd/blob/master/src/dmd/backend/nteh.d, backend/nteh.d)
* Coverage: https://codecov.io/gh/dlang/dmd/src/master/src/dmd/backend/nteh.d
*/
module dmd.backend.nteh;
version (SPP)
{
}
else
{
import core.stdc.stdio;
import core.stdc.string;
import dmd.backend.cc;
import dmd.backend.cdef;
import dmd.backend.code;
import dmd.backend.code_x86;
import dmd.backend.codebuilder : CodeBuilder;
import dmd.backend.dt;
import dmd.backend.el;
import dmd.backend.global;
import dmd.backend.oper;
import dmd.backend.rtlsym;
import dmd.backend.symtab;
import dmd.backend.ty;
import dmd.backend.type;
version (SCPP)
{
import scopeh;
}
else version (HTOD)
{
import scopeh;
}
static if (NTEXCEPTIONS)
{
extern (C++):
nothrow:
@safe:
int REGSIZE();
Symbol* except_gensym();
void except_fillInEHTable(Symbol *s);
private __gshared
{
Symbol *s_table;
Symbol *s_context;
const(char)* s_name_context_tag = "__nt_context";
const(char)* s_name_context = "__context";
const(char)* s_name_ecode = "__ecode";
const(char)* text_nt =
"struct __nt_context {" ~
"int esp; int info; int prev; int handler; int stable; int sindex; int ebp;" ~
"};\n";
}
// member stable is not used for MARS or C++
int nteh_EBPoffset_sindex() { return -4; }
int nteh_EBPoffset_prev() { return -nteh_contextsym_size() + 8; }
int nteh_EBPoffset_info() { return -nteh_contextsym_size() + 4; }
int nteh_EBPoffset_esp() { return -nteh_contextsym_size() + 0; }
int nteh_offset_sindex() { version (MARS) { return 16; } else { return 20; } }
int nteh_offset_sindex_seh() { return 20; }
int nteh_offset_info() { return 4; }
/***********************************
*/
@trusted
ubyte *nteh_context_string()
{
if (config.exe == EX_WIN32)
return cast(ubyte *)text_nt;
else
return null;
}
/*******************************
* Get symbol for scope table for current function.
* Returns:
* symbol of table
*/
@trusted
private Symbol *nteh_scopetable()
{
Symbol *s;
type *t;
if (!s_table)
{
t = type_alloc(TYint);
s = symbol_generate(SCstatic,t);
s.Sseg = UNKNOWN;
symbol_keep(s);
s_table = s;
}
return s_table;
}
/*************************************
*/
@trusted
void nteh_filltables()
{
version (MARS)
{
Symbol *s = s_table;
symbol_debug(s);
except_fillInEHTable(s);
}
}
/****************************
* Generate and output scope table.
* Not called for NTEH C++ exceptions
*/
@trusted
void nteh_gentables(Symbol *sfunc)
{
Symbol *s = s_table;
symbol_debug(s);
version (MARS)
{
//except_fillInEHTable(s);
}
else
{
/* NTEH table for C.
* The table consists of triples:
* parent index
* filter address
* handler address
*/
uint fsize = 4; // target size of function pointer
auto dtb = DtBuilder(0);
int sz = 0; // size so far
foreach (b; BlockRange(startblock))
{
if (b.BC == BC_try)
{
block *bhandler;
dtb.dword(b.Blast_index); // parent index
// If try-finally
if (b.numSucc() == 2)
{
dtb.dword(0); // filter address
bhandler = b.nthSucc(1);
assert(bhandler.BC == BC_finally);
// To successor of BC_finally block
bhandler = bhandler.nthSucc(0);
}
else // try-except
{
bhandler = b.nthSucc(1);
assert(bhandler.BC == BC_filter);
dtb.coff(bhandler.Boffset); // filter address
bhandler = b.nthSucc(2);
assert(bhandler.BC == BC_except);
}
dtb.coff(bhandler.Boffset); // handler address
sz += 4 + fsize * 2;
}
}
assert(sz != 0);
s.Sdt = dtb.finish();
}
outdata(s); // output the scope table
version (MARS)
{
nteh_framehandler(sfunc, s);
}
s_table = null;
}
/**************************
* Declare frame variables.
*/
@trusted
void nteh_declarvars(Blockx *bx)
{
Symbol *s;
//printf("nteh_declarvars()\n");
version (MARS)
{
if (!(bx.funcsym.Sfunc.Fflags3 & Fnteh)) // if haven't already done it
{ bx.funcsym.Sfunc.Fflags3 |= Fnteh;
s = symbol_name(s_name_context,SCbprel,tstypes[TYint]);
s.Soffset = -5 * 4; // -6 * 4 for C __try, __except, __finally
s.Sflags |= SFLfree | SFLnodebug;
type_setty(&s.Stype,mTYvolatile | TYint);
symbol_add(s);
bx.context = s;
}
}
else
{
if (!(funcsym_p.Sfunc.Fflags3 & Fnteh)) // if haven't already done it
{ funcsym_p.Sfunc.Fflags3 |= Fnteh;
if (!s_context)
s_context = scope_search(s_name_context_tag, CPP ? SCTglobal : SCTglobaltag);
symbol_debug(s_context);
s = symbol_name(s_name_context,SCbprel,s_context.Stype);
s.Soffset = -6 * 4; // -5 * 4 for C++
s.Sflags |= SFLfree;
symbol_add(s);
type_setty(&s.Stype,mTYvolatile | TYstruct);
s = symbol_name(s_name_ecode,SCauto,type_alloc(mTYvolatile | TYint));
s.Sflags |= SFLfree;
symbol_add(s);
}
}
}
/**************************************
* Generate elem that sets the context index into the scope table.
*/
version (MARS)
{
elem *nteh_setScopeTableIndex(Blockx *blx, int scope_index)
{
elem *e;
Symbol *s;
s = blx.context;
symbol_debug(s);
e = el_var(s);
e.EV.Voffset = nteh_offset_sindex();
return el_bin(OPeq, TYint, e, el_long(TYint, scope_index));
}
}
/**********************************
* Return pointer to context symbol.
*/
@trusted
Symbol *nteh_contextsym()
{
for (SYMIDX si = 0; 1; si++)
{ assert(si < globsym.length);
Symbol* sp = globsym[si];
symbol_debug(sp);
if (strcmp(sp.Sident.ptr,s_name_context) == 0)
return sp;
}
}
/**********************************
* Return size of context symbol on stack.
*/
@trusted
uint nteh_contextsym_size()
{
int sz;
if (usednteh & NTEH_try)
{
version (MARS)
{
sz = 5 * 4;
}
else version (SCPP)
{
sz = 6 * 4;
}
else version (HTOD)
{
sz = 6 * 4;
}
else
static assert(0);
}
else if (usednteh & NTEHcpp)
{
sz = 5 * 4; // C++ context record
}
else if (usednteh & NTEHpassthru)
{
sz = 1 * 4;
}
else
sz = 0; // no context record
return sz;
}
/**********************************
* Return pointer to ecode symbol.
*/
@trusted
Symbol *nteh_ecodesym()
{
SYMIDX si;
Symbol *sp;
for (si = 0; 1; si++)
{ assert(si < globsym.length);
sp = globsym[si];
symbol_debug(sp);
if (strcmp(sp.Sident.ptr, s_name_ecode) == 0)
return sp;
}
}
/*********************************
* Mark EH variables as used so that they don't get optimized away.
*/
void nteh_usevars()
{
version (SCPP)
{
// Turn off SFLdead and SFLunambig in Sflags
nteh_contextsym().Sflags &= ~(SFLdead | SFLunambig);
nteh_contextsym().Sflags |= SFLread;
nteh_ecodesym().Sflags &= ~(SFLdead | SFLunambig);
nteh_ecodesym().Sflags |= SFLread;
}
else
{
// Turn off SFLdead and SFLunambig in Sflags
nteh_contextsym().Sflags &= ~SFLdead;
nteh_contextsym().Sflags |= SFLread;
}
}
/*********************************
* Generate NT exception handling function prolog.
*/
@trusted
void nteh_prolog(ref CodeBuilder cdb)
{
code cs;
if (usednteh & NTEHpassthru)
{
/* An sindex value of -2 is a magic value that tells the
* stack unwinder to skip this frame.
*/
assert(config.exe & EX_posix);
cs.Iop = 0x68;
cs.Iflags = 0;
cs.Irex = 0;
cs.IFL2 = FLconst;
cs.IEV2.Vint = -2;
cdb.gen(&cs); // PUSH -2
return;
}
/* Generate instance of struct __nt_context on stack frame:
[ ] // previous ebp already there
push -1 // sindex
mov EDX,FS:__except_list
push offset FLAT:scope_table // stable (not for MARS or C++)
push offset FLAT:__except_handler3 // handler
push EDX // prev
mov FS:__except_list,ESP
sub ESP,8 // info, esp for __except support
*/
// useregs(mAX); // What is this for?
cs.Iop = 0x68;
cs.Iflags = 0;
cs.Irex = 0;
cs.IFL2 = FLconst;
cs.IEV2.Vint = -1;
cdb.gen(&cs); // PUSH -1
version (MARS)
{
// PUSH &framehandler
cs.IFL2 = FLframehandler;
nteh_scopetable();
}
else
{
if (usednteh & NTEHcpp)
{
// PUSH &framehandler
cs.IFL2 = FLframehandler;
}
else
{
// Do stable
cs.Iflags |= CFoff;
cs.IFL2 = FLextern;
cs.IEV2.Vsym = nteh_scopetable();
cs.IEV2.Voffset = 0;
cdb.gen(&cs); // PUSH &scope_table
cs.IFL2 = FLextern;
cs.IEV2.Vsym = getRtlsym(RTLSYM.EXCEPT_HANDLER3);
makeitextern(getRtlsym(RTLSYM.EXCEPT_HANDLER3));
}
}
CodeBuilder cdb2;
cdb2.ctor();
cdb2.gen(&cs); // PUSH &__except_handler3
if (config.exe == EX_WIN32)
{
makeitextern(getRtlsym(RTLSYM.EXCEPT_LIST));
static if (0)
{
cs.Iop = 0xFF;
cs.Irm = modregrm(0,6,BPRM);
cs.Iflags = CFfs;
cs.Irex = 0;
cs.IFL1 = FLextern;
cs.IEV1.Vsym = getRtlsym(RTLSYM.EXCEPT_LIST);
cs.IEV1.Voffset = 0;
cdb2.gen(&cs); // PUSH FS:__except_list
}
else
{
useregs(mDX);
cs.Iop = 0x8B;
cs.Irm = modregrm(0,DX,BPRM);
cs.Iflags = CFfs;
cs.Irex = 0;
cs.IFL1 = FLextern;
cs.IEV1.Vsym = getRtlsym(RTLSYM.EXCEPT_LIST);
cs.IEV1.Voffset = 0;
cdb.gen(&cs); // MOV EDX,FS:__except_list
cdb2.gen1(0x50 + DX); // PUSH EDX
}
cs.Iop = 0x89;
NEWREG(cs.Irm,SP);
cdb2.gen(&cs); // MOV FS:__except_list,ESP
}
cdb.append(cdb2);
cod3_stackadj(cdb, 8);
}
/*********************************
* Generate NT exception handling function epilog.
*/
@trusted
void nteh_epilog(ref CodeBuilder cdb)
{
if (config.exe != EX_WIN32)
return;
/* Generate:
mov ECX,__context[EBP].prev
mov FS:__except_list,ECX
*/
code cs;
reg_t reg;
version (MARS)
reg = CX;
else
reg = (tybasic(funcsym_p.Stype.Tnext.Tty) == TYvoid) ? AX : CX;
useregs(1 << reg);
cs.Iop = 0x8B;
cs.Irm = modregrm(2,reg,BPRM);
cs.Iflags = 0;
cs.Irex = 0;
cs.IFL1 = FLconst;
// EBP offset of __context.prev
cs.IEV1.Vint = nteh_EBPoffset_prev();
cdb.gen(&cs);
cs.Iop = 0x89;
cs.Irm = modregrm(0,reg,BPRM);
cs.Iflags |= CFfs;
cs.IFL1 = FLextern;
cs.IEV1.Vsym = getRtlsym(RTLSYM.EXCEPT_LIST);
cs.IEV1.Voffset = 0;
cdb.gen(&cs);
}
/**************************
* Set/Reset ESP from context.
*/
@trusted
void nteh_setsp(ref CodeBuilder cdb, opcode_t op)
{
code cs;
cs.Iop = op;
cs.Irm = modregrm(2,SP,BPRM);
cs.Iflags = 0;
cs.Irex = 0;
cs.IFL1 = FLconst;
// EBP offset of __context.esp
cs.IEV1.Vint = nteh_EBPoffset_esp();
cdb.gen(&cs); // MOV ESP,__context[EBP].esp
}
/****************************
* Put out prolog for BC_filter block.
*/
@trusted
void nteh_filter(ref CodeBuilder cdb, block *b)
{
code cs;
assert(b.BC == BC_filter);
if (b.Bflags & BFLehcode) // if referenced __ecode
{
/* Generate:
mov EAX,__context[EBP].info
mov EAX,[EAX]
mov EAX,[EAX]
mov __ecode[EBP],EAX
*/
getregs(cdb,mAX);
cs.Iop = 0x8B;
cs.Irm = modregrm(2,AX,BPRM);
cs.Iflags = 0;
cs.Irex = 0;
cs.IFL1 = FLconst;
// EBP offset of __context.info
cs.IEV1.Vint = nteh_EBPoffset_info();
cdb.gen(&cs); // MOV EAX,__context[EBP].info
cs.Irm = modregrm(0,AX,0);
cdb.gen(&cs); // MOV EAX,[EAX]
cdb.gen(&cs); // MOV EAX,[EAX]
cs.Iop = 0x89;
cs.Irm = modregrm(2,AX,BPRM);
cs.IFL1 = FLauto;
cs.IEV1.Vsym = nteh_ecodesym();
cs.IEV1.Voffset = 0;
cdb.gen(&cs); // MOV __ecode[EBP],EAX
}
}
/*******************************
* Generate C++ or D frame handler.
*/
void nteh_framehandler(Symbol *sfunc, Symbol *scopetable)
{
// Generate:
// MOV EAX,&scope_table
// JMP __cpp_framehandler
if (scopetable)
{
symbol_debug(scopetable);
CodeBuilder cdb;
cdb.ctor();
cdb.gencs(0xB8+AX,0,FLextern,scopetable); // MOV EAX,&scope_table
version (MARS)
cdb.gencs(0xE9,0,FLfunc,getRtlsym(RTLSYM.D_HANDLER)); // JMP _d_framehandler
else
cdb.gencs(0xE9,0,FLfunc,getRtlsym(RTLSYM.CPP_HANDLER)); // JMP __cpp_framehandler
code *c = cdb.finish();
pinholeopt(c,null);
codout(sfunc.Sseg,c);
code_free(c);
}
}
/*********************************
* Generate code to set scope index.
*/
code *nteh_patchindex(code* c, int sindex)
{
c.IEV2.Vsize_t = sindex;
return c;
}
@trusted
void nteh_gensindex(ref CodeBuilder cdb, int sindex)
{
if (!(config.ehmethod == EHmethod.EH_WIN32 || config.ehmethod == EHmethod.EH_SEH) || funcsym_p.Sfunc.Fflags3 & Feh_none)
return;
// Generate:
// MOV -4[EBP],sindex
cdb.genc(0xC7,modregrm(1,0,BP),FLconst,cast(targ_uns)nteh_EBPoffset_sindex(),FLconst,sindex); // 7 bytes long
cdb.last().Iflags |= CFvolatile;
//assert(GENSINDEXSIZE == calccodsize(c));
}
/*********************************
* Generate code for setjmp().
*/
@trusted
void cdsetjmp(ref CodeBuilder cdb, elem *e,regm_t *pretregs)
{
code cs;
regm_t retregs;
uint stackpushsave;
uint flag;
stackpushsave = stackpush;
version (SCPP)
{
if (CPP && (funcsym_p.Sfunc.Fflags3 & Fcppeh || usednteh & NTEHcpp))
{
/* If in C++ try block
If the frame that is calling setjmp has a try,catch block then
the call to setjmp3 is as follows:
__setjmp3(environment,3,__cpp_longjmp_unwind,trylevel,funcdata);
__cpp_longjmp_unwind is a routine in the RTL. This is a
stdcall routine that will deal with unwinding for CPP Frames.
trylevel is the value that gets incremented at each catch,
constructor invocation.
funcdata is the same value that you put into EAX prior to
cppframehandler getting called.
*/
Symbol *s;
s = except_gensym();
if (!s)
goto L1;
cdb.gencs(0x68,0,FLextern,s); // PUSH &scope_table
stackpush += 4;
cdb.genadjesp(4);
cdb.genc1(0xFF,modregrm(1,6,BP),FLconst,cast(targ_uns)-4);
// PUSH trylevel
stackpush += 4;
cdb.genadjesp(4);
cs.Iop = 0x68;
cs.Iflags = CFoff;
cs.Irex = 0;
cs.IFL2 = FLextern;
cs.IEV2.Vsym = getRtlsym(RTLSYM.CPP_LONGJMP);
cs.IEV2.Voffset = 0;
cdb.gen(&cs); // PUSH &_cpp_longjmp_unwind
stackpush += 4;
cdb.genadjesp(4);
flag = 3;
goto L2;
}
}
if (funcsym_p.Sfunc.Fflags3 & Fnteh)
{
/* If in NT SEH try block
If the frame that is calling setjmp has a try, except block
then the call to setjmp3 is as follows:
__setjmp3(environment,2,__seh_longjmp_unwind,trylevel);
__seth_longjmp_unwind is supplied by the RTL and is a stdcall
function. It is the name that MSOFT uses, we should
probably use the same one.
trylevel is the value that you increment at each try and
decrement at the close of the try. This corresponds to the
index field of the ehrec.
*/
int sindex_off;
sindex_off = 20; // offset of __context.sindex
cs.Iop = 0xFF;
cs.Irm = modregrm(2,6,BPRM);
cs.Iflags = 0;
cs.Irex = 0;
cs.IFL1 = FLbprel;
cs.IEV1.Vsym = nteh_contextsym();
cs.IEV1.Voffset = sindex_off;
cdb.gen(&cs); // PUSH scope_index
stackpush += 4;
cdb.genadjesp(4);
cs.Iop = 0x68;
cs.Iflags = CFoff;
cs.Irex = 0;
cs.IFL2 = FLextern;
cs.IEV2.Vsym = getRtlsym(RTLSYM.LONGJMP);
cs.IEV2.Voffset = 0;
cdb.gen(&cs); // PUSH &_seh_longjmp_unwind
stackpush += 4;
cdb.genadjesp(4);
flag = 2;
}
else
{
/* If the frame calling setjmp has neither a try..except, nor a
try..catch, then call setjmp3 as follows:
_setjmp3(environment,0)
*/
L1:
flag = 0;
}
L2:
cs.Iop = 0x68;
cs.Iflags = 0;
cs.Irex = 0;
cs.IFL2 = FLconst;
cs.IEV2.Vint = flag;
cdb.gen(&cs); // PUSH flag
stackpush += 4;
cdb.genadjesp(4);
pushParams(cdb,e.EV.E1,REGSIZE, TYnfunc);
getregs(cdb,~getRtlsym(RTLSYM.SETJMP3).Sregsaved & (ALLREGS | mES));
cdb.gencs(0xE8,0,FLfunc,getRtlsym(RTLSYM.SETJMP3)); // CALL __setjmp3
cod3_stackadj(cdb, -(stackpush - stackpushsave));
cdb.genadjesp(-(stackpush - stackpushsave));
stackpush = stackpushsave;
retregs = regmask(e.Ety, TYnfunc);
fixresult(cdb,e,retregs,pretregs);
}
/****************************************
* Call _local_unwind(), which means call the __finally blocks until
* stop_index is reached.
* Params:
* cdb = append generated code to
* saveregs = registers to save across the generated code
* stop_index = index to stop at
*/
@trusted
void nteh_unwind(ref CodeBuilder cdb,regm_t saveregs,uint stop_index)
{
// Shouldn't this always be CX?
version (SCPP)
const reg_t reg = AX;
else
const reg_t reg = CX;
version (MARS)
// https://github.com/dlang/druntime/blob/master/src/rt/deh_win32.d#L924
const local_unwind = RTLSYM.D_LOCAL_UNWIND2; // __d_local_unwind2()
else
// dm/src/win32/ehsup.c
const local_unwind = RTLSYM.LOCAL_UNWIND2; // __local_unwind2()
const regm_t desregs = (~getRtlsym(local_unwind).Sregsaved & (ALLREGS)) | (1 << reg);
CodeBuilder cdbs;
cdbs.ctor();
CodeBuilder cdbr;
cdbr.ctor();
gensaverestore(saveregs & desregs,cdbs,cdbr);
CodeBuilder cdbx;
cdbx.ctor();
getregs(cdbx,desregs);
code cs;
cs.Iop = LEA;
cs.Irm = modregrm(2,reg,BPRM);
cs.Iflags = 0;
cs.Irex = 0;
cs.IFL1 = FLconst;
// EBP offset of __context.prev
cs.IEV1.Vint = nteh_EBPoffset_prev();
cdbx.gen(&cs); // LEA ECX,contextsym
int nargs = 0;
version (SCPP)
{
const int take_addr = 1;
cdbx.genc2(0x68,0,take_addr); // PUSH take_addr
++nargs;
}
cdbx.genc2(0x68,0,stop_index); // PUSH stop_index
cdbx.gen1(0x50 + reg); // PUSH ECX ; DEstablisherFrame
nargs += 2;
version (MARS)
{
cdbx.gencs(0x68,0,FLextern,nteh_scopetable()); // PUSH &scope_table ; DHandlerTable
++nargs;
}
cdbx.gencs(0xE8,0,FLfunc,getRtlsym(local_unwind)); // CALL _local_unwind()
cod3_stackadj(cdbx, -nargs * 4);
cdb.append(cdbs);
cdb.append(cdbx);
cdb.append(cdbr);
}
/*************************************************
* Set monitor, hook monitor exception handler.
*/
version (MARS)
{
@trusted
void nteh_monitor_prolog(ref CodeBuilder cdb, Symbol *shandle)
{
/*
* PUSH handle
* PUSH offset _d_monitor_handler
* PUSH FS:__except_list
* MOV FS:__except_list,ESP
* CALL _d_monitor_prolog
*/
CodeBuilder cdbx;
cdbx.ctor();
assert(config.exe == EX_WIN32); // BUG: figure out how to implement for other EX's
if (shandle.Sclass == SCfastpar)
{ assert(shandle.Spreg != DX);
assert(shandle.Spreg2 == NOREG);
cdbx.gen1(0x50 + shandle.Spreg); // PUSH shandle
}
else
{
// PUSH shandle
useregs(mCX);
cdbx.genc1(0x8B,modregrm(2,CX,4),FLconst,4 * (1 + needframe) + shandle.Soffset + localsize);
cdbx.last().Isib = modregrm(0,4,SP);
cdbx.gen1(0x50 + CX); // PUSH ECX
}
Symbol *smh = getRtlsym(RTLSYM.MONITOR_HANDLER);
cdbx.gencs(0x68,0,FLextern,smh); // PUSH offset _d_monitor_handler
makeitextern(smh);
code cs;
useregs(mDX);
cs.Iop = 0x8B;
cs.Irm = modregrm(0,DX,BPRM);
cs.Iflags = CFfs;
cs.Irex = 0;
cs.IFL1 = FLextern;
cs.IEV1.Vsym = getRtlsym(RTLSYM.EXCEPT_LIST);
cs.IEV1.Voffset = 0;
cdb.gen(&cs); // MOV EDX,FS:__except_list
cdbx.gen1(0x50 + DX); // PUSH EDX
Symbol *s = getRtlsym(RTLSYM.MONITOR_PROLOG);
regm_t desregs = ~s.Sregsaved & ALLREGS;
getregs(cdbx,desregs);
cdbx.gencs(0xE8,0,FLfunc,s); // CALL _d_monitor_prolog
cs.Iop = 0x89;
NEWREG(cs.Irm,SP);
cdbx.gen(&cs); // MOV FS:__except_list,ESP
cdb.append(cdbx);
}
}
/*************************************************
* Release monitor, unhook monitor exception handler.
* Input:
* retregs registers to not destroy
*/
version (MARS)
{
@trusted
void nteh_monitor_epilog(ref CodeBuilder cdb,regm_t retregs)
{
/*
* CALL _d_monitor_epilog
* POP FS:__except_list
*/
assert(config.exe == EX_WIN32); // BUG: figure out how to implement for other EX's
Symbol *s = getRtlsym(RTLSYM.MONITOR_EPILOG);
//desregs = ~s.Sregsaved & ALLREGS;
regm_t desregs = 0;
CodeBuilder cdbs;
cdbs.ctor();
CodeBuilder cdbr;
cdbr.ctor();
gensaverestore(retregs& desregs,cdbs,cdbr);
cdb.append(cdbs);
getregs(cdb,desregs);
cdb.gencs(0xE8,0,FLfunc,s); // CALL __d_monitor_epilog
cdb.append(cdbr);
code cs;
cs.Iop = 0x8F;
cs.Irm = modregrm(0,0,BPRM);
cs.Iflags = CFfs;
cs.Irex = 0;
cs.IFL1 = FLextern;
cs.IEV1.Vsym = getRtlsym(RTLSYM.EXCEPT_LIST);
cs.IEV1.Voffset = 0;
cdb.gen(&cs); // POP FS:__except_list
}
}
}
}
| D |
/**
DMD compiler support.
Copyright: © 2013-2013 rejectedsoftware e.K.
License: Subject to the terms of the MIT license, as written in the included LICENSE.txt file.
Authors: Sönke Ludwig
*/
module dub.compilers.dmd;
import dub.compilers.compiler;
import dub.internal.utils;
import dub.internal.vibecompat.core.log;
import dub.internal.vibecompat.inet.path;
import dub.platform;
import std.algorithm;
import std.array;
import std.conv;
import std.exception;
import std.file;
import std.process;
import std.random;
import std.typecons;
class DmdCompiler : Compiler {
private static immutable s_options = [
tuple(BuildOptions.debugMode, ["-debug"]),
tuple(BuildOptions.releaseMode, ["-release"]),
tuple(BuildOptions.coverage, ["-cov"]),
tuple(BuildOptions.debugInfo, ["-g"]),
tuple(BuildOptions.debugInfoC, ["-gc"]),
tuple(BuildOptions.alwaysStackFrame, ["-gs"]),
tuple(BuildOptions.stackStomping, ["-gx"]),
tuple(BuildOptions.inline, ["-inline"]),
tuple(BuildOptions.noBoundsCheck, ["-noboundscheck"]),
tuple(BuildOptions.optimize, ["-O"]),
tuple(BuildOptions.profile, ["-profile"]),
tuple(BuildOptions.unittests, ["-unittest"]),
tuple(BuildOptions.verbose, ["-v"]),
tuple(BuildOptions.ignoreUnknownPragmas, ["-ignore"]),
tuple(BuildOptions.syntaxOnly, ["-o-"]),
tuple(BuildOptions.warnings, ["-wi"]),
tuple(BuildOptions.warningsAsErrors, ["-w"]),
tuple(BuildOptions.ignoreDeprecations, ["-d"]),
tuple(BuildOptions.deprecationWarnings, ["-dw"]),
tuple(BuildOptions.deprecationErrors, ["-de"]),
tuple(BuildOptions.property, ["-property"]),
];
@property string name() const { return "dmd"; }
BuildPlatform determinePlatform(ref BuildSettings settings, string compiler_binary, string arch_override)
{
// TODO: determine platform by invoking the compiler instead
BuildPlatform build_platform;
build_platform.platform = .determinePlatform();
build_platform.architecture = .determineArchitecture();
build_platform.compiler = this.name;
build_platform.compilerBinary = compiler_binary;
switch (arch_override) {
default: throw new Exception("Unsupported architecture: "~arch_override);
case "": break;
case "x86":
build_platform.architecture = ["x86"];
settings.addDFlags("-m32");
break;
case "x86_64":
build_platform.architecture = ["x86_64"];
settings.addDFlags("-m64");
break;
}
return build_platform;
}
void prepareBuildSettings(ref BuildSettings settings, BuildSetting fields = BuildSetting.all)
{
enforceBuildRequirements(settings);
if (!(fields & BuildSetting.options)) {
foreach (t; s_options)
if (settings.options & t[0])
settings.addDFlags(t[1]);
}
if (!(fields & BuildSetting.libs)) {
resolveLibs(settings);
version(Windows) settings.addSourceFiles(settings.libs.map!(l => l~".lib")().array());
else settings.addLFlags(settings.libs.map!(l => "-l"~l)().array());
}
if (!(fields & BuildSetting.versions)) {
settings.addDFlags(settings.versions.map!(s => "-version="~s)().array());
settings.versions = null;
}
if (!(fields & BuildSetting.debugVersions)) {
settings.addDFlags(settings.debugVersions.map!(s => "-debug="~s)().array());
settings.debugVersions = null;
}
if (!(fields & BuildSetting.importPaths)) {
settings.addDFlags(settings.importPaths.map!(s => "-I"~s)().array());
settings.importPaths = null;
}
if (!(fields & BuildSetting.stringImportPaths)) {
settings.addDFlags(settings.stringImportPaths.map!(s => "-J"~s)().array());
settings.stringImportPaths = null;
}
if (!(fields & BuildSetting.sourceFiles)) {
settings.addDFlags(settings.sourceFiles);
settings.sourceFiles = null;
}
if (!(fields & BuildSetting.lflags)) {
settings.addDFlags(settings.lflags.map!(f => "-L"~f)().array());
settings.lflags = null;
}
assert(fields & BuildSetting.dflags);
assert(fields & BuildSetting.copyFiles);
}
void extractBuildOptions(ref BuildSettings settings)
{
Appender!(string[]) newflags;
next_flag: foreach (f; settings.dflags) {
foreach (t; s_options)
if (t[1].canFind(f)) {
settings.options |= t[0];
continue next_flag;
}
if (f.startsWith("-version=")) settings.addVersions(f[9 .. $]);
else if (f.startsWith("-debug=")) settings.addDebugVersions(f[7 .. $]);
else newflags ~= f;
}
settings.dflags = newflags.data;
}
void setTarget(ref BuildSettings settings, in BuildPlatform platform)
{
final switch (settings.targetType) {
case TargetType.autodetect: assert(false, "Invalid target type: autodetect");
case TargetType.none: assert(false, "Invalid target type: none");
case TargetType.sourceLibrary: assert(false, "Invalid target type: sourceLibrary");
case TargetType.executable: break;
case TargetType.library:
case TargetType.staticLibrary:
settings.addDFlags("-lib");
break;
case TargetType.dynamicLibrary:
version (Windows) settings.addDFlags("-shared");
else settings.addDFlags("-shared", "-fPIC");
break;
}
auto tpath = Path(settings.targetPath) ~ getTargetFileName(settings, platform);
settings.addDFlags("-of"~tpath.toNativeString());
}
void invoke(in BuildSettings settings, in BuildPlatform platform)
{
auto res_file = getTempDir() ~ ("dub-build-"~uniform(0, uint.max).to!string~"-.rsp");
std.file.write(res_file.toNativeString(), join(settings.dflags.map!(s => s.canFind(' ') ? "\""~s~"\"" : s), "\n"));
scope (exit) remove(res_file.toNativeString());
logDiagnostic("%s %s", platform.compilerBinary, join(cast(string[])settings.dflags, " "));
auto compiler_pid = spawnProcess([platform.compilerBinary, "@"~res_file.toNativeString()]);
auto result = compiler_pid.wait();
enforce(result == 0, "DMD compile run failed with exit code "~to!string(result));
}
void invokeLinker(in BuildSettings settings, in BuildPlatform platform, string[] objects)
{
import std.string;
auto tpath = Path(settings.targetPath) ~ getTargetFileName(settings, platform);
auto args = [platform.compiler, "-of"~tpath.toNativeString()];
args ~= objects;
args ~= settings.sourceFiles;
version(linux) args ~= "-L--no-as-needed"; // avoids linker errors due to libraries being speficied in the wrong order by DMD
args ~= settings.lflags.map!(l => "-L"~l)().array;
static linkerargs = ["-g", "-gc", "-m32", "-m64", "-shared"];
args ~= settings.dflags.filter!(f => linkerargs.canFind(f))().array();
logDiagnostic("%s", args.join(" "));
auto res = spawnProcess(args).wait();
enforce(res == 0, "Link command failed with exit code "~to!string(res));
}
}
| D |
module ut.old.type;
import dpp.from;
import dpp.test;
import dpp.translation.type;
import clang: Type;
string translate(in from!"clang".Type type) @safe pure {
import dpp.translation.type: translate_ = translate;
import dpp.runtime.context: Context;
Context context;
return translate_(type, context);
}
@("void")
@safe pure unittest {
Type(Type.Kind.Void).translate.shouldEqual("void");
}
@("bool")
@safe pure unittest {
Type(Type.Kind.Bool).translate.shouldEqual("bool");
}
@("char_u")
@safe pure unittest {
Type(Type.Kind.Char_U).translate.shouldEqual("ubyte");
}
@("UChar")
@safe pure unittest {
Type(Type.Kind.UChar).translate.shouldEqual("ubyte");
}
@("Char16")
@safe pure unittest {
Type(Type.Kind.Char16).translate.shouldEqual("wchar");
}
@("Char32")
@safe pure unittest {
Type(Type.Kind.Char32).translate.shouldEqual("dchar");
}
@("unsigned short")
@safe pure unittest {
Type(Type.Kind.UShort).translate.shouldEqual("ushort");
}
@("unsigned int")
@safe pure unittest {
Type(Type.Kind.UInt).translate.shouldEqual("uint");
}
@("unsigned long")
@safe pure unittest {
Type(Type.Kind.ULong).translate.shouldEqual("c_ulong");
}
@("unsigned long long")
@safe pure unittest {
Type(Type.Kind.ULongLong).translate.shouldEqual("ulong");
}
@("uint128")
@safe pure unittest {
Type(Type.Kind.UInt128).translate.shouldEqual("UInt128");
}
@("char_s")
@safe pure unittest {
Type(Type.Kind.Char_S).translate.shouldEqual("char");
}
@("SChar")
@safe pure unittest {
Type(Type.Kind.SChar).translate.shouldEqual("byte");
}
@("WChar")
@safe pure unittest {
Type(Type.Kind.WChar).translate.shouldEqual("wchar");
}
@("short")
@safe pure unittest {
Type(Type.Kind.Short).translate.shouldEqual("short");
}
@("int")
@safe pure unittest {
Type(Type.Kind.Int).translate.shouldEqual("int");
}
@("long")
@safe pure unittest {
Type(Type.Kind.Long).translate.shouldEqual("c_long");
}
@("long long")
@safe pure unittest {
Type(Type.Kind.LongLong).translate.shouldEqual("long");
}
@("int128")
@safe pure unittest {
Type(Type.Kind.Int128).translate.shouldEqual("Int128");
}
@("float")
@safe pure unittest {
Type(Type.Kind.Float).translate.shouldEqual("float");
}
@("double")
@safe pure unittest {
Type(Type.Kind.Double).translate.shouldEqual("double");
}
@("long double")
@safe pure unittest {
Type(Type.Kind.LongDouble).translate.shouldEqual("real");
}
@("nullptr")
@safe pure unittest {
Type(Type.Kind.NullPtr).translate.shouldEqual("void*");
}
@("float128")
@safe pure unittest {
Type(Type.Kind.Float128).translate.shouldEqual("real");
}
@("half")
@safe pure unittest {
Type(Type.Kind.Half).translate.shouldEqual("float");
}
| D |
/*******************************************************************************
* Copyright (c) 2000, 2008 IBM Corporation and others.
* All rights reserved. This program and the accompanying materials
* are made available under the terms of the Eclipse Public License v1.0
* which accompanies this distribution, and is available at
* http://www.eclipse.org/legal/epl-v10.html
*
* Contributors:
* IBM Corporation - initial API and implementation
* Port to the D programming language:
* Frank Benoit <benoit@tionex.de>
*******************************************************************************/
module org.eclipse.swt.widgets.DirectoryDialog;
import org.eclipse.swt.widgets.Display;
import org.eclipse.swt.widgets.Dialog;
import org.eclipse.swt.widgets.Shell;
import org.eclipse.swt.SWT;
import org.eclipse.swt.SWTException;
import org.eclipse.swt.internal.win32.OS;
import org.eclipse.swt.internal.C;
import java.lang.all;
/**
* Instances of this class allow the user to navigate
* the file system and select a directory.
* <dl>
* <dt><b>Styles:</b></dt>
* <dd>(none)</dd>
* <dt><b>Events:</b></dt>
* <dd>(none)</dd>
* </dl>
* <p>
* IMPORTANT: This class is intended to be subclassed <em>only</em>
* within the SWT implementation.
* </p>
*
* @see <a href="http://www.eclipse.org/swt/snippets/#directorydialog">DirectoryDialog snippets</a>
* @see <a href="http://www.eclipse.org/swt/examples.php">SWT Example: ControlExample, Dialog tab</a>
* @see <a href="http://www.eclipse.org/swt/">Sample code and further information</a>
*/
public class DirectoryDialog : Dialog {
static String message = "";
static String filterPath = ""; //$NON-NLS-1$//$NON-NLS-2$
static String directoryPath;
/**
* Constructs a new instance of this class given only its parent.
*
* @param parent a shell which will be the parent of the new instance
*
* @exception IllegalArgumentException <ul>
* <li>ERROR_NULL_ARGUMENT - if the parent is null</li>
* </ul>
* @exception SWTException <ul>
* <li>ERROR_THREAD_INVALID_ACCESS - if not called from the thread that created the parent</li>
* <li>ERROR_INVALID_SUBCLASS - if this class is not an allowed subclass</li>
* </ul>
*/
public this (Shell parent) {
this (parent, SWT.APPLICATION_MODAL);
}
/**
* Constructs a new instance of this class given its parent
* and a style value describing its behavior and appearance.
* <p>
* The style value is either one of the style constants defined in
* class <code>SWT</code> which is applicable to instances of this
* class, or must be built by <em>bitwise OR</em>'ing together
* (that is, using the <code>int</code> "|" operator) two or more
* of those <code>SWT</code> style constants. The class description
* lists the style constants that are applicable to the class.
* Style bits are also inherited from superclasses.
* </p>
*
* @param parent a shell which will be the parent of the new instance
* @param style the style of dialog to construct
*
* @exception IllegalArgumentException <ul>
* <li>ERROR_NULL_ARGUMENT - if the parent is null</li>
* </ul>
* @exception SWTException <ul>
* <li>ERROR_THREAD_INVALID_ACCESS - if not called from the thread that created the parent</li>
* <li>ERROR_INVALID_SUBCLASS - if this class is not an allowed subclass</li>
* </ul>
*/
public this (Shell parent, int style) {
super (parent, checkStyle (parent, style));
checkSubclass ();
}
extern(Windows)static int BrowseCallbackProc (HWND hwnd, uint uMsg, int lParam, int lpData) {
DirectoryDialog pThis = cast(DirectoryDialog)cast(void*)lpData;
switch (uMsg) {
case OS.BFFM_INITIALIZED:
if (pThis.filterPath !is null && pThis.filterPath.length !is 0) {
/* Use the character encoding for the default locale */
StringT buffer = StrToTCHARs (0, pThis.filterPath.replace ('/', '\\'), true);
OS.SendMessage (hwnd, OS.BFFM_SETSELECTION, 1, cast(void*)buffer.ptr);
}
if (pThis.title !is null && pThis.title.length !is 0) {
/* Use the character encoding for the default locale */
StringT buffer = StrToTCHARs (0, pThis.title, true);
OS.SetWindowText (hwnd, buffer.ptr);
}
break;
case OS.BFFM_VALIDATEFAILEDA:
case OS.BFFM_VALIDATEFAILEDW:
/* Use the character encoding for the default locale */
// int length = OS.IsUnicode ? OS.wcslen (lParam) : OS.strlen (lParam);
// TCHAR buffer = new TCHAR (0, length);
// int byteCount = cast(int) buffer.length * TCHAR.sizeof;
// OS.MoveMemory (buffer, lParam, byteCount);
// directoryPath = buffer.toString (0, length);
pThis.directoryPath = TCHARzToStr( cast(TCHAR*)lParam );
break;
default:
}
return 0;
}
/**
* Returns the path which the dialog will use to filter
* the directories it shows.
*
* @return the filter path
*
* @see #setFilterPath
*/
public String getFilterPath () {
return filterPath;
}
/**
* Returns the dialog's message, which is a description of
* the purpose for which it was opened. This message will be
* visible on the dialog while it is open.
*
* @return the message
*/
public String getMessage () {
return message;
}
/**
* Makes the dialog visible and brings it to the front
* of the display.
*
* @return a string describing the absolute path of the selected directory,
* or null if the dialog was cancelled or an error occurred
*
* @exception SWTException <ul>
* <li>ERROR_WIDGET_DISPOSED - if the dialog has been disposed</li>
* <li>ERROR_THREAD_INVALID_ACCESS - if not called from the thread that created the dialog</li>
* </ul>
*/
public String open () {
if (OS.IsWinCE) SWT.error (SWT.ERROR_NOT_IMPLEMENTED);
auto hHeap = OS.GetProcessHeap ();
/* Get the owner HWND for the dialog */
HWND hwndOwner;
if (parent !is null) hwndOwner = parent.handle;
/* Copy the message to OS memory */
TCHAR* lpszTitle;
if (message.length !is 0) {
String string = message;
if (string.indexOf ('&') !is -1) {
int length = cast(int) string.length;
char [] buffer = new char [length * 2];
int index = 0;
for (int i=0; i<length; i++) {
char ch = string.charAt (i);
if (ch is '&') buffer [index++] = '&';
buffer [index++] = ch;
}
// string = new String (buffer, 0, index);
}
/* Use the character encoding for the default locale */
StringT buffer = StrToTCHARs (0, string, true);
int byteCount = cast(int) (buffer.length * TCHAR.sizeof);
lpszTitle = cast(TCHAR*)OS.HeapAlloc (hHeap, OS.HEAP_ZERO_MEMORY, byteCount);
OS.MoveMemory (lpszTitle, buffer.ptr, byteCount);
}
/* Create the BrowseCallbackProc */
/+ Callback callback = new Callback (this, "BrowseCallbackProc", 4); //$NON-NLS-1$
int lpfn = callback.getAddress ();+/
BFFCALLBACK lpfn = &BrowseCallbackProc;
if (lpfn is null) SWT.error (SWT.ERROR_NO_MORE_CALLBACKS);
/* Make the parent shell be temporary modal */
Dialog oldModal = null;
Display display = parent.getDisplay ();
if ((style & (SWT.APPLICATION_MODAL | SWT.SYSTEM_MODAL)) !is 0) {
oldModal = display.getModalDialog ();
display.setModalDialog (this);
}
directoryPath = null;
BROWSEINFO lpbi;
lpbi.hwndOwner = hwndOwner;
lpbi.lpszTitle = lpszTitle;
lpbi.ulFlags = OS.BIF_NEWDIALOGSTYLE | OS.BIF_RETURNONLYFSDIRS | OS.BIF_EDITBOX | OS.BIF_VALIDATE;
lpbi.lpfn = lpfn;
lpbi.lParam = cast(int)cast(void*)this;
/*
* Bug in Windows. On some hardware configurations, SHBrowseForFolder()
* causes warning dialogs with the message "There is no disk in the drive
* Please insert a disk into \Device\Harddisk0\DR0". This is possibly
* caused by SHBrowseForFolder() calling internally GetVolumeInformation().
* MSDN for GetVolumeInformation() says:
*
* "If you are attempting to obtain information about a floppy drive
* that does not have a floppy disk or a CD-ROM drive that does not
* have a compact disc, the system displays a message box asking the
* user to insert a floppy disk or a compact disc, respectively.
* To prevent the system from displaying this message box, call the
* SetErrorMode function with SEM_FAILCRITICALERRORS."
*
* The fix is to save and restore the error mode using SetErrorMode()
* with the SEM_FAILCRITICALERRORS flag around SHBrowseForFolder().
*/
int oldErrorMode = OS.SetErrorMode (OS.SEM_FAILCRITICALERRORS);
/*
* Bug in Windows. When a WH_MSGFILTER hook is used to run code
* during the message loop for SHBrowseForFolder(), running code
* in the hook can cause a GP. Specifically, SetWindowText()
* for static controls seemed to make the problem happen.
* The fix is to disable async messages while the directory
* dialog is open.
*
* NOTE: This only happens in versions of the comctl32.dll
* earlier than 6.0.
*/
bool oldRunMessages = display.runMessages;
if (OS.COMCTL32_MAJOR < 6) display.runMessages = false;
ITEMIDLIST* lpItemIdList = OS.SHBrowseForFolder (&lpbi);
if (OS.COMCTL32_MAJOR < 6) display.runMessages = oldRunMessages;
OS.SetErrorMode (oldErrorMode);
/* Clear the temporary dialog modal parent */
if ((style & (SWT.APPLICATION_MODAL | SWT.SYSTEM_MODAL)) !is 0) {
display.setModalDialog (oldModal);
}
bool success = lpItemIdList !is null;
if (success) {
/* Use the character encoding for the default locale */
TCHAR[OS.MAX_PATH] buffer;
if (OS.SHGetPathFromIDList (lpItemIdList, buffer.ptr)) {
directoryPath = TCHARzToStr (buffer.ptr);
filterPath = directoryPath;
}
}
/* Free the BrowseCallbackProc */
// callback.dispose ();
/* Free the OS memory */
if (lpszTitle !is null) OS.HeapFree (hHeap, 0, lpszTitle);
/* Free the pointer to the ITEMIDLIST */
LPVOID ppMalloc;
if (OS.SHGetMalloc (&ppMalloc) is OS.S_OK) {
/* void Free (struct IMalloc *this, void *pv); */
OS.VtblCall (5, ppMalloc , cast(int)lpItemIdList);
}
/*
* This code is intentionally commented. On some
* platforms, the owner window is repainted right
* away when a dialog window exits. This behavior
* is currently unspecified.
*/
// if (hwndOwner !is 0) OS.UpdateWindow (hwndOwner);
/* Return the directory path */
if (!success) return null;
return directoryPath;
}
/**
* Sets the path that the dialog will use to filter
* the directories it shows to the argument, which may
* be null. If the string is null, then the operating
* system's default filter path will be used.
* <p>
* Note that the path string is platform dependent.
* For convenience, either '/' or '\' can be used
* as a path separator.
* </p>
*
* @param string the filter path
*/
public void setFilterPath (String string) {
filterPath = string;
}
/**
* Sets the dialog's message, which is a description of
* the purpose for which it was opened. This message will be
* visible on the dialog while it is open.
*
* @param string the message
*
*/
public void setMessage (String string) {
// SWT extension: allow null string
//if (string is null) error (SWT.ERROR_NULL_ARGUMENT);
message = string;
}
}
| D |
instance DIA_Addon_Erol_EXIT(C_Info)
{
npc = VLK_4303_Addon_Erol;
nr = 999;
condition = DIA_Addon_Erol_EXIT_Condition;
information = DIA_Addon_Erol_EXIT_Info;
permanent = TRUE;
description = Dialog_Ende;
};
func int DIA_Addon_Erol_EXIT_Condition()
{
return TRUE;
};
func void DIA_Addon_Erol_EXIT_Info()
{
AI_StopProcessInfos(self);
};
instance DIA_ADDON_EROL_NO_TALK(C_Info)
{
npc = VLK_4303_Addon_Erol;
nr = 1;
condition = dia_addon_erol_no_talk_condition;
information = dia_addon_erol_no_talk_info;
permanent = TRUE;
important = TRUE;
};
func int dia_addon_erol_no_talk_condition()
{
if((self.aivar[AIV_LastFightAgainstPlayer] == FIGHT_LOST) && Npc_IsInState(self,ZS_Talk) && (EROLRECRUITEDDT == FALSE))
{
return TRUE;
};
};
func void dia_addon_erol_no_talk_info()
{
B_Say(self,other,"$SPAREME");
B_Say(self,other,"$NEVERENTERROOMAGAIN");
AI_StopProcessInfos(self);
};
instance DIA_Addon_Erol_PICKPOCKET(C_Info)
{
npc = VLK_4303_Addon_Erol;
nr = 900;
condition = DIA_Addon_Erol_PICKPOCKET_Condition;
information = DIA_Addon_Erol_PICKPOCKET_Info;
permanent = TRUE;
description = PICKPOCKET_COMM;
};
func int DIA_Addon_Erol_PICKPOCKET_Condition()
{
return C_Beklauen(43,42);
};
func void DIA_Addon_Erol_PICKPOCKET_Info()
{
Info_ClearChoices(DIA_Addon_Erol_PICKPOCKET);
Info_AddChoice(DIA_Addon_Erol_PICKPOCKET,Dialog_Back,DIA_Addon_Erol_PICKPOCKET_BACK);
Info_AddChoice(DIA_Addon_Erol_PICKPOCKET,DIALOG_PICKPOCKET,DIA_Addon_Erol_PICKPOCKET_DoIt);
};
func void DIA_Addon_Erol_PICKPOCKET_DoIt()
{
B_Beklauen();
Info_ClearChoices(DIA_Addon_Erol_PICKPOCKET);
};
func void DIA_Addon_Erol_PICKPOCKET_BACK()
{
Info_ClearChoices(DIA_Addon_Erol_PICKPOCKET);
};
instance DIA_Addon_Erol_Hallo(C_Info)
{
npc = VLK_4303_Addon_Erol;
nr = 5;
condition = DIA_Addon_Erol_Hallo_Condition;
information = DIA_Addon_Erol_Hallo_Info;
description = "Co se stalo?";
};
func int DIA_Addon_Erol_Hallo_Condition()
{
return TRUE;
};
func void DIA_Addon_Erol_Hallo_Info()
{
AI_Output(other,self,"DIA_Addon_Erol_Hallo_15_00"); //Co se stalo?
AI_Output(self,other,"DIA_Addon_Erol_Hallo_10_01"); //(Naštvaně) Co se stalo? Podívej se na ten nepořádek tamhle pod mostem!
AI_Output(self,other,"DIA_Addon_Erol_Hallo_10_02"); //(Naštvaně) Něco takového jsem neviděl za celý můj život. Ti tvorové by je měli do jednoho pobít.
};
instance DIA_Addon_Erol_what(C_Info)
{
npc = VLK_4303_Addon_Erol;
nr = 5;
condition = DIA_Addon_Erol_what_Condition;
information = DIA_Addon_Erol_what_Info;
description = "Co se stalo?";
};
func int DIA_Addon_Erol_what_Condition()
{
if(Npc_KnowsInfo(other,DIA_Addon_Erol_Hallo))
{
return TRUE;
};
return FALSE;
};
func void DIA_Addon_Erol_what_Info()
{
AI_Output(other,self,"DIA_Addon_Erol_what_15_00"); //Co se stalo?
AI_Output(self,other,"DIA_Addon_Erol_what_10_01"); //Cestoval jsem se svými pomocníky, když v tom se ti podělaní hajzlové z ničeho nic zjevili a všechny je zabili.
AI_Output(self,other,"DIA_Addon_Erol_what_10_02"); //Naštěstí jsem nezapomněl na můj pravý hak a díky tomu jsem vyvázl se zdravou kůží.
Log_CreateTopic(TOPIC_Addon_Erol,LOG_MISSION);
Log_SetTopicStatus(TOPIC_Addon_Erol,LOG_Running);
B_LogEntry(TOPIC_Addon_Erol,"Obchodník Erol byl přepaden bandity. Vzali mu veškeré zboží. Erol po mě chce abych mu vrátil jeho kamenné desky. Banditi se usadili vedle mostu nedaleko hostince 'U Mrtvé harpyje'.");
MIS_Addon_Erol_BanditStuff = LOG_Running;
Info_ClearChoices(DIA_Addon_Erol_what);
Info_AddChoice(DIA_Addon_Erol_what,"Takže ty věci, co leží pod mostem, jsou tvé?",DIA_Addon_Erol_what_dein);
Info_AddChoice(DIA_Addon_Erol_what,"Co to bylo za lidi co tě napadli?",DIA_Addon_Erol_what_wer);
};
func void DIA_Addon_Erol_what_back()
{
Info_ClearChoices(DIA_Addon_Erol_what);
};
func void DIA_Addon_Erol_what_dein()
{
AI_Output(other,self,"DIA_Addon_Erol_what_dein_15_00"); //Ty věci pod mostem jsou tvé?
AI_Output(self,other,"DIA_Addon_Erol_what_dein_10_01"); //Vozík, zboží, všechno...
if(Npc_HasItems(other,itmi_erolskelch) > 0)
{
AI_Output(other,self,"DIA_Addon_Erol_what_dein_Add_15_00"); //Vzal jsem něco ze tvého zboží...
AI_Output(self,other,"DIA_Addon_Erol_what_dein_Add_10_01"); //Nech si to. Nic z toho pro mě nemá žádnou cenu.
}
else
{
AI_Output(self,other,"DIA_Addon_Erol_what_dein_Add_10_02"); //Nic z toho pro mě nemá žádnou cenu.
};
AI_Output(self,other,"DIA_Addon_Erol_what_dein_10_02"); //Ale je tu něco nenahraditelného, co mi banditi ukradli. Tři kamenné desky.
Info_AddChoice(DIA_Addon_Erol_what,Dialog_Back,DIA_Addon_Erol_what_back);
Info_AddChoice(DIA_Addon_Erol_what,"Kamenné desky?",DIA_Addon_Erol_what_Was);
};
func void DIA_Addon_Erol_what_Was()
{
AI_Output(other,self,"DIA_Addon_Erol_what_Was_15_00"); //Kamenné desky?
AI_Output(self,other,"DIA_Addon_Erol_what_Was_10_01"); //Jo. Chtěl si je u mě koupit mág Vody ve městě. Slíbil jsem mu je, jak se k nim dostanu.
AI_Output(self,other,"DIA_Addon_Erol_what_Was_10_02"); //Musím je dostat zpět za každou cenu, jinak to silně poškodí mou reputaci.
Info_AddChoice(DIA_Addon_Erol_what,"Kde jsi získal ty kamenné desky?",DIA_Addon_Erol_what_woher);
Info_AddChoice(DIA_Addon_Erol_what,"Co s nimi chtějí mágové Vody dělat?",DIA_Addon_Erol_what_KDW);
};
func void DIA_Addon_Erol_what_KDW()
{
AI_Output(other,self,"DIA_Addon_Erol_what_KDW_15_00"); //Co s nimi chtějí mágové Vody dělat?
AI_Output(self,other,"DIA_Addon_Erol_what_KDW_10_01"); //Řekli mi, že je chtějí studovat a požádali mě, ať jich přinesu co nejvíce.
};
func void DIA_Addon_Erol_what_woher()
{
AI_Output(other,self,"DIA_Addon_Erol_what_woher_15_00"); //Odkud máš tyto kamenné desky?
AI_Output(self,other,"DIA_Addon_Erol_what_woher_10_01"); //Našel jsem je u starých budov vypadajících jako mausolea a jindy je třeba najdeš i v jeskyních.
AI_Output(self,other,"DIA_Addon_Erol_what_woher_10_02"); //Už jsem jich mágům Vody prodal celou kupu.
AI_Output(self,other,"DIA_Addon_Erol_what_woher_10_03"); //Nicméně tady dole jsou celkem vzácné. Nejčastěji severovýchodně od Khorinisu jich náchazím spoustu.
Info_AddChoice(DIA_Addon_Erol_what,"Proč prostě nenajdeš další?",DIA_Addon_Erol_what_neue);
};
func void DIA_Addon_Erol_what_neue()
{
AI_Output(other,self,"DIA_Addon_Erol_what_neue_15_00"); //Proč prostě nenajdeš další?
AI_Output(self,other,"DIA_Addon_Erol_what_neue_10_01"); //V boji s bandity jsem si vyvrtnul kotník.
AI_Output(self,other,"DIA_Addon_Erol_what_neue_10_02"); //Se špatnou nohou daleko neujdu.
};
func void DIA_Addon_Erol_what_wer()
{
AI_Output(other,self,"DIA_Addon_Erol_what_wer_15_00"); //Co to bylo za lidi, co tě napadli?
AI_Output(self,other,"DIA_Addon_Erol_what_wer_10_01"); //Banditi. Kdo jiný? Usadili se na mostě.
AI_Output(self,other,"DIA_Addon_Erol_what_wer_10_02"); //Oberou každého, kdo chce přejít most.
AI_Output(self,other,"DIA_Addon_Erol_what_wer_10_03"); //Věděl jsem, že je na mě nahoře připravená léčka, a proto jsem se rozhodl, že projdu pod mostem.
AI_Output(self,other,"DIA_Addon_Erol_what_wer_10_04"); //Ale můj vozík a mé zboží asi vzbudily příliš vysokou pozornost, zdá se.
AI_Output(self,other,"DIA_Addon_Erol_what_wer_10_05"); //Ti bastardi prostě skočili z mostu - přímo na na nás.
AI_Output(self,other,"DIA_Addon_Erol_what_wer_10_06"); //Bylo nutné se tam pokusit v noci proplížit...
};
instance DIA_Addon_Erol_FernandosWeapons(C_Info)
{
npc = VLK_4303_Addon_Erol;
nr = 5;
condition = DIA_Addon_Erol_FernandosWeapons_Condition;
information = DIA_Addon_Erol_FernandosWeapons_Info;
description = "Nemáš nějaké informace o zásilkách zbraní banditům?";
};
func int DIA_Addon_Erol_FernandosWeapons_Condition()
{
if(Npc_KnowsInfo(other,DIA_Addon_Erol_what) && (MIS_Vatras_FindTheBanditTrader == LOG_Running))
{
return TRUE;
};
return FALSE;
};
func void DIA_Addon_Erol_FernandosWeapons_Info()
{
AI_Output(other,self,"DIA_Addon_Erol_FernandosWeapons_15_00"); //Nemáš nějaké informace o zásilkách zbraní banditům?
AI_Output(self,other,"DIA_Addon_Erol_FernandosWeapons_10_01"); //Zásilky zbraní? Jasně, jedna tu je. Nějaký hajzl z města jim prodal mnoho zbraní. Taktak je mohli odnést.
AI_Output(self,other,"DIA_Addon_Erol_FernandosWeapons_10_02"); //Část z toho je uložená u mostu, kde mě napadli ti banditi.
AI_Output(self,other,"DIA_Addon_Erol_FernandosWeapons_10_03"); //Část museli odnést někam na pastviny za Bengarovou farmou.
AI_Output(self,other,"DIA_Addon_Erol_FernandosWeapons_10_04"); //Možná je chtěli banditi propašovat přes průsmyk.
Info_ClearChoices(DIA_Addon_Erol_FernandosWeapons);
Info_AddChoice(DIA_Addon_Erol_FernandosWeapons,Dialog_Back,DIA_Addon_Erol_FernandosWeapons_back);
Info_AddChoice(DIA_Addon_Erol_FernandosWeapons,"Kde je ta pastvina?",DIA_Addon_Erol_FernandosWeapons_bengar);
};
func void DIA_Addon_Erol_FernandosWeapons_bengar()
{
AI_Output(other,self,"DIA_Addon_Erol_FernandosWeapons_bengar_15_00"); //Kde je ta pastvina?
AI_Output(self,other,"DIA_Addon_Erol_FernandosWeapons_bengar_10_01"); //Přibližně uprostřed ostrova Khorinis leží Orlanův hostinec. Nazývá se 'U Mrtvé harpyje'.
AI_Output(self,other,"DIA_Addon_Erol_FernandosWeapons_bengar_10_02"); //Vede odtamtud cesta na jih. Prochází přes pastviny až ke vstupu do Hornického údolí.
Info_ClearChoices(DIA_Addon_Erol_FernandosWeapons);
};
func void DIA_Addon_Erol_FernandosWeapons_back()
{
Info_ClearChoices(DIA_Addon_Erol_FernandosWeapons);
};
instance DIA_Addon_Erol_Stoneplates(C_Info)
{
npc = VLK_4303_Addon_Erol;
nr = 5;
condition = DIA_Addon_Erol_Stoneplates_Condition;
information = DIA_Addon_Erol_Stoneplates_Info;
permanent = TRUE;
description = "O kamenných deskách...";
};
func int DIA_Addon_Erol_Stoneplates_Condition()
{
if(MIS_Addon_Erol_BanditStuff == LOG_Running)
{
return TRUE;
};
return FALSE;
};
var int StoneplatesCounter;
const int Addon_ErolsStoneplatesOffer = 10;
func void DIA_Addon_Erol_Stoneplates_Info()
{
var int StoneplatesCount;
var int XP_Addon_BringStoneplates;
var int StoneplatesGeld;
AI_Output(other,self,"DIA_Addon_Erol_Stoneplates_15_00"); //O kamenných deskách...
if(Npc_HasItems(other,ItWr_StonePlateCommon_Addon) >= 1)
{
StoneplatesCount = Npc_HasItems(other,ItWr_StonePlateCommon_Addon);
if(StoneplatesCount == 1)
{
AI_Output(other,self,"DIA_Addon_Erol_Stoneplates_15_01"); //Mám jednu z nich.
B_GivePlayerXP(XP_Addon_BringStoneplate);
B_GiveInvItems(other,self,ItWr_StonePlateCommon_Addon,1);
Npc_RemoveInvItems(self,ItWr_StonePlateCommon_Addon,Npc_HasItems(self,ItWr_StonePlateCommon_Addon));
StoneplatesCounter = StoneplatesCounter + 1;
}
else
{
AI_Output(other,self,"DIA_Addon_Erol_Stoneplates_15_02"); //Mám jich pár.
if((StoneplatesCount + StoneplatesCounter) >= 3)
{
B_GiveInvItems(other,self,ItWr_StonePlateCommon_Addon,3 - StoneplatesCounter);
Npc_RemoveInvItems(self,ItWr_StonePlateCommon_Addon,Npc_HasItems(self,ItWr_StonePlateCommon_Addon));
XP_Addon_BringStoneplates = (3 - StoneplatesCounter) * XP_Addon_BringStoneplate;
StoneplatesCounter = 3;
}
else
{
B_GiveInvItems(other,self,ItWr_StonePlateCommon_Addon,StoneplatesCount);
Npc_RemoveInvItems(self,ItWr_StonePlateCommon_Addon,Npc_HasItems(self,ItWr_StonePlateCommon_Addon));
XP_Addon_BringStoneplates = StoneplatesCount * XP_Addon_BringStoneplate;
StoneplatesCounter = StoneplatesCounter + StoneplatesCount;
};
B_GivePlayerXP(XP_Addon_BringStoneplates);
};
AI_Output(self,other,"DIA_Addon_Erol_Stoneplates_10_03"); //Díky.
if(StoneplatesCounter == 1)
{
AI_Output(self,other,"DIA_Addon_Erol_Stoneplates_10_04"); //Teď už mi chybí jen dvě.
}
else if(StoneplatesCounter == 2)
{
AI_Output(self,other,"DIA_Addon_Erol_Stoneplates_10_05"); //Teď už mi chybí jen jedna.
}
else
{
AI_Output(self,other,"DIA_Addon_Erol_Stoneplates_10_06"); //To stačí, nyní můžu dodržet svůj slib mágům Vody ve městě a pak jít konečně domů.
MIS_Addon_Erol_BanditStuff = LOG_SUCCESS;
Wld_AssignRoomToGuild("grpwaldhuette01",GIL_PUBLIC);
};
AI_Output(self,other,"DIA_Addon_Erol_Stoneplates_10_07"); //Zaplatím ti za ně, samozřejmě.
StoneplatesGeld = Addon_ErolsStoneplatesOffer * Npc_HasItems(self,ItWr_StonePlateCommon_Addon);
CreateInvItems(self,ItMi_Gold,StoneplatesGeld);
B_GiveInvItems(self,other,ItMi_Gold,StoneplatesGeld);
Npc_RemoveInvItems(self,ItWr_StonePlateCommon_Addon,Npc_HasItems(self,ItWr_StonePlateCommon_Addon));
if(MIS_Addon_Erol_BanditStuff == LOG_SUCCESS)
{
AI_Output(self,other,"DIA_Addon_Erol_Stoneplates_10_08"); //Jdu domů. Jestli chceš, tak se ke mně můžeš přidat.
AI_Output(self,other,"DIA_Addon_Erol_Stoneplates_10_09"); //Možná ti budu schopen něco prodat, když se dostanu domů.
AI_StopProcessInfos(self);
Npc_ExchangeRoutine(self,"Start");
Wld_AssignRoomToGuild("grpwaldhuette01",GIL_PUBLIC);
};
}
else if(C_ScHasMagicStonePlate() == TRUE)
{
AI_Output(other,self,"DIA_Addon_Erol_Stoneplates_15_10"); //Je tato tabulka dobrá?
AI_Output(self,other,"DIA_Addon_Erol_Stoneplates_10_11"); //Ne, tato má nějakou magickou moc.
AI_Output(self,other,"DIA_Addon_Erol_Stoneplates_10_12"); //Takové kamenné desky mágové Vody nekoupí.
}
else
{
AI_Output(other,self,"DIA_Addon_Erol_Stoneplates_15_13"); //Kolik jich budeš potřebovat?
AI_Output(self,other,"DIA_Addon_Erol_Stoneplates_10_14"); //Abych si zachránil svou reputaci ve městě u mágů Vody, potřebuji 3 kamenné desky.
};
};
instance DIA_Addon_Erol_Buerger(C_Info)
{
npc = VLK_4303_Addon_Erol;
nr = 5;
condition = DIA_Addon_Erol_Buerger_Condition;
information = DIA_Addon_Erol_Buerger_Info;
description = "Žiješ ve městě?";
};
func int DIA_Addon_Erol_Buerger_Condition()
{
if(Npc_KnowsInfo(other,DIA_Addon_Erol_Hallo))
{
return TRUE;
};
};
func void DIA_Addon_Erol_Buerger_Info()
{
AI_Output(other,self,"DIA_Addon_Erol_Buerger_15_00"); //Žiješ ve městě?
AI_Output(self,other,"DIA_Addon_Erol_Buerger_10_01"); //Už dlouho ne, kamaráde. Nic mě mezi těma zrádnýma a lakomýma sviněma, co žijí v horní čtvrti, nedrží.
AI_Output(self,other,"DIA_Addon_Erol_Buerger_10_02"); //Míval jsem velký vliv. Jen abys věděl. Ale to bylo velmi dávno...
if((MEMBERTRADEGUILD == FALSE) && (MIS_TRADEGUILD != LOG_FAILED) && (NIGELTELLABOUTGUILD == FALSE) && (EROLTELLABOUTGUILD == FALSE))
{
AI_Output(other,self,"DIA_Addon_Erol_Buerger_10_03"); //Už i tehdy si se zabýval obchodem?!
AI_Output(self,other,"DIA_Addon_Erol_Buerger_10_04"); //Ne, že jen zabýval, ale býval jsem jeden z nejbohatších obchodníků ve městě.
AI_Output(self,other,"DIA_Addon_Erol_Buerger_10_05"); //A kromě toho jsem také byl vůdcem cechu obchodníků v Khorinisu.
AI_Output(other,self,"DIA_Addon_Erol_Buerger_10_06"); //Cech obchodníků?!
AI_Output(self,other,"DIA_Addon_Erol_Buerger_10_07"); //Spadnul jsi z měsíce?! (udiveně)
AI_Output(self,other,"DIA_Addon_Erol_Buerger_10_09"); //Hmm... (udiveně) To je tedy zvláštní!
AI_Output(self,other,"DIA_Addon_Erol_Buerger_10_10"); //Upřímně řečeno, ještě nikdy jsem nenarazil na někoho, kdo by o něm nikdy neslyšel!
AI_Output(self,other,"DIA_Addon_Erol_Buerger_10_11"); //Ačkoli, teď se cech ani tak moc nesnaží vystavovat veřejnosti.
AI_Output(self,other,"DIA_Addon_Erol_Buerger_10_12"); //Je to pochopitelné. V poslední době se tu v okolí ochomýtají různí banditi a jiný odpad.
AI_Output(self,other,"DIA_Addon_Erol_Buerger_10_13"); //A sám vidíš, že být obchodníkem je v poslední době dost nebezpečné.
AI_Output(self,other,"DIA_Addon_Erol_Buerger_10_14"); //Ale dříve býval Cech obchodníků v Khorinisu jeden z nejvlivnějších a nejznámějších v celé Myrtaně!
AI_Output(self,other,"DIA_Addon_Erol_Buerger_10_15"); //Být jeho členem byla čest pro každého, ale mnoho lidí jsme nepřijímali.
AI_Output(self,other,"DIA_Addon_Erol_Buerger_10_16"); //Eh!... (smutně)
EROLTELLABOUTGUILD = TRUE;
};
};
instance DIA_ADDON_EROL_TRADEGUILD(C_Info)
{
npc = VLK_4303_Addon_Erol;
nr = 5;
condition = dia_addon_erol_tradeguild_condition;
information = dia_addon_erol_tradeguild_info;
permanent = FALSE;
description = "Chtěl bych se stát členem obchodního cechu.";
};
func int dia_addon_erol_tradeguild_condition()
{
if((EROLTELLABOUTGUILD == TRUE) && (MEMBERTRADEGUILD == FALSE) && (MIS_TRADEGUILD != LOG_FAILED) && (NIGELTELLABOUTGUILD == FALSE))
{
return TRUE;
};
};
func void dia_addon_erol_tradeguild_info()
{
AI_Output(other,self,"DIA_Addon_Erol_TradeGuild_01_00"); //Chtěl bych se stát členem obchodního cechu. Mohl by si mi s tím pomoct?
AI_Output(self,other,"DIA_Addon_Erol_TradeGuild_01_02"); //Hmmm... (Zamyšleně) Vlastně už to bude delší doba, co jsem z tama odešel.
AI_Output(self,other,"DIA_Addon_Erol_TradeGuild_01_03"); //Ačkoli, i přes to, mi pořád zůstalo určité spojení s cechem.
AI_Output(other,self,"DIA_Addon_Erol_TradeGuild_01_04"); //Takže by ti nedalo moc práce mi pomoci?
AI_Output(self,other,"DIA_Addon_Erol_TradeGuild_01_05"); //No...
if(MIS_Addon_Erol_BanditStuff != LOG_SUCCESS)
{
AI_Output(self,other,"DIA_Addon_Erol_Teach_10_01"); //Dobře, ale za to pro mně něco uděláš.
AI_Output(self,other,"DIA_Addon_Erol_Teach_10_02"); //Pomoz mi zachránit mou reputaci, a přines mi zpět mé kamenné desky pro mágy Vody.
AI_Output(self,other,"DIA_Addon_Erol_TradeGuild_01_06"); //Pak ti rád pomůžu stát se členem cechu.
}
else
{
AI_Output(self,other,"DIA_Addon_Erol_TradeGuild_01_07"); //A zvlášť když si mi prokázal takovou službu, vrátil si mi tabulky.
AI_Output(self,other,"DIA_Addon_Erol_TradeGuild_01_08"); //? dluh, jak víš, se má zplácet!
AI_Output(other,self,"DIA_Addon_Erol_TradeGuild_01_09"); //Co bych měl udělat?
AI_Output(self,other,"DIA_Addon_Erol_TradeGuild_01_10"); //Ty - absolutně nic... (směje se) Já se postarám o všechno.
AI_Output(self,other,"DIA_Addon_Erol_TradeGuild_01_11"); //Napíšu ti doporučující dopis, pro jednoho mého přítele.
AI_Output(self,other,"DIA_Addon_Erol_TradeGuild_01_13"); //Je to velmi vlivný člověk ve městě, a kromě toho - současný mistr cechu obchodníků.
AI_Output(self,other,"DIA_Addon_Erol_TradeGuild_01_14"); //Nebude tě jentak poslouchat... ale s tímto dopisem - to je jiná!
AI_Output(other,self,"DIA_Addon_Erol_TradeGuild_01_15"); //A co bych mu měl říct?
AI_Output(self,other,"DIA_Addon_Erol_TradeGuild_01_16"); //Nic říkat nemusíš, vše je řečeno v mém dopise.
AI_Output(self,other,"DIA_Addon_Erol_TradeGuild_01_17"); //A věř mi, napíšu to tak, že nebude mít jinou možnost, než tě přijmout.
AI_Output(other,self,"DIA_Addon_Erol_TradeGuild_01_20"); //Skvěle! Napiš mi ten dopis.
B_UseFakeScroll();
AI_Output(self,other,"DIA_Addon_Erol_TradeGuild_01_21"); //Na, vem to mistru Luterovi.
B_GiveInvItems(self,other,itwr_erolletter,1);
AI_Output(other,self,"DIA_Addon_Erol_TradeGuild_01_22"); //Luterovi?
AI_Output(self,other,"DIA_Addon_Erol_TradeGuild_01_23"); //Ano, a věřím, že víš o koho se jedná, takže ti nebude dělat velkou práci ho najít.
AI_Output(other,self,"DIA_Addon_Erol_TradeGuild_01_25"); //Dobrá tedy.
EROLGIVERECOMENDATION = TRUE;
};
};
instance DIA_ADDON_EROL_TRADEGUILDHOW(C_Info)
{
npc = VLK_4303_Addon_Erol;
nr = 5;
condition = dia_addon_erol_tradeguildhow_condition;
information = dia_addon_erol_tradeguildhow_info;
permanent = TRUE;
description = "Ohledně cechu obchodníků...";
};
func int dia_addon_erol_tradeguildhow_condition()
{
if(Npc_KnowsInfo(hero,dia_addon_erol_tradeguild) && (EROLTELLABOUTGUILD == TRUE) && (EROLGIVERECOMENDATION == FALSE) && (MEMBERTRADEGUILD == FALSE) && (MIS_TRADEGUILD != LOG_FAILED) && (NIGELTELLABOUTGUILD == FALSE))
{
return TRUE;
};
};
func void dia_addon_erol_tradeguildhow_info()
{
AI_Output(other,self,"DIA_Addon_Erol_TradeGuildHow_01_00"); //Ohledně cechu obchodníků...
if(MIS_Addon_Erol_BanditStuff != LOG_SUCCESS)
{
AI_Output(self,other,"DIA_Addon_Erol_TradeGuildHow_01_01"); //Už jsem ti řekl - napřed mi vrať mé desky!
AI_Output(self,other,"DIA_Addon_Erol_TradeGuildHow_01_02"); //Potom si promluvíme o tvé záležitosti.
}
else
{
AI_Output(self,other,"DIA_Addon_Erol_TradeGuildHow_01_03"); //Dobře. Pomohl jsi mi, teď pomůžu já tobě.
AI_Output(other,self,"DIA_Addon_Erol_TradeGuildHow_01_04"); //Co bych měl udělat?
AI_Output(self,other,"DIA_Addon_Erol_TradeGuildHow_01_05"); //Ty - absolutně nic... (směje se) Já se postarám o všechno.
AI_Output(self,other,"DIA_Addon_Erol_TradeGuildHow_01_06"); //Napíšu ti doporučující dopis, pro jednoho mého přítele.
AI_Output(self,other,"DIA_Addon_Erol_TradeGuildHow_01_08"); //Je to velmi vlivný člověk ve městě, a kromě toho - současný mistr cechu obchodníků.
AI_Output(self,other,"DIA_Addon_Erol_TradeGuildHow_01_09"); //Nebude tě jentak poslouchat... ale s tímto dopisem - to je jiná!
AI_Output(other,self,"DIA_Addon_Erol_TradeGuildHow_01_10"); //A co bych mu měl říct?
AI_Output(self,other,"DIA_Addon_Erol_TradeGuildHow_01_11"); //Nic říkat nemusíš, vše je řečeno v mém dopise.
AI_Output(self,other,"DIA_Addon_Erol_TradeGuildHow_01_12"); //A věř mi, napíšu to tak, že nebude mít jinou možnost, než tě přijmout.
AI_Output(other,self,"DIA_Addon_Erol_TradeGuildHow_01_15"); //Skvěle! Napiš mi ten dopis.
B_UseFakeScroll();
AI_Output(self,other,"DIA_Addon_Erol_TradeGuildHow_01_16"); //Na, vem to mistru Luterovi.
B_GiveInvItems(self,other,itwr_erolletter,1);
AI_Output(other,self,"DIA_Addon_Erol_TradeGuildHow_01_17"); //Luterovi?
AI_Output(self,other,"DIA_Addon_Erol_TradeGuildHow_01_18"); //Ano, a věřím, že víš o koho se jedná, takže ti nebude dělat velkou práci ho najít.
AI_Output(other,self,"DIA_Addon_Erol_TradeGuildHow_01_20"); //Dobrá tedy.
EROLGIVERECOMENDATION = TRUE;
};
};
instance DIA_Addon_Erol_PreTeach(C_Info)
{
npc = VLK_4303_Addon_Erol;
nr = 5;
condition = DIA_Addon_Erol_PreTeach_Condition;
information = DIA_Addon_Erol_PreTeach_Info;
description = "Zahnal jsi ty lupiče na útěk?";
};
func int DIA_Addon_Erol_PreTeach_Condition()
{
if(Npc_KnowsInfo(other,DIA_Addon_Erol_what))
{
return TRUE;
};
return FALSE;
};
func void DIA_Addon_Erol_PreTeach_Info()
{
AI_Output(other,self,"DIA_Addon_Erol_PreTeach_15_00"); //Zahnal jsi ty lupiče na útěk?
AI_Output(self,other,"DIA_Addon_Erol_PreTeach_10_01"); //Ano, ale jsem si jistý, že jsou stále na mostě.
AI_Output(other,self,"DIA_Addon_Erol_PreTeach_15_02"); //Můžeš mi ukázat jak dát pořádnou ránu?
AI_Output(self,other,"DIA_Addon_Erol_PreTeach_10_03"); //Samozřejmě, že ano.
Erol_Addon_TeachPlayer = TRUE;
Log_CreateTopic(Topic_OutTeacher,LOG_NOTE);
B_LogEntry(Topic_OutTeacher,LogText_Addon_Erol_Teach);
};
instance DIA_Addon_Erol_PreTrade(C_Info)
{
npc = VLK_4303_Addon_Erol;
nr = 100;
condition = DIA_Addon_Erol_PreTrade_Condition;
information = DIA_Addon_Erol_PreTrade_Info;
permanent = TRUE;
description = "Ukaž mi své zboží.";
};
func int DIA_Addon_Erol_PreTrade_Condition()
{
if(Npc_KnowsInfo(other,DIA_Addon_Erol_what) && (Npc_GetDistToWP(self,"NW_BIGFARM_HUT_IN_01") > 2000) && (ErolRECRUITEDDT == FALSE))
{
return TRUE;
};
};
func void DIA_Addon_Erol_PreTrade_Info()
{
AI_Output(other,self,"DIA_Elena_TRADE_15_00"); //Ukaž mi své zboží.
AI_Output(self,other,"DIA_Addon_Erol_PreTrade_10_00"); //Nic ti prodat nemůžu. Všechno mé zboží zůstalo támhle pod mostem!
AI_Output(self,other,"DIA_Addon_Erol_PreTrade_10_01"); //Něco ti budu moct prodat, až se dostanu domů.
if(MIS_Addon_Erol_BanditStuff != LOG_SUCCESS)
{
AI_Output(self,other,"DIA_Addon_Erol_PreTrade_10_02"); //Ale neodejdu odsud, dokud nezískám zpět své kamenné desky pro mága.
};
};
instance DIA_Addon_Erol_SLD(C_Info)
{
npc = VLK_4303_Addon_Erol;
nr = 5;
condition = DIA_Addon_Erol_SLD_Condition;
information = DIA_Addon_Erol_SLD_Info;
description = "To je tvůj dům?";
};
func int DIA_Addon_Erol_SLD_Condition()
{
if(Npc_GetDistToWP(self,"NW_BIGFARM_HUT_IN_01") < 2000)
{
return TRUE;
};
};
var int Erol_IsAtHome;
func void DIA_Addon_Erol_SLD_Info()
{
AI_Output(other,self,"DIA_Addon_Erol_SLD_15_00"); //(udiveně) Takže to je tvoje dům?
AI_Output(self,other,"DIA_Addon_Erol_SLD_10_01"); //Jo, proč? Máš s tím nějkaý problém?
AI_Output(other,self,"DIA_Addon_Erol_SLD_15_02"); //Nemáš problémy se žoldáky?
AI_Output(self,other,"DIA_Addon_Erol_SLD_10_03"); //Dokud se nebudu plést do jejich záležitostí, oni si mne také nebudou všímat.
AI_Output(self,other,"DIA_Addon_Erol_SLD_10_04"); //A navíc jsou to skvělí zákazníci a platím jim za to, že mi dávají pozor na chatu, když někam vyrazím pryč.
B_GivePlayerXP(XP_Ambient);
if(Erol_IsAtHome == FALSE)
{
Npc_ExchangeRoutine(self,"HOME");
Erol_IsAtHome = TRUE;
};
};
var int ErolGiveMat;
instance DIA_Addon_Erol_Trade(C_Info)
{
npc = VLK_4303_Addon_Erol;
nr = 100;
condition = DIA_Addon_Erol_Trade_Condition;
information = DIA_Addon_Erol_Trade_Info;
trade = TRUE;
permanent = TRUE;
description = "Ukaž mi své zboží.";
};
func int DIA_Addon_Erol_Trade_Condition()
{
if((MIS_Addon_Erol_BanditStuff == LOG_SUCCESS) && Wld_IsTime(8,0,22,0) && ((Npc_GetDistToWP(self,"NW_BIGFARM_HUT_IN_01") < 3000) || (ErolRECRUITEDDT == TRUE)))
{
return TRUE;
};
};
var int DIA_Addon_Erol_Trade_OneTime;
func void DIA_Addon_Erol_Trade_Info()
{
if(C_BodyStateContains(self,BS_SIT))
{
AI_Standup(self);
AI_TurnToNPC(self,other);
};
B_Say(other,self,"$TRADE_2");
AI_Output(self,other,"DIA_Addon_Erol_Trade_10_00"); //Bojím se, že není moc na výběr.
if((MIS_ROBAMATERIAL == LOG_Running) && (ErolGiveMat == FALSE))
{
CreateInvItems(self,itmi_novmaterial,1);
ErolGiveMat = TRUE;
};
if(Erol_IsAtHome == FALSE)
{
Log_CreateTopic(Topic_OutTrader,LOG_NOTE);
B_LogEntry(Topic_OutTrader,LogText_Addon_ErolTrade);
Npc_ExchangeRoutine(self,"Home");
Erol_IsAtHome = TRUE;
};
B_GiveTradeInv(self);
};
instance DIA_Addon_Erol_Teach(C_Info)
{
npc = VLK_4303_Addon_Erol;
nr = 99;
condition = DIA_Addon_Erol_Teach_Condition;
information = DIA_Addon_Erol_Teach_Info;
permanent = TRUE;
description = "Ukaž mi, jak tvrdě udeřit.";
};
func int DIA_Addon_Erol_Teach_Condition()
{
if(Erol_Addon_TeachPlayer == TRUE)
{
return TRUE;
};
};
func void DIA_Addon_Erol_Teach_Info()
{
AI_Output(other,self,"DIA_Addon_Erol_Teach_15_00"); //Ukaž mi, jak tvrdě udeřit.
if(MIS_Addon_Erol_BanditStuff != LOG_SUCCESS)
{
AI_Output(self,other,"DIA_Addon_Erol_Teach_10_01"); //Dobře, ale uděláš pro mě jednu laskavost.
AI_Output(self,other,"DIA_Addon_Erol_Teach_10_02"); //Pomoz mi zachránit mou reputaci, a přines mi zpět mé kamenné desky.
AI_Output(self,other,"DIA_Addon_Erol_Teach_10_03"); //Pak ti ukážu, jak lépe využít své síly v boji.
}
else if(Erol_Bonus == FALSE)
{
AI_Output(self,other,"DIA_Addon_Erol_Teach_Add_10_00"); //Dobře. Sleduj. Je to jednoduchý trik.
AI_Output(self,other,"DIA_Addon_Erol_Teach_Add_10_01"); //Když někoho praštíš, nesmíš použít jen sílu paže, ale sílu celého těla.
AI_Output(self,other,"DIA_Addon_Erol_Teach_Add_10_02"); //Otoč se bokem, vystrč rameno dopředu a ve stejnou chvíli vymršti ruku.
AI_Output(self,other,"DIA_Addon_Erol_Teach_Add_10_03"); //(Smích) Když se dobře strefíš, poznáš ten rozdíl!
B_RaiseAttribute_Bonus(other,ATR_STRENGTH,1);
Erol_Bonus = TRUE;
}
else
{
AI_Output(self,other,"DIA_Addon_Erol_Teach_Add_10_04"); //Pokud chceš vědět víc, musíš tvrdě trénovat...
Info_ClearChoices(DIA_Addon_Erol_Teach);
Info_AddChoice(DIA_Addon_Erol_Teach,Dialog_Back,DIA_Addon_Erol_Teach_Back);
Info_AddChoice(DIA_Addon_Erol_Teach,b_buildlearnstringforskills(PRINT_LearnSTR1,B_GetLearnCostAttribute(other,ATR_STRENGTH)),DIA_Addon_Erol_Teach_STR_1);
Info_AddChoice(DIA_Addon_Erol_Teach,b_buildlearnstringforskills(PRINT_LearnSTR5,B_GetLearnCostAttribute(other,ATR_STRENGTH) * 5),DIA_Addon_Erol_Teach_STR_5);
};
};
func void DIA_Addon_Erol_Teach_Back()
{
Info_ClearChoices(DIA_Addon_Erol_Teach);
};
func void DIA_Addon_Erol_Teach_STR_1()
{
B_TeachAttributePoints(self,other,ATR_STRENGTH,1,T_MAX);
Info_ClearChoices(DIA_Addon_Erol_Teach);
Info_AddChoice(DIA_Addon_Erol_Teach,Dialog_Back,DIA_Addon_Erol_Teach_Back);
Info_AddChoice(DIA_Addon_Erol_Teach,b_buildlearnstringforskills(PRINT_LearnSTR1,B_GetLearnCostAttribute(other,ATR_STRENGTH)),DIA_Addon_Erol_Teach_STR_1);
Info_AddChoice(DIA_Addon_Erol_Teach,b_buildlearnstringforskills(PRINT_LearnSTR5,B_GetLearnCostAttribute(other,ATR_STRENGTH) * 5),DIA_Addon_Erol_Teach_STR_5);
};
func void DIA_Addon_Erol_Teach_STR_5()
{
B_TeachAttributePoints(self,other,ATR_STRENGTH,5,T_MAX);
Info_ClearChoices(DIA_Addon_Erol_Teach);
Info_AddChoice(DIA_Addon_Erol_Teach,Dialog_Back,DIA_Addon_Erol_Teach_Back);
Info_AddChoice(DIA_Addon_Erol_Teach,b_buildlearnstringforskills(PRINT_LearnSTR1,B_GetLearnCostAttribute(other,ATR_STRENGTH)),DIA_Addon_Erol_Teach_STR_1);
Info_AddChoice(DIA_Addon_Erol_Teach,b_buildlearnstringforskills(PRINT_LearnSTR5,B_GetLearnCostAttribute(other,ATR_STRENGTH) * 5),DIA_Addon_Erol_Teach_STR_5);
};
instance DIA_ADDON_EROL_LURKER(C_Info)
{
npc = VLK_4303_Addon_Erol;
nr = 10;
condition = dia_addon_erol_lurker_condition;
information = dia_addon_erol_lurker_info;
permanent = TRUE;
description = "Jak to jde?";
};
func int dia_addon_erol_lurker_condition()
{
if((MIS_Addon_Erol_BanditStuff == LOG_SUCCESS) && (Npc_GetDistToWP(self,"NW_BIGFARM_HUT_IN_01") < 3000))
{
return TRUE;
};
};
func void dia_addon_erol_lurker_info()
{
AI_Output(other,self,"DIA_VLK_4303_Addon_Erol_Lurker_01_00"); //Jak to jde?
if((Kapitel >= 1) && (MIS_RABOGLAV == FALSE) && (MIS_Addon_Erol_BanditStuff == LOG_SUCCESS) && (Npc_GetDistToWP(self,"NW_BIGFARM_HUT_IN_01") < 3000))
{
AI_Output(self,other,"DIA_VLK_4303_Addon_Erol_Lurker_01_01"); //(naštvaně) Do háje! Podívej se na můj dům - a to jsem ho zrovna dal do kupy.
AI_Output(other,self,"DIA_VLK_4303_Addon_Erol_Lurker_01_02"); //A co s ním bylo?
AI_Output(self,other,"DIA_VLK_4303_Addon_Erol_Lurker_01_03"); //Představ si, nějaká prokletá nestvůra v něm udělala bordel! Všechen nábytek rozbila na padrť!
AI_Output(self,other,"DIA_VLK_4303_Addon_Erol_Lurker_01_04"); //Dokonce i truhlu rozbila a sežrala celý její obsah.
AI_Output(self,other,"DIA_VLK_4303_Addon_Erol_Lurker_01_05"); //A Thorben ji teď musí spravit!
AI_Output(self,other,"DIA_VLK_4303_Addon_Erol_Lurker_01_06"); //Všechny stěny a celou podlahu blátem a špínou zasvinila! Nechala tu po sobě smrad zhnilých ryb! Zápach se drží, že ještě teď mě to do očí řeže!
AI_Output(other,self,"DIA_VLK_4303_Addon_Erol_Lurker_01_07"); //A k čemu jsou ti dva vazouni se sekyrama, co se ti tu motají kolem chaty?
AI_Output(self,other,"DIA_VLK_4303_Addon_Erol_Lurker_01_08"); //Oni tvrdí, že nic neviděli... prokletí hlupáci!
AI_Output(self,other,"DIA_VLK_4303_Addon_Erol_Lurker_01_09"); //A pak se ještě opovažujou mě žádat o peníze. Gobliní ohon na ně... a ne zlato!
AI_Output(self,other,"DIA_VLK_4303_Addon_Erol_Lurker_01_10"); //Vsadím se, že si trošičku přihnuli jako obvykle a trošku si pospali, prokleté hovada!
AI_Output(self,other,"DIA_VLK_4303_Addon_Erol_Lurker_01_11"); //Mimochodem si myslím, že se tvor tady stále někde okolo potlouká.
AI_Output(self,other,"DIA_VLK_4303_Addon_Erol_Lurker_01_12"); //Sám bych jí nakopnul, ale po příběhu s bandity mě nějak rozbolela noha.
AI_Output(self,other,"DIA_VLK_4303_Addon_Erol_Lurker_01_13"); //Poslyš? zabij tu příšeru, a já ti za to zaplatím!
AI_Output(other,self,"DIA_VLK_4303_Addon_Erol_Lurker_01_14"); //Dobře! Jestli ji někde zmerčím, budiž - zabiju ji pro tebe.
AI_Output(self,other,"DIA_VLK_4303_Addon_Erol_Lurker_01_15"); //Výborně! Jen nezapomeň donést její drápy, musejí mí nějakou magickou sílu. Zdá se, že se ta potvora pohybuje jen tady!
AI_Output(self,other,"DIA_VLK_4303_Addon_Erol_Lurker_01_16"); //Je to nutné... Truhla na půlky! (smích) Noční můra!
Wld_InsertNpc(lurker_uniq,"NW_LAKE_GREG_TREASURE_01");
MIS_RABOGLAV = LOG_Running;
Log_CreateTopic(TOPIC_RABOGLAV,LOG_MISSION);
Log_SetTopicStatus(TOPIC_RABOGLAV,LOG_Running);
B_LogEntry(TOPIC_RABOGLAV,"Erol mi řekl o útoku na jeho dům. Myslím si, že to udělalo něco, co smrdělo po zkažených rybách. Souhlasil jsem, že se vypořádám s tímto stvořením, ale nesmím zapomenout získat z ní trofej.");
}
else if(Kapitel == 3)
{
AI_Output(self,other,"DIA_VLK_4303_Addon_Erol_Lurker_01_17"); //Z těch postav v černých pláštích mám husí kůži.
AI_Output(self,other,"DIA_VLK_4303_Addon_Erol_Lurker_01_18"); //Něco tady neustále chodí, něco čenichá...(nervózně) Nelíbí se mi to!
}
else
{
AI_Output(self,other,"DIA_VLK_4303_Addon_Erol_Lurker_01_19"); //Zatím je vše v pořádku.
AI_Output(self,other,"DIA_VLK_4303_Addon_Erol_Lurker_01_20"); //Jestli se něco uděje, dám ti vědět.
};
};
instance DIA_VLK_4303_ADDON_EROL_RABOGLAV(C_Info)
{
npc = VLK_4303_Addon_Erol;
nr = 1;
condition = dia_vlk_4303_addon_erol_raboglav_condition;
information = dia_vlk_4303_addon_erol_raboglav_info;
permanent = FALSE;
description = "S tou tvojí nestvůrou je konec!";
};
func int dia_vlk_4303_addon_erol_raboglav_condition()
{
if((MIS_RABOGLAV == LOG_Running) && Npc_IsDead(lurker_uniq) && (Npc_HasItems(other,ITAT_LEADERLURKER) >= 1))
{
return TRUE;
};
};
func void dia_vlk_4303_addon_erol_raboglav_info()
{
B_GivePlayerXP(150);
AI_Output(other,self,"DIA_VLK_4303_Addon_Erol_RABOGLAV_01_00"); //Stou nestvůrou je konec! Vyklubal se z ní nakonec obrovský číhavec.
AI_Output(other,self,"DIA_VLK_4303_Addon_Erol_RABOGLAV_01_01"); //A tady jsou i ty jeho drápy. To je vše, co jsi žádal.
B_GiveInvItems(other,self,ITAT_LEADERLURKER,1);
Npc_RemoveInvItems(self,ITAT_LEADERLURKER,1);
if(Trophy_LURKERLEADER == TRUE)
{
Ext_RemoveFromSlot(other,"BIP01 PELVIS");
Npc_RemoveInvItems(other,ItUt_LURKERLEADER,Npc_HasItems(other,ItUt_LURKERLEADER));
Trophy_LURKERLEADER = FALSE;
};
AI_Output(self,other,"DIA_VLK_4303_Addon_Erol_RABOGLAV_01_02"); //Ohó! S takovýma by se dala i hlava setnout na jedenkrát!
AI_Output(self,other,"DIA_VLK_4303_Addon_Erol_RABOGLAV_01_03"); //Myslím, že sis zřejmě musel dát s tím práci... s ním?
AI_Output(other,self,"DIA_VLK_4303_Addon_Erol_RABOGLAV_01_04"); //Ano, docela to stálo úsilí. Doufám ale, že jsem se nedřel zbytečně.
AI_Output(self,other,"DIA_VLK_4303_Addon_Erol_RABOGLAV_01_05"); //Samozřejmně, že ne. Tady, jak jsem slíbil je tvoje odměna.
B_GiveInvItems(self,other,ItMi_Gold,300);
AI_Output(self,other,"DIA_VLK_4303_Addon_Erol_RABOGLAV_01_06"); //Hory ze zlata to sice nejsou, ale i tak si myslím, že je to dost. Sám to víš, časy jsou zlé!
AI_Output(other,self,"DIA_VLK_4303_Addon_Erol_RABOGLAV_01_07"); //Je to dost. Stává se to!
MIS_RABOGLAV = LOG_SUCCESS;
Log_SetTopicStatus(TOPIC_RABOGLAV,LOG_SUCCESS);
B_LogEntry(TOPIC_RABOGLAV,"Erol by velice překvapený když uviděl velikost drápů číhavce, který ho obtěžoval.");
};
//--------------------CEO----------------------------------------------
instance DIA_ADDON_EROL_RECRDT(C_Info)
{
npc = VLK_4303_Addon_Erol;
nr = 5;
condition = dia_addon_erol_recrdt_condition;
information = dia_addon_erol_recrdt_info;
permanent = FALSE;
description = "Jak jde obchod?";
};
func int dia_addon_erol_recrdt_condition()
{
if((MIS_PPL_FOR_TOWER == LOG_Running) && (PasswordSet == TRUE) && (Erol_IsAtHome == TRUE) && (VALERANRECRUITEDDT == FALSE))
{
return TRUE;
};
};
func void dia_addon_erol_recrdt_info()
{
AI_Output(other,self,"DIA_Addon_Erol_RecrDT_15_00"); //Jak jde obchod?
AI_Output(self,other,"DIA_Addon_Erol_RecrDT_10_01"); //Zdravím tě. Ale nic moc.
AI_Output(self,other,"DIA_Addon_Erol_RecrDT_10_02"); //Už jsem starý na to, chodit sem a tam s vozíkem plným zboží. A na cestách je to čím dál tím nebezpečnější.
AI_Output(self,other,"DIA_Addon_Erol_RecrDT_10_03"); //Tady banditi, tam příšery a teď ještě ty přízraky v temných pláštích, co se tady potulují.
AI_Output(self,other,"DIA_Addon_Erol_RecrDT_10_04"); //Šel bych na odpočinek, ale to bych umřel nudou.
AI_Output(other,self,"DIA_Addon_Erol_RecrDT_15_05"); //A ty bys nechtěl změnit způsob své živnosti?
AI_Output(self,other,"DIA_Addon_Erol_RecrDT_10_06"); //Co máš na mysli?
AI_Output(other,self,"DIA_Addon_Erol_RecrDT_15_07"); //Možná bych pro tebe měl práci.
AI_Output(other,self,"DIA_Addon_Erol_RecrDT_15_08"); //Tak se přihodilo, že teď jsem majitelem jedné věže v blízkosti Onarovy farmy a chci tam vybudovat malý tábor. A zoufale potřebuju schopného správce.
AI_Output(self,other,"DIA_Addon_Erol_RecrDT_10_09"); //A nabízíš to místo mě? Hmm, zajímavá nabídka, ale hned ti neodpovím.
AI_Output(self,other,"DIA_Addon_Erol_RecrDT_10_10"); //Vzpomínáš, jsem stále obchodník. Já umím dobře nabízet zboží a počítat peníze, ale zkušenosti s vedením lidí nemám.
AI_Output(other,self,"DIA_Addon_Erol_RecrDT_15_11"); //S lidma si poradím sám.
AI_Output(other,self,"DIA_Addon_Erol_RecrDT_15_12"); //Ty, pokud budeš souhlasit, budeš mít na starost finance a obchod: starat se o výplaty a inventarizaci všech věcí. Jednat s dodavateli a přimět je, aby nám poskytli ty nejlepší ceny.
AI_Output(self,other,"DIA_Addon_Erol_RecrDT_10_13"); //To je dobré. A co bydlení? Chápu to dobře, že se budu muset vzdát svého domova a bydlet s vám.
AI_Output(other,self,"DIA_Addon_Erol_RecrDT_15_14"); //To je pravda. Žít musíš s náma. Ale jídlo bude na můj účet.
AI_Output(self,other,"DIA_Addon_Erol_RecrDT_10_15"); //Připouštím - je to velmi vážné rozhodnutí... Musím si to rozmyslet. Přijď zítra, dám ti odpověď!
EROLDECISIONDAY = Wld_GetDay();
};
instance DIA_ADDON_EROL_AGREES_RECRDT(C_Info)
{
npc = VLK_4303_Addon_Erol;
nr = 5;
condition = dia_addon_erol_agrees_recrdt_condition;
information = dia_addon_erol_agrees_recrdt_info;
permanent = FALSE;
description = "Co tedy říkáš na moji nabídku?";
};
func int dia_addon_erol_agrees_recrdt_condition()
{
if(Npc_KnowsInfo(hero,dia_addon_erol_recrdt) && (EROLDECISIONDAY < Wld_GetDay()) && (VALERANRECRUITEDDT == FALSE))
{
return TRUE;
};
};
func void dia_addon_erol_agrees_recrdt_info()
{
AI_Output(other,self,"DIA_Addon_Erol_Agrees_RecrDT_15_00"); //Co tedy říkáš na moji nabídku?
AI_Output(self,other,"DIA_Addon_Erol_Agrees_RecrDT_10_01"); //(Udiveně) Máš nějaké další návrhy?
AI_Output(self,other,"DIA_Addon_Erol_Agrees_RecrDT_10_02"); //Dělám si legraci. Uvědomil jsem si, že je to pro mě v současné době nejlepší nabídka.
AI_Output(self,other,"DIA_Addon_Erol_Agrees_RecrDT_10_03"); //Taky mě nikdy nevadilo vyzkoušet něco nového.
AI_Output(self,other,"DIA_Addon_Erol_Agrees_RecrDT_10_04"); //Jinými slovy, souhlasím!
AI_Output(other,self,"DIA_Addon_Erol_Agrees_RecrDT_15_05"); //Skvěle! V tom případě si zbal své věci a vyraz do tvrze, budu tam na tebe čekat. A abych nezapomněl, kolik bys chtěl za práci?
AI_Output(self,other,"DIA_Addon_Erol_Agrees_RecrDT_10_06"); //Když počítám, že ubytování a jídlo je na tebe, 40 zlatých na den by mělo stačit.
AI_Output(self,other,"DIA_Addon_Erol_Agrees_RecrDT_10_07"); //Úspory nějaké mám, do šantánu už vzhledem ke svému věku nechodím a většinu času stejně budu trávit tam, tak co.
Info_ClearChoices(dia_addon_erol_agrees_recrdt);
Info_AddChoice(dia_addon_erol_agrees_recrdt,"Dobře, uvidíme se v tvrzi.",dia_addon_erol_agrees_recrdt_yes);
Info_AddChoice(dia_addon_erol_agrees_recrdt,"40 zlatých? Musím o tom popřemýšlet...",dia_addon_erol_agrees_recrdt_no);
};
func void dia_addon_erol_agrees_recrdt_yes()
{
B_GivePlayerXP(500);
AI_Output(other,self,"DIA_Addon_Erol_Agrees_RecrDT_yes_15_00"); //Dobře, uvidíme se ve tvrzi. Jestli po tobě budou chtít heslo, tak jim řekni 'dračí poklad'.
AI_Output(self,other,"DIA_Addon_Erol_Agrees_RecrDT_yes_10_01"); //Dobře, je to jen heslo, a žádný vstupní poplatek. Na viděnou!
B_LogEntry(TOPIC_PPL_FOR_TOWER,"Erol souhlasil, že pro mne bude pracovat jako správce.");
self.npcType = NPCTYPE_FRIEND;
self.aivar[AIV_ToughGuy] = TRUE;
self.aivar[AIV_IGNORE_Theft] = TRUE;
self.aivar[AIV_IGNORE_Sheepkiller] = TRUE;
self.aivar[AIV_IgnoresArmor] = TRUE;
EROLRECRUITEDDT = TRUE;
AI_StopProcessInfos(self);
Npc_ExchangeRoutine(self,"TowerCEO");
};
func void dia_addon_erol_agrees_recrdt_no()
{
AI_Output(other,self,"DIA_Addon_Erol_Agrees_RecrDT_no_15_00"); //40 zlatých? Promiň, musím o tom ještě popřemýšlet...
AI_StopProcessInfos(self);
};
instance DIA_ADDON_EROL_ATLAST_RECRDT(C_Info)
{
npc = VLK_4303_Addon_Erol;
nr = 5;
condition = dia_addon_erol_atlast_recrdt_condition;
information = dia_addon_erol_atlast_recrdt_info;
permanent = FALSE;
description = "Jsi přijat!";
};
func int dia_addon_erol_atlast_recrdt_condition()
{
if(Npc_KnowsInfo(hero,dia_addon_erol_agrees_recrdt) && (VALERANRECRUITEDDT == FALSE) && (EROLRECRUITEDDT == FALSE))
{
return TRUE;
};
};
func void dia_addon_erol_atlast_recrdt_info()
{
B_GivePlayerXP(300);
AI_Output(other,self,"DIA_Addon_Erol_Atlast_RecrDT_15_00"); //Jsi přijat! Jestli po tobě budou chtít heslo, tak jim řekni 'dračí poklad'.
AI_Output(self,other,"DIA_Addon_Erol_Atlast_RecrDT_10_01"); //Není příliš moudré používat heslo, o kterém sní každý druhý dobrodruh, který o sobě říká že je hledač pokladů a nechce se mu pracovat. Ale to není můj případ - uvidíme se!
B_LogEntry(TOPIC_PPL_FOR_TOWER,"Erol souhlasil, že pro mne bude pracovat jako správce.");
self.npcType = NPCTYPE_FRIEND;
self.aivar[AIV_ToughGuy] = TRUE;
self.aivar[AIV_IGNORE_Theft] = TRUE;
self.aivar[AIV_IGNORE_Sheepkiller] = TRUE;
self.aivar[AIV_IgnoresArmor] = TRUE;
EROLRECRUITEDDT = TRUE;
AI_StopProcessInfos(self);
Npc_ExchangeRoutine(self,"TowerCEO");
};
instance DIA_EROL_FIRSTCEO(C_Info)
{
npc = VLK_4303_Addon_Erol;
nr = 5;
condition = dia_erol_firstceo_condition;
information = dia_erol_firstceo_info;
permanent = FALSE;
important = TRUE;
};
func int dia_erol_firstceo_condition()
{
if((EROLRECRUITEDDT == TRUE) && (Npc_GetDistToWP(self,"NW_CASTLEMINE_HUT_10") < 5000))
{
return TRUE;
};
};
func void dia_erol_firstceo_info()
{
AI_Output(self,other,"DIA_Erol_FirstCEO_10_00"); //Čekal jsem, že to nebude úplně ideální, ale tohle...
AI_Output(self,other,"DIA_Erol_FirstCEO_10_01"); //Krev, prach, bordel a nábytek rozbitej, no dobře s tím si poradíme. Teď do práce.
AI_Output(self,other,"DIA_Erol_FirstCEO_10_02"); //Říkal jsi, že zde chceš vybudovat tábor. Nepletu se?
AI_Output(other,self,"DIA_Erol_FirstCEO_15_03"); //Ano. Lord Hagen chce, abych v této oblasti nastolil pořádek a z toho důvodu mě byla přenechána tahle tvrz.
AI_Output(other,self,"DIA_Erol_FirstCEO_15_04"); //A ze stejného důvodu souhlasil i Onar.
AI_Output(other,self,"DIA_Erol_FirstCEO_15_05"); //Ale nemůžu spravovat a chránit tuhle tvrz sám, potřebuju lidi. S prvními dvěma ses už seznámil.
AI_Output(self,other,"DIA_Erol_FirstCEO_10_06"); //Líbí se mi tvé plány. Poslouchej, nejprve budeme muset tohle místo trochu zkulturnit.
AI_Output(self,other,"DIA_Erol_FirstCEO_10_07"); //No úplně nejdřív od tebe budu potřebovat určitý obnos na nejnutnější výdaje.
AI_Output(other,self,"DIA_Erol_FirstCEO_15_08"); //Kolik?
AI_Output(self,other,"DIA_Erol_FirstCEO_10_09"); //Myslím, že 5000 zlatých bude stačit.
CEONEEDSFIRSTMONEY = TRUE;
};
instance DIA_EROL_FIRSTCEO_MONEYLATE(C_Info)
{
npc = VLK_4303_Addon_Erol;
nr = 5;
condition = dia_erol_firstceo_moneylate_condition;
information = dia_erol_firstceo_moneylate_info;
permanent = FALSE;
description = "Tady je 5000 zlatých.";
};
func int dia_erol_firstceo_moneylate_condition()
{
if((CEONEEDSFIRSTMONEY == TRUE) && (Npc_HasItems(other,ItMi_Gold) >= 5000) && (EROLRECRUITEDDT == TRUE))
{
return TRUE;
};
};
func void dia_erol_firstceo_moneylate_info()
{
B_GivePlayerXP(1000);
AI_Output(other,self,"DIA_Erol_FirstCEO_MoneyLate_15_00"); //Tady je 5000 zlatých.
B_GiveInvItems(other,self,ItMi_Gold,5000);
Npc_RemoveInvItems(self,ItMi_Gold,5000);
AI_Output(self,other,"DIA_Erol_FirstCEO_MoneyLate_10_01"); //Dobře. S penězi si nyní nemusíme dělat starosti a já můžu začít s parcí.
AI_Output(self,other,"DIA_Erol_FirstCEO_MoneyLate_10_02"); //Mimo to, já i ostaní potřebujem něco k jídlu.
AI_Output(self,other,"DIA_Erol_FirstCEO_MoneyLate_10_03"); //Myslím, že pro začátek by mohlo stačit 50 kusů opečeného masa, 25 kusů čerstvých ryb a 10 chlebů.
DT_BUDGET = 5000;
DT_BUDGETACTIVE = TRUE;
EVERYDAYDTMONEY = Wld_GetDay();
CEONEEDSFIRSTMONEY = FALSE;
CEONEEDSFIRSTFOOD = TRUE;
B_LogEntry(TOPIC_PPL_FOR_TOWER,"Pro lidi, co žijí v mé tvrzi potřebuji zásoby jídla - pro začátek 50 kusů opečeného masa, 25 ryb a 10 chlebů.");
};
instance DIA_EROL_FIRSTCEO_FOODLATE(C_Info)
{
npc = VLK_4303_Addon_Erol;
nr = 5;
condition = dia_erol_firstceo_foodlate_condition;
information = dia_erol_firstceo_foodlate_info;
permanent = FALSE;
description = "Tady je všechno potřebné jídlo.";
};
func int dia_erol_firstceo_foodlate_condition()
{
if((CEONEEDSFIRSTFOOD == TRUE) && (Npc_HasItems(other,ItFo_Bread) >= 10) && (Npc_HasItems(other,ItFoMutton) >= 50) && (Npc_HasItems(other,ItFo_Fish) >= 25) && (EROLRECRUITEDDT == TRUE))
{
return TRUE;
};
};
func void dia_erol_firstceo_foodlate_info()
{
B_GivePlayerXP(1000);
AI_Output(other,self,"DIA_Erol_FirstCEO_FoodLate_15_00"); //Tady je všechno potřebné jídlo.
B_GiveInvItems(other,self,ItFoMutton,50);
Npc_RemoveInvItems(self,ItFoMutton,50);
B_GiveInvItems(other,self,ItFo_Fish,25);
Npc_RemoveInvItems(self,ItFo_Fish,25);
B_GiveInvItems(other,self,ItFo_Bread,10);
Npc_RemoveInvItems(self,ItFo_Bread,10);
AI_Output(self,other,"DIA_Erol_FirstCEO_FoodLate_10_01"); //Výborně! Teď mám dost peněz i jídla, abych vedl hospodářství bez problémů.
AI_Output(self,other,"DIA_Erol_FirstCEO_FoodLate_10_02"); //Ale bude to stačit jen na určitou dobu. Nechceš přeci, aby se ti to tady celé zhroutilo?
AI_Output(other,self,"DIA_Erol_FirstCEO_FoodLate_15_03"); //Samozřejmě, že ne. Řekni mi, co mám dělat, abych tomu předešel?
AI_Output(self,other,"DIA_Erol_FirstCEO_FoodLate_10_04"); //Najdi lidi, co pro tebe budou chtít pracovat.
AI_Output(self,other,"DIA_Erol_FirstCEO_FoodLate_10_05"); //Například lovce, kteří budou zajišťovat maso pro zdejší obyvatele.
AI_Output(self,other,"DIA_Erol_FirstCEO_FoodLate_10_06"); //Také je tady důl, možná v něm ještě zůstala nějaká ruda. Měl bys to prověřit.
AI_Output(self,other,"DIA_Erol_FirstCEO_FoodLate_10_07"); //Jedním slovem, přemýšlej. Hodně cestuješ, ne jako já, tak sežeň lidi, kteří se k tobě budou chtít přidat.
AI_Output(other,self,"DIA_Erol_FirstCEO_FoodLate_15_08"); //Dobře... Myslím, že mě pár lidí napadá.
AI_Output(self,other,"DIA_Erol_FirstCEO_FoodLate_10_09"); //Hodně štěstí při hledání. A pamatuj, že dodávky jídla a finanční zajištění jsou na tobě a že většina lidí by chtěla jíst třikrát denně.
AI_Output(self,other,"DIA_Erol_FirstCEO_FoodLate_10_10"); //Já se tím nemohu zabývat, jelikož to vyžaduje cestování mimo tvrz, a pak bych se nemohl věnovat svým povinnostem - řízení a organizaci tábora.
AI_Output(self,other,"DIA_Erol_FirstCEO_FoodLate_10_11"); //Nemůžeš dopustit, aby v tvrzi došli peníze a jídlo.
B_LogEntry(TOPIC_PPL_FOR_TOWER,"Teď, když mám správce, mohu přemýšlet o vylepšeních a hledání lidí, co budou ochotni pro mě pracovat. Zároveň musím myslet na to, aby v táboře nedošli peníze a jídlo.");
DT_FOODSTOCK = 120;
DT_FOODSTOCKACTIVE = TRUE;
EVERYDAYDTFOOD = Wld_GetDay();
CEONEEDSFIRSTFOOD = FALSE;
HURRAYICANHIRE = TRUE;
AI_StopProcessInfos(self);
};
instance DIA_Erol_CanHireCook(C_Info)
{
npc = VLK_4303_Addon_Erol;
nr = 5;
condition = DIA_Erol_CanHireCook_condition;
information = DIA_Erol_CanHireCook_info;
permanent = FALSE;
important = TRUE;
};
func int DIA_Erol_CanHireCook_condition()
{
if((ErolRECRUITEDDT == TRUE) && (CanHireCook == TRUE))
{
return TRUE;
};
};
func void DIA_Erol_CanHireCook_info()
{
AI_Output(self,other,"DIA_Erol_CanHireCook_10_00"); //Do tábora začali přicházet první dodávky potravin. To je dobrá zpráva!
AI_Output(self,other,"DIA_Erol_CanHireCook_10_01"); //Teď vyvstává otázka jeho skladování. Bez dobrého uskladnění se budou potraviny kazit.
AI_Output(other,self,"DIA_Erol_CanHireCook_10_02"); //A co navrhuješ?
AI_Output(self,other,"DIA_Erol_CanHireCook_10_03"); //Podle mého názoru by se šiknul dobrý kuchař, který by si s tím problémem dokázal poradit.
AI_Output(self,other,"DIA_Erol_CanHireCook_10_04"); //Popřemýšlej nad tím, je to vážná věc.
AI_Output(other,self,"DIA_Erol_CanHireCook_10_05"); //Dobře, zkusím to nějak zařídit.
EddaNeed = TRUE;
B_LogEntry(TOPIC_PPL_FOR_TOWER,"V táboře je potřeba kuchař, který by se postaral i o skladování potravin. Zajímalo by mě, kde se na něj poptat?");
AI_StopProcessInfos(self);
};
instance DIA_Erol_CanHireSmith(C_Info)
{
npc = VLK_4303_Addon_Erol;
nr = 5;
condition = DIA_Erol_CanHireSmith_condition;
information = DIA_Erol_CanHireSmith_info;
permanent = FALSE;
important = TRUE;
};
func int DIA_Erol_CanHireSmith_condition()
{
if((ErolRECRUITEDDT == TRUE) && (CanHireSmith == TRUE))
{
return TRUE;
};
};
func void DIA_Erol_CanHireSmith_info()
{
AI_Output(self,other,"DIA_Erol_CanHireSmith_10_00"); //V táboře započala těžba rudy.
AI_Output(self,other,"DIA_Erol_CanHireSmith_10_01"); //Je čas přemýšlet o tom, kde sehnat dobrého kováře. Tím spíš, že kovárnu tady už máme.
AI_Output(other,self,"DIA_Erol_CanHireSmith_10_02"); //A kde ho mám hledat? Dobrých kovářů je na tomhle ostrově už tak málo.
AI_Output(self,other,"DIA_Erol_CanHireSmith_10_03"); //Souhlasím. Ale jestli chceš, aby tvůj tábor za něco stál, tak bys ho měl najít.
AI_Output(self,other,"DIA_Erol_CanHireSmith_10_04"); //Nabrousit zbraně, vyspravit zbroj a vyrábět předměty z rudy, kterou těžíme, dokáže jenom kovář.
AI_Output(self,other,"DIA_Erol_CanHireSmith_10_05"); //Tak co kdybys radši zapnul mozkové závity a popřemýšlel, kdo by to místo mohl vzít.
AI_Output(other,self,"DIA_Erol_CanHireSmith_10_06"); //Dobře, zkusím něco vymyslet.
CarlNeed = TRUE;
B_LogEntry(TOPIC_PPL_FOR_TOWER,"Tábor potřebuje kováře. Bez něho se nemůže dál rozvíjet.");
AI_StopProcessInfos(self);
};
instance DIA_Erol_CanHireHealer(C_Info)
{
npc = VLK_4303_Addon_Erol;
nr = 5;
condition = DIA_Erol_CanHireHealer_condition;
information = DIA_Erol_CanHireHealer_info;
permanent = FALSE;
important = TRUE;
};
func int DIA_Erol_CanHireHealer_condition()
{
var int DayNow;
DayNow = Wld_GetDay();
if((ErolRECRUITEDDT == TRUE) && (SagittaIsDead == FALSE) && ((WOLFRECRUITEDDT == TRUE) || (ALRIKRECRUITEDDT == TRUE) || (GAYVERNRECRUITEDDT == TRUE)))
{
return TRUE;
};
};
func void DIA_Erol_CanHireHealer_info()
{
AI_Output(self,other,"DIA_Erol_CanHireHealer_10_00"); //V posledních dnech v táboře přibylo stráží.
AI_Output(self,other,"DIA_Erol_CanHireHealer_10_01"); //To je dobře, protože jsem nedávno byl napaden několika dravými potvorami.
AI_Output(self,other,"DIA_Erol_CanHireHealer_10_02"); //Jeden ze strážců utrpěl v tom souboji zranění, no naštěstí nejsou příliš vážná.
AI_Output(self,other,"DIA_Erol_CanHireHealer_10_03"); //Ale jestli to tak půjde dál, tak budem za chvilku bez lidí.
AI_Output(other,self,"DIA_Erol_CanHireHealer_10_04"); //Na co narážíš?
AI_Output(self,other,"DIA_Erol_CanHireHealer_10_05"); //Potřebujeme léčitele. A také alchymistu, který dokáže na ošetření takových zranění vařit lektvary.
AI_Output(other,self,"DIA_Erol_CanHireHealer_10_06"); //Hmm... To bude větší problém, než s kovářem.
AI_Output(self,other,"DIA_Erol_CanHireHealer_10_07"); //Chápu, že to není snadný úkol, ale od jeho vyřešení závisí životy lidí v táboře.
AI_Output(self,other,"DIA_Erol_CanHireHealer_10_08"); //Proto bys s tím měl něco udělat.
AI_Output(other,self,"DIA_Erol_CanHireHealer_10_09"); //Dobře, seženu nám léčitele.
SagittaNeed = TRUE;
B_LogEntry(TOPIC_PPL_FOR_TOWER,"Tábor potřebuje léčitele. Bez něj tu lidé dlouho nepřežijí.");
AI_StopProcessInfos(self);
};
instance DIA_Erol_CanProduceSmith(C_Info)
{
npc = VLK_4303_Addon_Erol;
nr = 5;
condition = DIA_Erol_CanProduceSmith_condition;
information = DIA_Erol_CanProduceSmith_info;
permanent = FALSE;
important = TRUE;
};
func int DIA_Erol_CanProduceSmith_condition()
{
var int DayNow;
DayNow = Wld_GetDay();
if((ErolRECRUITEDDT == TRUE) && (CARLRECRUITEDDT == TRUE) && (CarlDayHire < DayNow) && (CarlIsDead == FALSE))
{
return TRUE;
};
};
func void DIA_Erol_CanProduceSmith_info()
{
AI_Output(self,other,"DIA_Erol_CanProduceSmith_10_00"); //Carl začal pracovat v kovárně. Jsem rád že se ti ho povedlo přemluvit, aby pro nás pracoval.
AI_Output(self,other,"DIA_Erol_CanProduceSmith_10_01"); //Teď si musíme promluvit o tom hlavním.
AI_Output(other,self,"DIA_Erol_CanProduceSmith_10_02"); //Co tím myslíš?
AI_Output(self,other,"DIA_Erol_CanProduceSmith_10_03"); //Kovárna musí přinášet zisky, jinak je k ničemu.
AI_Output(other,self,"DIA_Erol_CanProduceSmith_10_04"); //Dobrá, jaké máš nápady?
AI_Output(self,other,"DIA_Erol_CanProduceSmith_10_05"); //Mohli bychom naše zásoby rudy přetavit na ingoty.
AI_Output(self,other,"DIA_Erol_CanProduceSmith_10_06"); //To je tovar, po kterém je nyní největší poptávka, a taky nám to umožní snížit náklady na provoz tábora.
AI_Output(other,self,"DIA_Erol_CanProduceSmith_10_07"); //To zní dobře.
AI_Output(self,other,"DIA_Erol_CanProduceSmith_10_08"); //Mně se to taky líbí. Tak nad tím popřemýšlej.
CanSellOre = TRUE;
B_LogEntry(TOPIC_PPL_FOR_TOWER,"Erol navrhl použít zásoby rudy pro výrobu železných ingotů, které pak můžeme dál prodávat. To nám bude poskytovat dostatečný příjem.");
AI_StopProcessInfos(self);
};
instance DIA_Erol_CanProduceWeapon(C_Info)
{
npc = VLK_4303_Addon_Erol;
nr = 5;
condition = DIA_Erol_CanProduceWeapon_condition;
information = DIA_Erol_CanProduceWeapon_info;
permanent = FALSE;
important = TRUE;
};
func int DIA_Erol_CanProduceWeapon_condition()
{
var int DayNow;
DayNow = Wld_GetDay();
if((ErolRECRUITEDDT == TRUE) && (WOLFRECRUITEDDT == TRUE) && (ALRIKRECRUITEDDT == TRUE) && (GAYVERNRECRUITEDDT == TRUE) && (CARLRECRUITEDDT == TRUE) && (CarlDayHire < DayNow) && (CarlIsDead == FALSE))
{
return TRUE;
};
};
func void DIA_Erol_CanProduceWeapon_info()
{
AI_Output(self,other,"DIA_Erol_CanProduceWeapon_10_01"); //V poslední době v táboře přibylo lidí. Myslím, že bychom měli lépe vyzbrojit naše stráže.
AI_Output(self,other,"DIA_Erol_CanProduceWeapon_10_02"); //Tím spíš, že jsou těžké časy, kolem dokola se to hemží dravou zvěří.
AI_Output(self,other,"DIA_Erol_CanProduceWeapon_10_03"); //Někdo nedávno dokonce viděl poblíž živého skřeta!
AI_Output(self,other,"DIA_Erol_CanProduceWeapon_10_04"); //Jestli se nebudeme starat o svou bezpečnost, stane se tohle místo brzo kořistí zločinců nebo skřetů.
AI_Output(other,self,"DIA_Erol_CanProduceWeapon_10_05"); //Co pro to můžeme udělat?
AI_Output(self,other,"DIA_Erol_CanProduceWeapon_10_06"); //Zbraně nám vyková Carl. Není to sice mistr kovář, ale vykovat dobrý meč dovede.
AI_Output(self,other,"DIA_Erol_CanProduceWeapon_10_07"); //Ale naši chlapci potřebují lepší zbroje. To co mají teď, je nezachrání ani před krvavou mouchou.
AI_Output(other,self,"DIA_Erol_CanProduceWeapon_10_08"); //Co navrhuješ?
AI_Output(self,other,"DIA_Erol_CanProduceWeapon_10_13"); //Abychom mohli vyrábět vlastní zbroje, potřebujeme schémata a nákresy.
AI_Output(self,other,"DIA_Erol_CanProduceWeapon_10_14"); //Vím, že jsi navštívil různá místa, tak jsi třeba něco podobného už viděl.
AI_Output(self,other,"DIA_Erol_CanProduceWeapon_10_15"); //Jestli něco získáš, dones to ke mně a já se už postarám, aby naši chlapci nechodili v hadrech.
CanGiveArmor = TRUE;
AI_StopProcessInfos(self);
};
instance DIA_EROL_CrawlerArmor(C_Info)
{
npc = VLK_4303_Addon_Erol;
nr = 5;
condition = DIA_EROL_CrawlerArmor_condition;
information = DIA_EROL_CrawlerArmor_info;
permanent = FALSE;
description = "Přinesl jsem plány zbroje.";
};
func int DIA_EROL_CrawlerArmor_condition()
{
if((ErolRECRUITEDDT == TRUE) && (CanGiveArmor == TRUE) && (GiveNewArmorDocs == FALSE) && (Npc_HasItems(other,ItWr_ArmorDocs) >= 1))
{
return TRUE;
};
};
func void DIA_EROL_CrawlerArmor_info()
{
B_GivePlayerXP(1500);
AI_Output(other,self,"DIA_EROL_CrawlerArmor_15_00"); //Přinesl jsem plány zbroje.
B_GiveInvItems(other,self,ItWr_ArmorDocs,1);
Npc_RemoveInvItems(self,ItWr_ArmorDocs,1);
AI_Output(self,other,"DIA_EROL_CrawlerArmor_15_01"); //Dobře, dej mi je. Dám ty nákresy Carlovi, aby se s nimi seznámil.
AI_Output(self,other,"DIA_EROL_CrawlerArmor_15_02"); //Jestli jim porozumí, možná dokáže tu zbroj i vyrobit a za pár dní by už všechny stráže mohly být pořádně vyzbrojeny.
AI_Output(other,self,"DIA_EROL_CrawlerArmor_15_03"); //V to doufám.
GiveNewArmorDocs = Wld_GetDay();
CanGiveArmorDocs = TRUE;
};
instance DIA_EROL_ArmorDone(C_Info)
{
npc = VLK_4303_Addon_Erol;
nr = 5;
condition = DIA_EROL_ArmorDone_condition;
information = DIA_EROL_ArmorDone_info;
permanent = FALSE;
important = TRUE;
};
func int DIA_EROL_ArmorDone_condition()
{
if((ErolRECRUITEDDT == TRUE) && (CanGiveOtherArmor == TRUE))
{
return TRUE;
};
};
func void DIA_EROL_ArmorDone_info()
{
B_GivePlayerXP(200);
AI_Output(self,other,"DIA_EROL_ArmorDone_15_00"); //Carl vyrobil zbroje a já je rozdal mezi kluky.
AI_Output(self,other,"DIA_EROL_ArmorDone_15_01"); //Teď se o jejich bezpečnost už nemusíme starat, zbroje vypadají velmi silně.
AI_Output(self,other,"DIA_EROL_ArmorDone_15_02"); //Tady, ber! Tenhle kousek jsem nechal vyrobit speciálně pro tebe. Určitě ti přijde vhod.
B_GiveInvItems(self,other,ItAr_OldSteelArmor,1);
AI_Output(other,self,"DIA_EROL_ArmorDone_15_03"); //Děkuju.
};
instance DIA_Erol_BUSINESSACTION(C_Info)
{
npc = VLK_4303_Addon_Erol;
nr = 21;
condition = dia_Erol_businessaction_condition;
information = dia_Erol_businessaction_info;
permanent = TRUE;
description = "Chtěl bych něco udělat...";
};
func int dia_Erol_businessaction_condition()
{
if((HURRAYICANHIRE == TRUE) && (ErolRECRUITEDDT == TRUE))
{
return TRUE;
};
};
func void dia_Erol_businessaction_info()
{
AI_Output(other,self,"DIA_Erol_BusinessAction_15_00"); //Chtěl bych něco udělat.
AI_Output(self,other,"DIA_Erol_BusinessAction_10_01"); //Co konkrétně?
Info_ClearChoices(dia_Erol_businessaction);
Info_AddChoice(dia_Erol_businessaction,Dialog_Back,dia_Erol_businessaction_back);
Info_AddChoice(dia_Erol_businessaction,"Vybrat zlato z táborové pokladnice.",dia_Erol_businessaction_budgettake);
Info_AddChoice(dia_Erol_businessaction,"Uložit zlato do táborové pokladnice.",dia_Erol_businessaction_budgetgive);
Info_AddChoice(dia_Erol_businessaction,"Prodat proviant ze skladu v táboře.",dia_Erol_businessaction_foodsell);
Info_AddChoice(dia_Erol_businessaction,"Uložit proviant do skladu v táboře.",dia_Erol_businessaction_foodgive);
Info_AddChoice(DIA_Erol_businessaction,"Sebrat magickou rudu ze skladu v táboře.",DIA_Erol_businessaction_oretake);
Info_AddChoice(DIA_Erol_businessaction,"Sebrat železnou rudu ze skladu v táboře.",DIA_Erol_businessaction_irontake);
if(CanSellOre == TRUE)
{
if(DoSellOre == FALSE)
{
Info_AddChoice(DIA_Erol_businessaction,"Začít s výrobou železných a rudných ingotů.",DIA_Erol_businessaction_produce_on);
}
else
{
Info_AddChoice(DIA_Erol_businessaction,"Zastavit výrobu železných a rudných ingotů.",DIA_Erol_businessaction_produce_off);
};
};
};
func void dia_Erol_businessaction_oretake()
{
AI_Output(other,self,"dia_Erol_businessaction_oretake_15_00"); //Chtěl bych sebrat magickou rudu ze skladu v táboře.
if(DT_BUDGET_ORE == FALSE)
{
AI_Output(self,other,"dia_Erol_businessaction_oretake_10_01"); //Bohužel na to teď nemáme dostatečné zásoby rudy.
}
else
{
AI_Output(self,other,"dia_Erol_businessaction_oretake_10_02"); //Dobře, tady je veškerá magická ruda, co máme.
B_GiveInvItems(self,other,ItMi_Nugget,DT_BUDGET_ORE);
DT_BUDGET_ORE = 0;
};
Info_ClearChoices(dia_Erol_businessaction);
Info_AddChoice(dia_Erol_businessaction,Dialog_Back,dia_Erol_businessaction_back);
Info_AddChoice(dia_Erol_businessaction,"Vybrat zlato z táborové pokladnice.",dia_Erol_businessaction_budgettake);
Info_AddChoice(dia_Erol_businessaction,"Uložit zlato do táborové pokladnice.",dia_Erol_businessaction_budgetgive);
Info_AddChoice(dia_Erol_businessaction,"Prodat proviant ze skladu v táboře.",dia_Erol_businessaction_foodsell);
Info_AddChoice(dia_Erol_businessaction,"Uložit proviant do skladu v táboře.",dia_Erol_businessaction_foodgive);
Info_AddChoice(DIA_Erol_businessaction,"Sebrat magickou rudu ze skladu v táboře.",DIA_Erol_businessaction_oretake);
Info_AddChoice(DIA_Erol_businessaction,"Sebrat železnou rudu ze skladu v táboře.",DIA_Erol_businessaction_irontake);
if(CanSellOre == TRUE)
{
if(DoSellOre == FALSE)
{
Info_AddChoice(DIA_Erol_businessaction,"Začít s výrobou železných a rudných ingotů.",DIA_Erol_businessaction_produce_on);
}
else
{
Info_AddChoice(DIA_Erol_businessaction,"Zastavit výrobu železných a rudných ingotů.",DIA_Erol_businessaction_produce_off);
};
};
};
func void dia_Erol_businessaction_irontake()
{
AI_Output(other,self,"dia_Erol_businessaction_irontake_15_00"); //Chtěl bych sebrat železnou rudu ze skladu v táboře.
if(DT_BUDGET_IRON == FALSE)
{
AI_Output(self,other,"dia_Erol_businessaction_irontake_10_01"); //Bohužel na to teď nemáme dostatečné zásoby rudy.
}
else
{
AI_Output(self,other,"dia_Erol_businessaction_irontake_10_02"); //Dobře, tady je veškerá železná ruda, co máme.
B_GiveInvItems(self,other,ItMi_SNugget,DT_BUDGET_IRON);
DT_BUDGET_IRON = 0;
};
Info_ClearChoices(dia_Erol_businessaction);
Info_AddChoice(dia_Erol_businessaction,Dialog_Back,dia_Erol_businessaction_back);
Info_AddChoice(dia_Erol_businessaction,"Vybrat zlato z táborové pokladnice.",dia_Erol_businessaction_budgettake);
Info_AddChoice(dia_Erol_businessaction,"Uložit zlato do táborové pokladnice.",dia_Erol_businessaction_budgetgive);
Info_AddChoice(dia_Erol_businessaction,"Prodat proviant ze skladu v táboře.",dia_Erol_businessaction_foodsell);
Info_AddChoice(dia_Erol_businessaction,"Uložit proviant do skladu v táboře.",dia_Erol_businessaction_foodgive);
Info_AddChoice(DIA_Erol_businessaction,"Sebrat magickou rudu ze skladu v táboře.",DIA_Erol_businessaction_oretake);
Info_AddChoice(DIA_Erol_businessaction,"Sebrat železnou rudu ze skladu v táboře.",DIA_Erol_businessaction_irontake);
if(CanSellOre == TRUE)
{
if(DoSellOre == FALSE)
{
Info_AddChoice(DIA_Erol_businessaction,"Začít s výrobou železných a rudných ingotů.",DIA_Erol_businessaction_produce_on);
}
else
{
Info_AddChoice(DIA_Erol_businessaction,"Ukončit výrobu železných a rudných ingotů.",DIA_Erol_businessaction_produce_off);
};
};
};
func void dia_Erol_businessaction_produce_on()
{
DoSellOre = TRUE;
Info_ClearChoices(dia_Erol_businessaction);
Info_AddChoice(dia_Erol_businessaction,Dialog_Back,dia_Erol_businessaction_back);
Info_AddChoice(dia_Erol_businessaction,"Vybrat zlato z táborové pokladnice.",dia_Erol_businessaction_budgettake);
Info_AddChoice(dia_Erol_businessaction,"Uložit zlato do táborové pokladnice.",dia_Erol_businessaction_budgetgive);
Info_AddChoice(dia_Erol_businessaction,"Prodat proviant ze skladu v táboře.",dia_Erol_businessaction_foodsell);
Info_AddChoice(dia_Erol_businessaction,"Uložit proviant do skladu v táboře.",dia_Erol_businessaction_foodgive);
Info_AddChoice(DIA_Erol_businessaction,"Sebrat magickou rudu ze skladu v táboře.",DIA_Erol_businessaction_oretake);
Info_AddChoice(DIA_Erol_businessaction,"Sebrat železnou rudu ze skladu v táboře.",DIA_Erol_businessaction_irontake);
if(CanSellOre == TRUE)
{
if(DoSellOre == FALSE)
{
Info_AddChoice(DIA_Erol_businessaction,"Začít s výrobou železných a rudných ingotů.",DIA_Erol_businessaction_produce_on);
}
else
{
Info_AddChoice(DIA_Erol_businessaction,"Zastavit výrobu železných ingotů.",DIA_Erol_businessaction_produce_off);
};
};
};
func void dia_Erol_businessaction_produce_off()
{
DoSellOre = FALSE;
Info_ClearChoices(dia_Erol_businessaction);
Info_AddChoice(dia_Erol_businessaction,Dialog_Back,dia_Erol_businessaction_back);
Info_AddChoice(dia_Erol_businessaction,"Vybrat zlato z táborové pokladnice.",dia_Erol_businessaction_budgettake);
Info_AddChoice(dia_Erol_businessaction,"Uložit zlato do táborové pokladnice.",dia_Erol_businessaction_budgetgive);
Info_AddChoice(dia_Erol_businessaction,"Prodat proviant ze skladu v táboře.",dia_Erol_businessaction_foodsell);
Info_AddChoice(dia_Erol_businessaction,"Uložit proviant do skladu v táboře.",dia_Erol_businessaction_foodgive);
Info_AddChoice(DIA_Erol_businessaction,"Sebrat magickou rudu ze skladu v táboře.",DIA_Erol_businessaction_oretake);
Info_AddChoice(DIA_Erol_businessaction,"Sebrat železnou rudu ze skladu v táboře.",DIA_Erol_businessaction_irontake);
if(CanSellOre == TRUE)
{
if(DoSellOre == FALSE)
{
Info_AddChoice(DIA_Erol_businessaction,"Začít s výrobou železných a rudných ingotů.",DIA_Erol_businessaction_produce_on);
}
else
{
Info_AddChoice(DIA_Erol_businessaction,"Zastavit výrobu železných a rudných ingotů.",DIA_Erol_businessaction_produce_off);
};
};
};
func void dia_Erol_businessaction_back()
{
Info_ClearChoices(dia_Erol_businessaction);
};
func void dia_Erol_businessaction_budgetgive()
{
AI_Output(other,self,"DIA_Erol_BusinessAction_BudgetGive_15_00"); //Chtěl bych uložit zlato do táborové pokladnice.
AI_Output(self,other,"DIA_Erol_BusinessAction_BudgetGive_10_01"); //O jakou sumu jde?
Info_ClearChoices(dia_Erol_businessaction);
if(Npc_HasItems(other,ItMi_Gold) >= 500)
{
Info_AddChoice(dia_Erol_businessaction,"500 zlatých.",dia_Erol_businessaction_budgetgive_small);
};
if(Npc_HasItems(other,ItMi_Gold) >= 1500)
{
Info_AddChoice(dia_Erol_businessaction,"1500 zlatých.",dia_Erol_businessaction_budgetgive_medium);
};
if(Npc_HasItems(other,ItMi_Gold) >= 2500)
{
Info_AddChoice(dia_Erol_businessaction,"2500 zlatých.",dia_Erol_businessaction_budgetgive_huge);
};
Info_AddChoice(dia_Erol_businessaction,Dialog_Back,dia_Erol_businessaction_back);
};
func void dia_Erol_businessaction_budgetgive_small()
{
AI_Output(other,self,"DIA_Erol_BusinessAction_BudgetGive_Small_15_00"); //500 zlatých.
B_GiveInvItems(other,self,ItMi_Gold,500);
DT_BUDGET = DT_BUDGET + 500;
Npc_RemoveInvItems(self,ItMi_Gold,500);
Info_ClearChoices(dia_Erol_businessaction);
if(Npc_HasItems(other,ItMi_Gold) >= 500)
{
Info_AddChoice(dia_Erol_businessaction,"500 zlatých.",dia_Erol_businessaction_budgetgive_small);
};
if(Npc_HasItems(other,ItMi_Gold) >= 1500)
{
Info_AddChoice(dia_Erol_businessaction,"1500 zlatých.",dia_Erol_businessaction_budgetgive_medium);
};
if(Npc_HasItems(other,ItMi_Gold) >= 2500)
{
Info_AddChoice(dia_Erol_businessaction,"2500 zlatých.",dia_Erol_businessaction_budgetgive_huge);
};
Info_AddChoice(dia_Erol_businessaction,Dialog_Back,dia_Erol_businessaction_back);
};
func void dia_Erol_businessaction_budgetgive_medium()
{
AI_Output(other,self,"DIA_Erol_BusinessAction_BudgetGive_Medium_15_00"); //1500 zlatých.
B_GiveInvItems(other,self,ItMi_Gold,1500);
DT_BUDGET = DT_BUDGET + 1500;
Npc_RemoveInvItems(self,ItMi_Gold,1500);
Info_ClearChoices(dia_Erol_businessaction);
if(Npc_HasItems(other,ItMi_Gold) >= 500)
{
Info_AddChoice(dia_Erol_businessaction,"500 zlatých.",dia_Erol_businessaction_budgetgive_small);
};
if(Npc_HasItems(other,ItMi_Gold) >= 1500)
{
Info_AddChoice(dia_Erol_businessaction,"1500 zlatých.",dia_Erol_businessaction_budgetgive_medium);
};
if(Npc_HasItems(other,ItMi_Gold) >= 2500)
{
Info_AddChoice(dia_Erol_businessaction,"2500 zlatých.",dia_Erol_businessaction_budgetgive_huge);
};
Info_AddChoice(dia_Erol_businessaction,Dialog_Back,dia_Erol_businessaction_back);
};
func void dia_Erol_businessaction_budgetgive_huge()
{
AI_Output(other,self,"DIA_Erol_BusinessAction_BudgetGive_Huge_15_00"); //2500 zlatých.
B_GiveInvItems(other,self,ItMi_Gold,2500);
DT_BUDGET = DT_BUDGET + 2500;
Npc_RemoveInvItems(self,ItMi_Gold,2500);
Info_ClearChoices(dia_Erol_businessaction);
if(Npc_HasItems(other,ItMi_Gold) >= 500)
{
Info_AddChoice(dia_Erol_businessaction,"500 zlatých.",dia_Erol_businessaction_budgetgive_small);
};
if(Npc_HasItems(other,ItMi_Gold) >= 1500)
{
Info_AddChoice(dia_Erol_businessaction,"1500 zlatých.",dia_Erol_businessaction_budgetgive_medium);
};
if(Npc_HasItems(other,ItMi_Gold) >= 2500)
{
Info_AddChoice(dia_Erol_businessaction,"2500 zlatých.",dia_Erol_businessaction_budgetgive_huge);
};
Info_AddChoice(dia_Erol_businessaction,Dialog_Back,dia_Erol_businessaction_back);
};
func void dia_Erol_businessaction_budgettake()
{
AI_Output(other,self,"DIA_Erol_BusinessAction_BudgetTake_15_00"); //Chtěl bych vybrat zlato z táborové pokladnice.
if(DT_BUDGET <= 5000)
{
AI_Output(self,other,"DIA_Erol_BusinessAction_BudgetTake_10_01"); //Bohužel ti teď zlato dát nemohu, mám v kase jen minimum potřebné k provozu tábora.
Info_ClearChoices(dia_Erol_businessaction);
}
else
{
AI_Output(self,other,"DIA_Erol_BusinessAction_BudgetTake_10_02"); //A kolik?
Info_ClearChoices(dia_Erol_businessaction);
if(DT_BUDGET > 5000)
{
Info_AddChoice(dia_Erol_businessaction,"500 zlatých.",dia_Erol_businessaction_budgettake_small);
};
if(DT_BUDGET >= 6000)
{
Info_AddChoice(dia_Erol_businessaction,"1500 zlatých.",dia_Erol_businessaction_budgettake_medium);
};
if(DT_BUDGET >= 7000)
{
Info_AddChoice(dia_Erol_businessaction,"2500 zlatých.",dia_Erol_businessaction_budgettake_huge);
};
Info_AddChoice(dia_Erol_businessaction,Dialog_Back,dia_Erol_businessaction_back);
};
};
func void dia_Erol_businessaction_budgettake_small()
{
AI_Output(other,self,"DIA_Erol_BusinessAction_BudgetTake_Small_15_00"); //500 zlatých.
B_GiveInvItems(self,other,ItMi_Gold,500);
DT_BUDGET = DT_BUDGET - 500;
Info_ClearChoices(dia_Erol_businessaction);
if(DT_BUDGET > 5000)
{
Info_AddChoice(dia_Erol_businessaction,"500 zlatých.",dia_Erol_businessaction_budgettake_small);
};
if(DT_BUDGET >= 6000)
{
Info_AddChoice(dia_Erol_businessaction,"1500 zlatých.",dia_Erol_businessaction_budgettake_medium);
};
if(DT_BUDGET >= 7000)
{
Info_AddChoice(dia_Erol_businessaction,"2500 zlatých.",dia_Erol_businessaction_budgettake_huge);
};
Info_AddChoice(dia_Erol_businessaction,Dialog_Back,dia_Erol_businessaction_back);
};
func void dia_Erol_businessaction_budgettake_medium()
{
AI_Output(other,self,"DIA_Erol_BusinessAction_BudgetTake_Medium_15_00"); //1500 zlatých.
B_GiveInvItems(self,other,ItMi_Gold,1500);
DT_BUDGET = DT_BUDGET - 1500;
Info_ClearChoices(dia_Erol_businessaction);
if(DT_BUDGET > 5000)
{
Info_AddChoice(dia_Erol_businessaction,"500 zlatých.",dia_Erol_businessaction_budgettake_small);
};
if(DT_BUDGET >= 6000)
{
Info_AddChoice(dia_Erol_businessaction,"1500 zlatých.",dia_Erol_businessaction_budgettake_medium);
};
if(DT_BUDGET >= 7000)
{
Info_AddChoice(dia_Erol_businessaction,"2500 zlatých.",dia_Erol_businessaction_budgettake_huge);
};
Info_AddChoice(dia_Erol_businessaction,Dialog_Back,dia_Erol_businessaction_back);
};
func void dia_Erol_businessaction_budgettake_huge()
{
var string concatText1;
var string concatText2;
AI_Output(other,self,"DIA_Erol_BusinessAction_BudgetTake_Huge_15_00"); //2500 zlatých.
B_GiveInvItems(self,other,ItMi_Gold,2500);
DT_BUDGET = DT_BUDGET - 2500;
Info_ClearChoices(dia_Erol_businessaction);
if(DT_BUDGET > 5000)
{
Info_AddChoice(dia_Erol_businessaction,"500 zlatých.",dia_Erol_businessaction_budgettake_small);
};
if(DT_BUDGET >= 6000)
{
Info_AddChoice(dia_Erol_businessaction,"1500 zlatých.",dia_Erol_businessaction_budgettake_medium);
};
if(DT_BUDGET >= 7000)
{
Info_AddChoice(dia_Erol_businessaction,"2500 zlatých.",dia_Erol_businessaction_budgettake_huge);
};
Info_AddChoice(dia_Erol_businessaction,Dialog_Back,dia_Erol_businessaction_back);
};
func void dia_Erol_businessaction_foodgive()
{
AI_Output(other,self,"DIA_Erol_BusinessAction_FoodGive_15_00"); //Chtěl bych uložit proviant do skladu v táboře.
AI_Output(self,other,"DIA_Erol_BusinessAction_FoodGive_10_01"); //Jaké množství zásob máš na mysli?
Info_ClearChoices(dia_Erol_businessaction);
if(Npc_HasItems(other,ItFoMutton) >= 20)
{
Info_AddChoice(dia_Erol_businessaction,"20 kusů opečeného masa.",dia_Erol_businessaction_foodgive_hmf);
};
if(Npc_HasItems(other,ItFoMuttonRaw) >= 20)
{
Info_AddChoice(dia_Erol_businessaction,"20 kusů syrového masa.",dia_Erol_businessaction_foodgive_mf);
};
if(Npc_HasItems(other,ItFo_Fish) >= 20)
{
Info_AddChoice(dia_Erol_businessaction,"20 kusů čerstvých ryb.",dia_Erol_businessaction_foodgive_fb);
};
if(Npc_HasItems(other,ItFo_Bread) >= 10)
{
Info_AddChoice(dia_Erol_businessaction,"10 bochníků chleba.",dia_Erol_businessaction_foodgive_bsc);
};
Info_AddChoice(dia_Erol_businessaction,Dialog_Back,dia_Erol_businessaction_back);
};
func void dia_Erol_businessaction_foodgive_hmf()
{
AI_Output(other,self,"DIA_Erol_BusinessAction_FoodGive_MF_15_00"); //20 kusů opečeného masa.
B_GiveInvItems(other,self,ItFoMutton,20);
Npc_RemoveInvItems(self,ItFoMutton,20);
DT_FOODSTOCK = DT_FOODSTOCK + 20;
Info_ClearChoices(dia_Erol_businessaction);
if(Npc_HasItems(other,ItFoMutton) >= 20)
{
Info_AddChoice(dia_Erol_businessaction,"20 kusů opečeného masa.",dia_Erol_businessaction_foodgive_hmf);
};
if(Npc_HasItems(other,ItFoMuttonRaw) >= 20)
{
Info_AddChoice(dia_Erol_businessaction,"20 kusů syrového masa.",dia_Erol_businessaction_foodgive_mf);
};
if(Npc_HasItems(other,ItFo_Fish) >= 20)
{
Info_AddChoice(dia_Erol_businessaction,"20 kusů čerstvých ryb.",dia_Erol_businessaction_foodgive_fb);
};
if(Npc_HasItems(other,ItFo_Bread) >= 10)
{
Info_AddChoice(dia_Erol_businessaction,"10 bochníků chleba.",dia_Erol_businessaction_foodgive_bsc);
};
Info_AddChoice(dia_Erol_businessaction,Dialog_Back,dia_Erol_businessaction_back);
};
func void dia_Erol_businessaction_foodgive_mf()
{
AI_Output(other,self,"DIA_Erol_BusinessAction_FoodGive_MF_15_00"); //20 kusů syrového masa.
B_GiveInvItems(other,self,ItFoMuttonRaw,20);
Npc_RemoveInvItems(self,ItFoMuttonRaw,20);
DT_FOODSTOCK = DT_FOODSTOCK + 20;
Info_ClearChoices(dia_Erol_businessaction);
if(Npc_HasItems(other,ItFoMutton) >= 20)
{
Info_AddChoice(dia_Erol_businessaction,"20 kusů opečeného masa.",dia_Erol_businessaction_foodgive_hmf);
};
if(Npc_HasItems(other,ItFoMuttonRaw) >= 20)
{
Info_AddChoice(dia_Erol_businessaction,"20 kusů syrového masa.",dia_Erol_businessaction_foodgive_mf);
};
if(Npc_HasItems(other,ItFo_Fish) >= 20)
{
Info_AddChoice(dia_Erol_businessaction,"20 kusů čerstvých ryb.",dia_Erol_businessaction_foodgive_fb);
};
if(Npc_HasItems(other,ItFo_Bread) >= 10)
{
Info_AddChoice(dia_Erol_businessaction,"10 bochníků chleba.",dia_Erol_businessaction_foodgive_bsc);
};
Info_AddChoice(dia_Erol_businessaction,Dialog_Back,dia_Erol_businessaction_back);
};
func void dia_Erol_businessaction_foodgive_fb()
{
AI_Output(other,self,"DIA_Erol_BusinessAction_FoodGive_FB_15_00"); //20 kusů čerstvých ryb.
B_GiveInvItems(other,self,ItFo_Fish,20);
Npc_RemoveInvItems(self,ItFo_Fish,20);
DT_FOODSTOCK = DT_FOODSTOCK + 20;
Info_ClearChoices(dia_Erol_businessaction);
if(Npc_HasItems(other,ItFoMutton) >= 20)
{
Info_AddChoice(dia_Erol_businessaction,"20 kusů opečeného masa.",dia_Erol_businessaction_foodgive_hmf);
};
if(Npc_HasItems(other,ItFoMuttonRaw) >= 20)
{
Info_AddChoice(dia_Erol_businessaction,"20 kusů syrového masa.",dia_Erol_businessaction_foodgive_mf);
};
if(Npc_HasItems(other,ItFo_Fish) >= 20)
{
Info_AddChoice(dia_Erol_businessaction,"20 kusů čerstvých ryb.",dia_Erol_businessaction_foodgive_fb);
};
if(Npc_HasItems(other,ItFo_Bread) >= 10)
{
Info_AddChoice(dia_Erol_businessaction,"10 bochníků chleba.",dia_Erol_businessaction_foodgive_bsc);
};
Info_AddChoice(dia_Erol_businessaction,Dialog_Back,dia_Erol_businessaction_back);
};
func void dia_Erol_businessaction_foodgive_bsc()
{
AI_Output(other,self,"DIA_Erol_BusinessAction_FoodGive_BSC_15_00"); //10 bochníků chleba.
B_GiveInvItems(other,self,ItFo_Bread,10);
Npc_RemoveInvItems(self,ItFo_Bread,10);
DT_FOODSTOCK = DT_FOODSTOCK + 10;
Info_ClearChoices(dia_Erol_businessaction);
if(Npc_HasItems(other,ItFoMutton) >= 20)
{
Info_AddChoice(dia_Erol_businessaction,"20 kusů opečeného masa.",dia_Erol_businessaction_foodgive_hmf);
};
if(Npc_HasItems(other,ItFoMuttonRaw) >= 20)
{
Info_AddChoice(dia_Erol_businessaction,"20 kusů syrového masa.",dia_Erol_businessaction_foodgive_mf);
};
if(Npc_HasItems(other,ItFo_Fish) >= 20)
{
Info_AddChoice(dia_Erol_businessaction,"20 kusů čerstvých ryb.",dia_Erol_businessaction_foodgive_fb);
};
if(Npc_HasItems(other,ItFo_Bread) >= 10)
{
Info_AddChoice(dia_Erol_businessaction,"10 bochníků chleba.",dia_Erol_businessaction_foodgive_bsc);
};
Info_AddChoice(dia_Erol_businessaction,Dialog_Back,dia_Erol_businessaction_back);
};
func void dia_Erol_businessaction_foodsell()
{
AI_Output(other,self,"DIA_Erol_BusinessAction_FoodSell_15_00"); //Chtěl bych prodat proviant ze skladu v táboře.
if(DT_FOODSTOCK < 130)
{
AI_Output(self,other,"DIA_Erol_BusinessAction_FoodSell_10_01"); //Bohužel to teď není možné, mám ve skladu jen minimum potřebné k provozu tábora.
Info_ClearChoices(dia_Erol_businessaction);
}
else
{
AI_Output(self,other,"DIA_Erol_BusinessAction_FoodSell_10_02"); //To by šlo zrealizovat. Kolik jídla chceš prodat?
Info_ClearChoices(dia_Erol_businessaction);
if(DT_FOODSTOCK >= 130)
{
Info_AddChoice(dia_Erol_businessaction,"10 jednotek proviantu. (příjem do táborové pokladnice: 50 zlatých)",dia_Erol_businessaction_foodsell_small);
};
if(DT_FOODSTOCK >= 145)
{
Info_AddChoice(dia_Erol_businessaction,"25 jednotek proviantu. (příjem do táborové pokladnice: 125 zlatých)",dia_Erol_businessaction_foodsell_medium);
};
if(DT_FOODSTOCK >= 170)
{
Info_AddChoice(dia_Erol_businessaction,"50 jednotek proviantu. (příjem do táborové pokladnice: 250 zlatých)",dia_Erol_businessaction_foodsell_huge);
};
Info_AddChoice(dia_Erol_businessaction,Dialog_Back,dia_Erol_businessaction_back);
};
};
func void dia_Erol_businessaction_foodsell_small()
{
var string concatText1;
var string concatText2;
AI_Output(other,self,"DIA_Erol_BusinessAction_FoodSell_Small_15_00"); //10 jednotek proviantu.
DT_BUDGET = DT_BUDGET + 50;
DT_FOODSTOCK = DT_FOODSTOCK - 10;
Info_ClearChoices(dia_Erol_businessaction);
if(DT_FOODSTOCK >= 130)
{
Info_AddChoice(dia_Erol_businessaction,"10 jednotek proviantu. (příjem do táborové pokladnice: 50 zlatých)",dia_Erol_businessaction_foodsell_small);
};
if(DT_FOODSTOCK >= 145)
{
Info_AddChoice(dia_Erol_businessaction,"25 jednotek proviantu. (příjem do táborové pokladnice: 125 zlatých)",dia_Erol_businessaction_foodsell_medium);
};
if(DT_FOODSTOCK >= 170)
{
Info_AddChoice(dia_Erol_businessaction,"50 jednotek proviantu. (příjem do táborové pokladnice: 250 zlatých)",dia_Erol_businessaction_foodsell_huge);
};
Info_AddChoice(dia_Erol_businessaction,Dialog_Back,dia_Erol_businessaction_back);
};
func void dia_Erol_businessaction_foodsell_medium()
{
var string concatText1;
var string concatText2;
AI_Output(other,self,"DIA_Erol_BusinessAction_FoodSell_Medium_15_00"); //25 jednotek proviantu.
DT_BUDGET = DT_BUDGET + 125;
DT_FOODSTOCK = DT_FOODSTOCK - 25;
Info_ClearChoices(dia_Erol_businessaction);
if(DT_FOODSTOCK >= 130)
{
Info_AddChoice(dia_Erol_businessaction,"10 jednotek proviantu. (příjem do táborové pokladnice: 50 zlatých)",dia_Erol_businessaction_foodsell_small);
};
if(DT_FOODSTOCK >= 145)
{
Info_AddChoice(dia_Erol_businessaction,"25 jednotek proviantu. (příjem do táborové pokladnice: 125 zlatých)",dia_Erol_businessaction_foodsell_medium);
};
if(DT_FOODSTOCK >= 170)
{
Info_AddChoice(dia_Erol_businessaction,"50 jednotek proviantu. (příjem do táborové pokladnice: 250 zlatých)",dia_Erol_businessaction_foodsell_huge);
};
Info_AddChoice(dia_Erol_businessaction,Dialog_Back,dia_Erol_businessaction_back);
};
func void dia_Erol_businessaction_foodsell_huge()
{
var string concatText1;
var string concatText2;
AI_Output(other,self,"DIA_Erol_BusinessAction_FoodSell_Huge_15_00"); //50 jednotek proviantu.
DT_BUDGET = DT_BUDGET + 250;
DT_FOODSTOCK = DT_FOODSTOCK - 50;
Info_ClearChoices(dia_Erol_businessaction);
if(DT_FOODSTOCK >= 130)
{
Info_AddChoice(dia_Erol_businessaction,"10 jednotek proviantu. (příjem do táborové pokladnice: 50 zlatých)",dia_Erol_businessaction_foodsell_small);
};
if(DT_FOODSTOCK >= 145)
{
Info_AddChoice(dia_Erol_businessaction,"25 jednotek proviantu. (příjem do táborové pokladnice: 125 zlatých)",dia_Erol_businessaction_foodsell_medium);
};
if(DT_FOODSTOCK >= 170)
{
Info_AddChoice(dia_Erol_businessaction,"50 jednotek proviantu. (příjem do táborové pokladnice: 250 zlatých)",dia_Erol_businessaction_foodsell_huge);
};
Info_AddChoice(dia_Erol_businessaction,Dialog_Back,dia_Erol_businessaction_back);
};
instance DIA_Erol_MONEYCRISIS(C_Info)
{
npc = VLK_4303_Addon_Erol;
nr = 1;
condition = dia_Erol_moneycrisis_condition;
information = dia_Erol_moneycrisis_info;
permanent = TRUE;
important = TRUE;
};
func int dia_Erol_moneycrisis_condition()
{
if((DTMONEYCRISIS == TRUE) && (DTFOODCRISIS == FALSE) && (ErolRECRUITEDDT == TRUE))
{
return TRUE;
};
};
func void dia_Erol_moneycrisis_info()
{
var string concatText1;
DTMONEYDEBT = 5000 - DT_BUDGET;
AI_Output(self,other,"DIA_Erol_MoneyCrisis_07_00"); //Ještě něco! V táboře nejsou peníze, nemám lidem jak vyplácet mzdu!
AI_Output(self,other,"DIA_Erol_MoneyCrisis_07_01"); //Jen tak-tak se mi je podařilo přemluvit, aby neodešli.
AI_Output(self,other,"DIA_Erol_MoneyCrisis_07_02"); //Nutně potřebujeme zlato!
AI_Output(other,self,"DIA_Erol_MoneyCrisis_15_03"); //Kolik?
concatText1 = ConcatStrings("Potřeba ",IntToString(DTMONEYDEBT));
concatText1 = ConcatStrings(concatText1," zlatých");
AI_Print(concatText1);
Info_ClearChoices(dia_Erol_moneycrisis);
if(Npc_HasItems(other,ItMi_Gold) >= DTMONEYDEBT)
{
Info_AddChoice(dia_Erol_moneycrisis,"Tady jsou peníze.",dia_Erol_moneycrisis_yes);
};
Info_AddChoice(dia_Erol_moneycrisis,"Nemám teď tolik zlata.",dia_Erol_moneycrisis_no);
};
func void dia_Erol_moneycrisis_yes()
{
AI_Output(other,self,"DIA_Erol_MoneyCrisis_Yes_15_00"); //Tady jsou peníze.
AI_Output(self,other,"DIA_Erol_MoneyCrisis_Yes_07_01"); //Výborně, hned dám příkaz na vyplacení dluhů.
B_GiveInvItems(other,self,ItMi_Gold,DTMONEYDEBT);
DT_BUDGET = DT_BUDGET + DTMONEYDEBT;
Npc_RemoveInvItems(self,ItMi_Gold,DTMONEYDEBT);
DTMONEYCRISIS = FALSE;
AI_StopProcessInfos(self);
};
func void dia_Erol_moneycrisis_no()
{
AI_Output(other,self,"DIA_Erol_MoneyCrisis_No_15_00"); //Nemám teď tolik zlata.
AI_Output(self,other,"DIA_Erol_MoneyCrisis_No_07_01"); //Musíš ho sehnat! Nemůžeš být tak nezodpovědný.
AI_StopProcessInfos(self);
};
instance DIA_Erol_FOODCRISIS(C_Info)
{
npc = VLK_4303_Addon_Erol;
nr = 1;
condition = dia_Erol_foodcrisis_condition;
information = dia_Erol_foodcrisis_info;
permanent = TRUE;
important = TRUE;
};
func int dia_Erol_foodcrisis_condition()
{
if((DTFOODCRISIS == TRUE) && (ErolRECRUITEDDT == TRUE))
{
return TRUE;
};
};
func void dia_Erol_foodcrisis_info()
{
AI_Output(self,other,"DIA_Erol_FoodCrisis_07_00"); //Ještě něco! V táboře došel proviant, nemáme nic k jídlu!
AI_Output(self,other,"DIA_Erol_FoodCrisis_07_01"); //Zatím jsem se domluvil s Onarem na dodávkách, ale čeká ho důležitá zakázka a jakmile ji bude muset zrealizovat, tak nám už nebude moci pomoct.
AI_Output(self,other,"DIA_Erol_FoodCrisis_07_02"); //Nutně potřebujeme jídlo! Především maso, ryby a chléb...
Info_ClearChoices(dia_Erol_foodcrisis);
if(Npc_HasItems(other,ItFoMutton) >= 20)
{
Info_AddChoice(dia_Erol_foodcrisis,"Tady máš 20 kusů opečeného masa.",dia_Erol_foodcrisis_m);
};
if(Npc_HasItems(other,ItFoMuttonRaw) >= 20)
{
Info_AddChoice(dia_Erol_foodcrisis,"Tady máš 20 kusů syrového masa.",dia_Erol_foodcrisis_rm);
};
if(Npc_HasItems(other,ItFo_Fish) >= 20)
{
Info_AddChoice(dia_Erol_foodcrisis,"Tady máš 20 kusů čerstvých ryb.",dia_Erol_foodcrisis_f);
};
if(Npc_HasItems(other,ItFo_Bread) >= 10)
{
Info_AddChoice(dia_Erol_foodcrisis,"Tady máš 10 bochníků chleba.",dia_Erol_foodcrisis_b);
};
Info_AddChoice(dia_Erol_foodcrisis,"Nemám u sebe tolik jídla.",dia_Erol_foodcrisis_no);
};
func void dia_Erol_foodcrisis_m()
{
AI_Output(other,self,"DIA_Erol_FoodCrisis_M_15_00"); //Tady máš 20 kusů opečeného masa.
B_GiveInvItems(other,self,ItFoMutton,20);
Npc_RemoveInvItems(self,ItFoMutton,20);
DT_FOODSTOCK = DT_FOODSTOCK + 20;
if(DT_FOODSTOCK >= 120)
{
AI_Output(self,other,"DIA_Erol_FoodCrisis_M_07_01"); //Výborně, to jsme potřebovali.
DTFOODCRISIS = FALSE;
DTFOODDEBT = 0;
Info_ClearChoices(dia_Erol_foodcrisis);
}
else
{
AI_Output(self,other,"DIA_Erol_FoodCrisis_M_07_02"); //Ještě, potřebujeme víc jídla.
if(Npc_HasItems(other,ItFoMutton) >= 20)
{
Info_AddChoice(dia_Erol_foodcrisis,"Tady máš 20 kusů opečeného masa.",dia_Erol_foodcrisis_m);
};
};
};
func void dia_Erol_foodcrisis_rm()
{
AI_Output(other,self,"DIA_Erol_FoodCrisis_RM_15_00"); //Tady máš 20 kusů syrového masa.
B_GiveInvItems(other,self,ItFoMuttonRaw,20);
Npc_RemoveInvItems(self,ItFoMuttonRaw,20);
DT_FOODSTOCK = DT_FOODSTOCK + 20;
if(DT_FOODSTOCK >= 120)
{
AI_Output(self,other,"DIA_Erol_FoodCrisis_RM_07_01"); //Výborně, to jsme potřebovali.
DTFOODCRISIS = FALSE;
DTFOODDEBT = 0;
Info_ClearChoices(dia_Erol_foodcrisis);
}
else
{
AI_Output(self,other,"DIA_Erol_FoodCrisis_RM_M_07_02"); //Ještě, potřebujeme víc jídla.
if(Npc_HasItems(other,ItFoMuttonRaw) >= 20)
{
Info_AddChoice(dia_Erol_foodcrisis,"Tady máš 20 kusů syrového masa.",dia_Erol_foodcrisis_rm);
};
};
};
func void dia_Erol_foodcrisis_f()
{
AI_Output(other,self,"DIA_Erol_FoodCrisis_F_15_00"); //Tady máš 20 kusů čerstvých ryb.
B_GiveInvItems(other,self,ItFo_Fish,20);
Npc_RemoveInvItems(self,ItFo_Fish,20);
DT_FOODSTOCK = DT_FOODSTOCK + 20;
if(DT_FOODSTOCK >= 120)
{
AI_Output(self,other,"DIA_Erol_FoodCrisis_F_07_01"); //Výborně, to jsme potřebovali.
DTFOODCRISIS = FALSE;
DTFOODDEBT = 0;
Info_ClearChoices(dia_Erol_foodcrisis);
}
else
{
AI_Output(self,other,"DIA_Erol_FoodCrisis_F_07_02"); //Ještě, potřebujeme víc jídla.
if(Npc_HasItems(other,ItFo_Fish) >= 20)
{
Info_AddChoice(dia_Erol_foodcrisis,"Tady máš 20 kusů čerstvých ryb.",dia_Erol_foodcrisis_f);
};
};
};
func void dia_Erol_foodcrisis_b()
{
AI_Output(other,self,"DIA_Erol_FoodCrisis_B_15_00"); //Tady máš 10 bochníků chleba.
B_GiveInvItems(other,self,ItFo_Bread,10);
Npc_RemoveInvItems(self,ItFo_Bread,10);
DT_FOODSTOCK = DT_FOODSTOCK + 10;
if(DT_FOODSTOCK >= 120)
{
AI_Output(self,other,"DIA_Erol_FoodCrisis_B_07_01"); //Výborně, to jsme potřebovali.
DTFOODCRISIS = FALSE;
DTFOODDEBT = 0;
Info_ClearChoices(dia_Erol_foodcrisis);
}
else
{
AI_Output(self,other,"DIA_Erol_FoodCrisis_B_07_02"); //Ještě, potřebujeme víc jídla.
if(Npc_HasItems(other,ItFo_Bread) >= 10)
{
Info_AddChoice(dia_Erol_foodcrisis,"Tady máš 10 bochníků chleba.",dia_Erol_foodcrisis_b);
};
};
};
func void dia_Erol_foodcrisis_no()
{
AI_Output(other,self,"DIA_Erol_FoodCrisis_No_15_00"); //Nemám u sebe tolik jídla. Sám žiju z ruky do huby.
AI_Output(self,other,"DIA_Erol_FoodCrisis_No_07_01"); //Ó, Innosi! Nemůžeš být tak nezodpovědný! Potřebujeme jídlo!
AI_StopProcessInfos(self);
};
instance DIA_EROL_IGETTHEFOUTOFHERE(C_Info)
{
npc = VLK_4303_Addon_Erol;
nr = 15;
condition = dia_erol_igetthefoutofhere_condition;
information = dia_erol_igetthefoutofhere_info;
permanent = FALSE;
description = "Chystám se odplout na pevninu.";
};
func int dia_erol_igetthefoutofhere_condition()
{
if((WHOTRAVELONBIGLAND == TRUE) && (EROLRECRUITEDDT == TRUE))
{
return TRUE;
};
};
func void dia_erol_igetthefoutofhere_info()
{
AI_Output(other,self,"DIA_Erol_IGetTheFOutOfHere_15_00"); //Chystám se odplout na pevninu. Můžeš dohlédnout na tvrz?
AI_Output(self,other,"DIA_Erol_IGetTheFOutOfHere_10_01"); //To jsou nám noviny... chceš odplout navždy, nebo se máš v úmyslu vrátit?
AI_Output(other,self,"DIA_Erol_IGetTheFOutOfHere_15_02"); //Bojím se, že už se do Khorinisu nevrátím. Jestli máš zájem starat se i nadále o tvrz, tak ti jí přenechám.
AI_Output(self,other,"DIA_Erol_IGetTheFOutOfHere_10_03"); //Á... dobře, když to říkáš. Díky tvému úsilí jsme se zde dobře zabydleli, tak myslím, že mohu i nadále vést úspěšně tento tábor.
AI_Output(self,other,"DIA_Erol_IGetTheFOutOfHere_10_04"); //Teď když se toje tvrz a Onarova farma, staly hlavním pilířem obrany proti skřetům. Můžeme upevnit vztahy s ostatnímy tábory, ve společném úsilí boje proti těmto tvorům.
AI_Output(self,other,"DIA_Erol_IGetTheFOutOfHere_10_05"); //Tak si myslím, že můžeš bez obav odplout.
AI_Output(self,other,"DIA_Erol_IGetTheFOutOfHere_10_06"); //Udělal jsi pro nás všechno co jsi mohl a teď je řada na nás abychom se snažili. Šťastnou cestu!
AI_Output(other,self,"DIA_Erol_IGetTheFOutOfHere_15_07"); //Děkuji!
AI_StopProcessInfos(self);
};
instance DIA_EROL_INTOWER(C_Info)
{
npc = VLK_4303_Addon_Erol;
nr = 22;
condition = dia_erol_intower_condition;
information = dia_erol_intower_info;
permanent = TRUE;
description = "Jak to vypadá v tvrzi?";
};
func int dia_erol_intower_condition()
{
if((EROLRECRUITEDDT == TRUE) && (KAPITELORCATC == FALSE) && (DTMONEYCRISIS == FALSE) && (DTFOODCRISIS == FALSE) && (CEONEEDSFIRSTMONEY == FALSE) && (CEONEEDSFIRSTFOOD == FALSE) && (Npc_GetDistToWP(self,"NW_CASTLEMINE_TOWER_CAMPFIRE_01") < 12000))
{
return TRUE;
};
};
func void dia_erol_intower_info()
{
AI_Output(other,self,"DIA_Erol_InTower_15_00"); //Jak to vypadá v tvrzi?
AI_Output(self,other,"DIA_Erol_InTower_07_01"); //Dobře! Jestli budem mít dost jídla a peněz, nemusíš se strachovat.
};
instance DIA_EROL_INTOWER_ORCKAP(C_Info)
{
npc = VLK_4303_Addon_Erol;
nr = 22;
condition = dia_erol_intower_orckap_condition;
information = dia_erol_intower_orckap_info;
permanent = TRUE;
description = "Jak to jde v táboře?";
};
func int dia_erol_intower_orckap_condition()
{
if((EROLRECRUITEDDT == TRUE) && (KAPITELORCATC == TRUE))
{
return TRUE;
};
};
func void dia_erol_intower_orckap_info()
{
AI_Output(other,self,"DIA_Erol_InTower_OrcKap_15_00"); //Jak to jde v táboře?
AI_Output(self,other,"DIA_Erol_InTower_OrcKap_07_01"); //Peněz i jídla máme dost, ale z těch skřetů mám strach...
};
| D |
/*
* Hunt - A data validation for DLang based on hunt library.
*
* Copyright (C) 2015-2019, HuntLabs
*
* Website: https://www.huntlabs.net
*
* Licensed under the Apache-2.0 License.
*
*/
module hunt.validation.constraints.NotBlank;
struct NotBlank
{
string message="may not be empty";
}
| D |
/**
* Oracle import library.
*
* Part of the D DBI project.
*
* Version:
* Oracle 10g revision 2
*
* Import library version 0.04
*
* Authors: The D DBI project
*
* Copyright: BSD license
*/
module dbi.oracle.imp.xa;
const uint XIDDATASIZE = 128; /// Size in bytes.
const uint MAXGTRIDSIZE = 64; /// Maximum size in bytes of gtrid.
const uint MAXBQUALSIZE = 64; /// Maximum size in bytes of bqual.
/**
* Transaction branch identification: XID and NULLXID:
*
* A value of -1 in formatID means that the XID is null.
*/
struct xid_t {
int formatID; /// Format identifier.
int gtrid_length; /// Value from 1 through 64.
int bqual_length; /// Value from 1 through 64.
char[XIDDATASIZE] data; /// Transaction data.
}
alias xid_t XID;
/**
* Declarations of routines by which RMs call TMs:
*/
extern (C) int ax_reg (int, XID*, int);
/**
* ditto
*/
extern (C) int ax_unreg (int, int);
const uint RMNAMESZ = 32; /// Length of resource manager name, including the null terminator.
const uint MAXINFOSIZE = 256; /// Maximum size in bytes of xa_info strings, including the null terminator.
/*
* XA Switch Data Structure.
*/
struct xa_switch_t {
char[RMNAMESZ] name; /// Name of resource manager.
int flags; /// Resource manager specific options.
int xaversion; /// Must be 0.
extern (C) int function(char*, int, int) xa_open_entry; ///
extern (C) int function(char*, int, int) xa_close_entry; ///
extern (C) int function(XID*, int, int) xa_start_entry; ///
extern (C) int function(XID*, int, int) xa_end_entry; ///
extern (C) int function(XID*, int, int) xa_rollback_entry; ///
extern (C) int function(XID*, int, int) xa_prepare_entry; ///
extern (C) int function(XID*, int, int) xa_commit_entry; ///
extern (C) int function(XID*, int, int, int) xa_recover_entry; ///
extern (C) int function(XID*, int, int) xa_forget_entry; ///
extern (C) int function(int*, int*, int, int) xa_complete_entry; ///
}
const ulong TMNOFLAGS = 0x00000000; /// No resource manager features selected.
const ulong TMREGISTER = 0x00000001; /// Resource manager dynamically registers.
const ulong TMNOMIGRATE = 0x00000002; /// Resource manager does not support association migration.
const ulong TMUSEASYNC = 0x00000004; /// Resource manager supports asynchronous operations.
const ulong TMASYNC = 0x80000000; /// Perform routine asynchronously.
const ulong TMONEPHASE = 0x40000000; /// Caller is using one-phase commit optimization.
const ulong TMFAIL = 0x20000000; /// Dissociates caller and marks transaction branch rollback-only.
const ulong TMNOWAIT = 0x10000000; /// Return if blocking condition exists.
const ulong TMRESUME = 0x08000000; /// Caller is resuming association with suspended transaction branch.
const ulong TMSUCCESS = 0x04000000; /// Dissociate caller from transaction branch.
const ulong TMSUSPEND = 0x02000000; /// Caller is suspending, not ending, association.
const ulong TMSTARTRSCAN = 0x01000000; /// Start a recovery scan.
const ulong TMENDRSCAN = 0x00800000; /// End a recovery scan.
const ulong TMMULTIPLE = 0x00400000; /// Wait for any asynchronous operation.
const ulong TMJOIN = 0x00200000; /// Caller is joining existing transaction branch.
const ulong TMMIGRATE = 0x00100000; /// Caller intends to perform migration.
const ulong TM_JOIN = 2; /// Caller is joining existing transaction branch .
const ulong TM_RESUME = 1; /// Caller is resuming association with suspended transaction branch.
const ulong TM_OK = 0; /// Normal execution.
const long TMER_TMERR = -1; /// An error occurred in the transaction manager.
const long TMER_INVAL = -2; /// Invalid arguments were given.
const long TMER_PROTO = -3; /// Routine invoked in an improper context.
const ulong XA_RBBASE = 100; /// The inclusive lower bound of the rollback codes.
const ulong XA_RBROLLBACK = XA_RBBASE; /// The rollback was caused by an unspecified reason.
const ulong XA_RBCOMMFAIL = XA_RBBASE + 1;/// The rollback was caused by a communication failure.
const ulong XA_RBDEADLOCK = XA_RBBASE + 2;/// A deadlock was detected.
const ulong XA_RBINTEGRITY = XA_RBBASE + 3;/// A condition that violates the integrity of the resources was detected.
const ulong XA_RBOTHER = XA_RBBASE + 4;/// The resource manager rolled back the transaction for a reason not on this list.
const ulong XA_RBPROTO = XA_RBBASE + 5;/// A protocal error occurred in the resource manager.
const ulong XA_RBTIMEOUT = XA_RBBASE + 6;/// A transaction branch took too long.
const ulong XA_RBTRANSIENT = XA_RBBASE + 7;/// May retry the transaction branch.
const ulong XA_RBEND = XA_RBTRANSIENT; /// The inclusive upper bound of the rollback codes.
const ulong XA_NOMIGRATE = 9; /// Resumption must occur where suspension occurred.
const ulong XA_HEURHAZ = 8; /// The transaction branch may have been heuristically completed.
const ulong XA_HEURCOM = 7; /// The transaction branch has been heuristically comitted.
const ulong XA_HEURRB = 6; /// The transaction branch has been heuristically rolled back.
const ulong XA_HEURMIX = 5; /// The transaction branch has been heuristically committed and rolled back.
const ulong XA_RETRY = 4; /// Routine returned with no effect and may be re-issued.
const ulong XA_RDONLY = 3; /// The transaction was read-only and has been committed.
const ulong XA_OK = 0; /// Normal execution.
const long XAER_ASYNC = -2; /// Asynchronous operation already outstanding.
const long XAER_RMERR = -3; /// A resource manager error occurred in the transaction branch.
const long XAER_NOTA = -4; /// The XID is not valid.
const long XAER_INVAL = -5; /// Invalid arguments were given.
const long XAER_PROTO = -6; /// Routine invoked in an improper context.
const long XAER_RMFAIL = -7; /// Resource manager unavailable.
const long XAER_DUPID = -8; /// The XID already exists.
const long XAER_OUTSIDE = -9; /// Resource manager doing work outside global transaction. | D |
module hunt.http.codec.websocket.model.UpgradeRequest;
import hunt.http.codec.websocket.model.ExtensionConfig;
import hunt.http.codec.http.model.Cookie;
import hunt.http.codec.http.model.HttpURI;
// dfmt off
version(WITH_HUNT_SECURITY) {
import hunt.security.Principal;
}
// dfmt on
import hunt.collection;
/**
* The HTTP Upgrade to WebSocket Request
*/
interface UpgradeRequest {
/**
* Add WebSocket Extension Configuration(s) to Upgrade Request.
* <p>
* This is merely the list of requested Extensions to use, see {@link UpgradeResponse#getExtensions()} for what was
* negotiated
*
* @param configs the configuration(s) to add
*/
void addExtensions(ExtensionConfig[] configs ...);
/**
* Add WebSocket Extension Configuration(s) to request
* <p>
* This is merely the list of requested Extensions to use, see {@link UpgradeResponse#getExtensions()} for what was
* negotiated
*
* @param configs the configuration(s) to add
*/
void addExtensions(string[] configs...);
/**
* Get the list of Cookies on the Upgrade request
*
* @return the list of Cookies
*/
List!(Cookie) getCookies();
/**
* Get the list of WebSocket Extension Configurations for this Upgrade Request.
* <p>
* This is merely the list of requested Extensions to use, see {@link UpgradeResponse#getExtensions()} for what was
* negotiated
*
* @return the list of Extension configurations (in the order they were specified)
*/
List!(ExtensionConfig) getExtensions();
/**
* Get a specific Header value from Upgrade Request
*
* @param name the name of the header
* @return the value of the header (null if header does not exist)
*/
string getHeader(string name);
/**
* Get the specific Header value, as an <code>int</code>, from the Upgrade Request.
*
* @param name the name of the header
* @return the value of the header as an <code>int</code> (-1 if header does not exist)
* @throws NumberFormatException if unable to parse value as an int.
*/
int getHeaderInt(string name);
/**
* Get the headers as a Map of keys to value lists.
*
* @return the headers
*/
Map!(string, List!(string)) getHeaders();
/**
* Get the specific header values (for multi-value headers)
*
* @param name the header name
* @return the value list (null if no header exists)
*/
List!(string) getHeaders(string name);
/**
* The host of the Upgrade Request URI
*
* @return host of the request URI
*/
string getHost();
/**
* The HTTP version used for this Upgrade Request
* <p>
* As of <a href="http://tools.ietf.org/html/rfc6455">RFC6455 (December 2011)</a> this is always
* <code>HTTP/1.1</code>
*
* @return the HTTP Version used
*/
string getHttpVersion();
/**
* The HTTP method for this Upgrade Request.
* <p>
* As of <a href="http://tools.ietf.org/html/rfc6455">RFC6455 (December 2011)</a> this is always <code>GET</code>
*
* @return the HTTP method used
*/
string getMethod();
/**
* The WebSocket Origin of this Upgrade Request
* <p>
* See <a href="http://tools.ietf.org/html/rfc6455#section-10.2">RFC6455: Section 10.2</a> for details.
* <p>
* Equivalent to {@link #getHeader(string)} passed the "Origin" header.
*
* @return the Origin header
*/
string getOrigin();
/**
* Returns a map of the query parameters of the request.
*
* @return a unmodifiable map of query parameters of the request.
*/
Map!(string, List!(string)) getParameterMap();
/**
* Get the WebSocket Protocol Version
* <p>
* As of <a href="http://tools.ietf.org/html/rfc6455#section-11.6">RFC6455</a>, Hunt only supports version
* <code>13</code>
*
* @return the WebSocket protocol version
*/
string getProtocolVersion();
/**
* Get the Query string of the request URI.
*
* @return the request uri query string
*/
string getQueryString();
/**
* Get the Request URI
*
* @return the request URI
*/
HttpURI getRequestURI();
/**
* Access the Servlet HTTP Session (if present)
* <p>
* Note: Never present on a Client UpgradeRequest.
*
* @return the Servlet HttpSession on server side UpgradeRequests
*/
Object getSession();
/**
* Get the list of offered WebSocket sub-protocols.
*
* @return the list of offered sub-protocols
*/
List!(string) getSubProtocols();
/**
* Get the User Principal for this request.
* <p>
* Only applicable when using UpgradeRequest from server side.
*
* @return the user principal
*/
version(WITH_HUNT_SECURITY) Principal getUserPrincipal();
/**
* Test if a specific sub-protocol is offered
*
* @param test the sub-protocol to test for
* @return true if sub-protocol exists on request
*/
bool hasSubProtocol(string test);
/**
* Test if supplied Origin is the same as the Request
*
* @param test the supplied origin
* @return true if the supplied origin matches the request origin
*/
bool isOrigin(string test);
/**
* Test if connection is secure.
*
* @return true if connection is secure.
*/
bool isSecure();
/**
* Set the list of Cookies on the request
*
* @param cookies the cookies to use
*/
void setCookies(List!(Cookie) cookies);
/**
* Set the list of WebSocket Extension configurations on the request.
*
* @param configs the list of extension configurations
*/
void setExtensions(List!(ExtensionConfig) configs);
/**
* Set a specific header with multi-value field
* <p>
* Overrides any previous value for this named header
*
* @param name the name of the header
* @param values the multi-value field
*/
void setHeader(string name, List!(string) values);
/**
* Set a specific header value
* <p>
* Overrides any previous value for this named header
*
* @param name the header to set
* @param value the value to set it to
*/
void setHeader(string name, string value);
/**
* Sets multiple headers on the request.
* <p>
* Only sets those headers provided, does not remove
* headers that exist on request and are not provided in the
* parameter for this method.
* <p>
* Convenience method vs calling {@link #setHeader(string, List)} multiple times.
*
* @param headers the headers to set
*/
void setHeaders(Map!(string, List!(string)) headers);
/**
* Set the HTTP Version to use.
* <p>
* As of <a href="http://tools.ietf.org/html/rfc6455">RFC6455 (December 2011)</a> this should always be
* <code>HTTP/1.1</code>
*
* @param httpVersion the HTTP version to use.
*/
void setHttpVersion(string httpVersion);
/**
* Set the HTTP method to use.
* <p>
* As of <a href="http://tools.ietf.org/html/rfc6455">RFC6455 (December 2011)</a> this is always <code>GET</code>
*
* @param method the HTTP method to use.
*/
void setMethod(string method);
/**
* Set the Request URI to use for this request.
* <p>
* Must be an absolute URI with scheme <code>'ws'</code> or <code>'wss'</code>
*
* @param uri the Request URI
*/
void setRequestURI(HttpURI uri);
/**
* Set the Session associated with this request.
* <p>
* Typically used to associate the Servlet HttpSession object.
*
* @param session the session object to associate with this request
*/
void setSession(Object session);
/**
* Set the offered WebSocket Sub-Protocol list.
*
* @param protocols the offered sub-protocol list
*/
void setSubProtocols(List!(string) protocols);
/**
* Set the offered WebSocket Sub-Protocol list.
*
* @param protocols the offered sub-protocol list
*/
void setSubProtocols(string[] protocols...);
}
| D |
/Users/davidsullivan/Desktop/Programing/Rust/renderer/renderer/target/debug/renderer-a3b1b18757392d80.dSYM: /Users/davidsullivan/Desktop/Programing/Rust/renderer/renderer/src/lib.rs /Users/davidsullivan/Desktop/Programing/Rust/renderer/renderer/src/main.rs
| D |
/*******************************************************************************
* Copyright (c) 2000, 2008 IBM Corporation and others.
* All rights reserved. This program and the accompanying materials
* are made available under the terms of the Eclipse Public License v1.0
* which accompanies this distribution, and is available at
* http://www.eclipse.org/legal/epl-v10.html
*
* Contributors:
* IBM Corporation - initial API and implementation
* Port to the D programming language:
* Frank Benoit <benoit@tionex.de>
*******************************************************************************/
module org.eclipse.swt.graphics.Point;
import java.lang.all;
public import org.eclipse.swt.internal.SerializableCompatibility;
/**
* Instances of this class represent places on the (x, y)
* coordinate plane.
* <p>
* The coordinate space for rectangles and points is considered
* to have increasing values downward and to the right from its
* origin making this the normal, computer graphics oriented notion
* of (x, y) coordinates rather than the strict mathematical one.
* </p>
* <p>
* The hashCode() method in this class uses the values of the public
* fields to compute the hash value. When storing instances of the
* class in hashed collections, do not modify these fields after the
* object has been inserted.
* </p>
* <p>
* Application code does <em>not</em> need to explicitly release the
* resources managed by each instance when those instances are no longer
* required, and thus no <code>dispose()</code> method is provided.
* </p>
*
* @see Rectangle
* @see <a href="http://www.eclipse.org/swt/">Sample code and further information</a>
*/
public final class Point : SerializableCompatibility {
/**
* the x coordinate of the point
*/
public int x;
/**
* the y coordinate of the point
*/
public int y;
//static final long serialVersionUID = 3257002163938146354L;
/**
* Constructs a new point with the given x and y coordinates.
*
* @param x the x coordinate of the new point
* @param y the y coordinate of the new point
*/
public this (int x, int y) {
this.x = x;
this.y = y;
}
/**
* Compares the argument to the receiver, and returns true
* if they represent the <em>same</em> object using a class
* specific comparison.
*
* @param object the object to compare with this object
* @return <code>true</code> if the object is the same as this object and <code>false</code> otherwise
*
* @see #hashCode()
*/
public override equals_t opEquals (Object object) {
if (object is this) return true;
if ( auto p = cast(Point)object ){
return (p.x is this.x) && (p.y is this.y);
}
return false;
}
/**
* Returns an integer hash code for the receiver. Any two
* objects that return <code>true</code> when passed to
* <code>equals</code> must return the same value for this
* method.
*
* @return the receiver's hash
*
* @see #equals(Object)
*/
override public hash_t toHash () {
return x ^ y;
}
/**
* Returns a string containing a concise, human-readable
* description of the receiver.
*
* @return a string representation of the point
*/
override public String toString () {
return Format( "Point {{{}, {}}", x, y ); //$NON-NLS-1$ //$NON-NLS-2$ //$NON-NLS-3$
}
}
| D |
//рычаг от пещеры на острове воров
//высегда выкл., воры внутри
func int CanUse_Thief_Isle()
{
if (Npc_IsPlayer(self)) {
PrintScreen("Не двигается.",-1,20,FONT_ScreenSmall,2);
};
return FALSE;
}; | D |
module org.serviio.restlet.RestletConstants;
public class RestletConstants
{
public static final int API_PORT = 23423;
public static final int CDS_PORT = 23424;
}
/* Location: C:\Users\Main\Downloads\serviio.jar
* Qualified Name: org.serviio.restlet.RestletConstants
* JD-Core Version: 0.7.0.1
*/ | D |
/Users/Jorge/Desktop/Projects/Web/Swift/kisiBootcamp/.build/x86_64-apple-macosx/debug/GoogleCloud.build/Storage/API/ObjectACLAPI.swift.o : /Users/Jorge/Desktop/Projects/Web/Swift/kisiBootcamp/.build/checkouts/google-cloud-provider/Sources/GoogleCloud/Storage/API/ObjectACLAPI.swift /Users/Jorge/Desktop/Projects/Web/Swift/kisiBootcamp/.build/checkouts/google-cloud-provider/Sources/GoogleCloud/Storage/API/DefaultObjectACLAPI.swift /Users/Jorge/Desktop/Projects/Web/Swift/kisiBootcamp/.build/checkouts/google-cloud-provider/Sources/GoogleCloud/Storage/API/BucketAccessControlAPI.swift /Users/Jorge/Desktop/Projects/Web/Swift/kisiBootcamp/.build/checkouts/google-cloud-provider/Sources/GoogleCloud/Storage/API/ChannelsAPI.swift /Users/Jorge/Desktop/Projects/Web/Swift/kisiBootcamp/.build/checkouts/google-cloud-provider/Sources/GoogleCloud/Storage/API/StorageNotificationsAPI.swift /Users/Jorge/Desktop/Projects/Web/Swift/kisiBootcamp/.build/checkouts/google-cloud-provider/Sources/GoogleCloud/Storage/API/StorageObjectAPI.swift /Users/Jorge/Desktop/Projects/Web/Swift/kisiBootcamp/.build/checkouts/google-cloud-provider/Sources/GoogleCloud/Storage/API/StorageBucketAPI.swift /Users/Jorge/Desktop/Projects/Web/Swift/kisiBootcamp/.build/checkouts/google-cloud-provider/Sources/GoogleCloud/Common/OAuth/OAuthPayload.swift /Users/Jorge/Desktop/Projects/Web/Swift/kisiBootcamp/.build/checkouts/google-cloud-provider/Sources/GoogleCloud/Common/OAuth/OAuthRefreshable.swift /Users/Jorge/Desktop/Projects/Web/Swift/kisiBootcamp/.build/checkouts/google-cloud-provider/Sources/GoogleCloud/Storage/Models/Enums/StorageScope.swift /Users/Jorge/Desktop/Projects/Web/Swift/kisiBootcamp/.build/checkouts/google-cloud-provider/Sources/GoogleCloud/Common/GoogleCloudAPIConfig.swift /Users/Jorge/Desktop/Projects/Web/Swift/kisiBootcamp/.build/checkouts/google-cloud-provider/Sources/GoogleCloud/Storage/StorageConfig.swift /Users/Jorge/Desktop/Projects/Web/Swift/kisiBootcamp/.build/checkouts/google-cloud-provider/Sources/GoogleCloud/Common/OAuth/OAuthAccessToken.swift /Users/Jorge/Desktop/Projects/Web/Swift/kisiBootcamp/.build/checkouts/google-cloud-provider/Sources/GoogleCloud/Common/OAuth/OAuthCredentialLoader.swift /Users/Jorge/Desktop/Projects/Web/Swift/kisiBootcamp/.build/checkouts/google-cloud-provider/Sources/GoogleCloud/Provider.swift /Users/Jorge/Desktop/Projects/Web/Swift/kisiBootcamp/.build/checkouts/google-cloud-provider/Sources/GoogleCloud/Common/GoogleCloudError.swift /Users/Jorge/Desktop/Projects/Web/Swift/kisiBootcamp/.build/checkouts/google-cloud-provider/Sources/GoogleCloud/Storage/CloudStorageError.swift /Users/Jorge/Desktop/Projects/Web/Swift/kisiBootcamp/.build/checkouts/google-cloud-provider/Sources/GoogleCloud/Extensions.swift /Users/Jorge/Desktop/Projects/Web/Swift/kisiBootcamp/.build/checkouts/google-cloud-provider/Sources/GoogleCloud/Common/Credentials/Loaders.swift /Users/Jorge/Desktop/Projects/Web/Swift/kisiBootcamp/.build/checkouts/google-cloud-provider/Sources/GoogleCloud/Storage/Models/Enums/StorageClass.swift /Users/Jorge/Desktop/Projects/Web/Swift/kisiBootcamp/.build/checkouts/google-cloud-provider/Sources/GoogleCloud/Storage/Models/StorageObject.swift /Users/Jorge/Desktop/Projects/Web/Swift/kisiBootcamp/.build/checkouts/google-cloud-provider/Sources/GoogleCloud/Storage/Models/StorageBucket.swift /Users/Jorge/Desktop/Projects/Web/Swift/kisiBootcamp/.build/checkouts/google-cloud-provider/Sources/GoogleCloud/Common/Credentials/ApplicationDefault.swift /Users/Jorge/Desktop/Projects/Web/Swift/kisiBootcamp/.build/checkouts/google-cloud-provider/Sources/GoogleCloud/Common/OAuth/OAuthApplicationDefault.swift /Users/Jorge/Desktop/Projects/Web/Swift/kisiBootcamp/.build/checkouts/google-cloud-provider/Sources/GoogleCloud/Storage/StorageClient.swift /Users/Jorge/Desktop/Projects/Web/Swift/kisiBootcamp/.build/checkouts/google-cloud-provider/Sources/GoogleCloud/Common/Credentials/ServiceAccount.swift /Users/Jorge/Desktop/Projects/Web/Swift/kisiBootcamp/.build/checkouts/google-cloud-provider/Sources/GoogleCloud/Common/OAuth/OAuthServiceAccount.swift /Users/Jorge/Desktop/Projects/Web/Swift/kisiBootcamp/.build/checkouts/google-cloud-provider/Sources/GoogleCloud/Storage/StorageRequest.swift /Users/Jorge/Desktop/Projects/Web/Swift/kisiBootcamp/.build/checkouts/google-cloud-provider/Sources/GoogleCloud/Storage/Models/StorageBucketList.swift /Users/Jorge/Desktop/Projects/Web/Swift/kisiBootcamp/.build/checkouts/google-cloud-provider/Sources/GoogleCloud/Common/OAuth/OAuthComputeEngine+AppEngineFlex.swift /Users/Jorge/Desktop/Projects/Web/Swift/kisiBootcamp/.build/checkouts/google-cloud-provider/Sources/GoogleCloud/Storage/Models/IAMPolicy.swift /Users/Jorge/Desktop/Projects/Web/Swift/kisiBootcamp/.build/x86_64-apple-macosx/debug/NIOHTTP1.swiftmodule /Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/lib/swift/macosx/x86_64/ObjectiveC.swiftmodule /Users/Jorge/Desktop/Projects/Web/Swift/kisiBootcamp/.build/x86_64-apple-macosx/debug/NIOOpenSSL.swiftmodule /Users/Jorge/Desktop/Projects/Web/Swift/kisiBootcamp/.build/x86_64-apple-macosx/debug/NIO.swiftmodule /Users/Jorge/Desktop/Projects/Web/Swift/kisiBootcamp/.build/x86_64-apple-macosx/debug/HTTP.swiftmodule /Users/Jorge/Desktop/Projects/Web/Swift/kisiBootcamp/.build/x86_64-apple-macosx/debug/NIOTLS.swiftmodule /Users/Jorge/Desktop/Projects/Web/Swift/kisiBootcamp/.build/x86_64-apple-macosx/debug/JWT.swiftmodule /Users/Jorge/Desktop/Projects/Web/Swift/kisiBootcamp/.build/x86_64-apple-macosx/debug/Async.swiftmodule /Users/Jorge/Desktop/Projects/Web/Swift/kisiBootcamp/.build/x86_64-apple-macosx/debug/Command.swiftmodule /Users/Jorge/Desktop/Projects/Web/Swift/kisiBootcamp/.build/x86_64-apple-macosx/debug/Service.swiftmodule /Users/Jorge/Desktop/Projects/Web/Swift/kisiBootcamp/.build/x86_64-apple-macosx/debug/Console.swiftmodule /Users/Jorge/Desktop/Projects/Web/Swift/kisiBootcamp/.build/x86_64-apple-macosx/debug/Core.swiftmodule /Users/Jorge/Desktop/Projects/Web/Swift/kisiBootcamp/.build/x86_64-apple-macosx/debug/Logging.swiftmodule /Users/Jorge/Desktop/Projects/Web/Swift/kisiBootcamp/.build/x86_64-apple-macosx/debug/Debugging.swiftmodule /Users/Jorge/Desktop/Projects/Web/Swift/kisiBootcamp/.build/x86_64-apple-macosx/debug/Routing.swiftmodule /Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/lib/swift/macosx/x86_64/Dispatch.swiftmodule /Users/Jorge/Desktop/Projects/Web/Swift/kisiBootcamp/.build/x86_64-apple-macosx/debug/COperatingSystem.swiftmodule /Users/Jorge/Desktop/Projects/Web/Swift/kisiBootcamp/.build/x86_64-apple-macosx/debug/Random.swiftmodule /Users/Jorge/Desktop/Projects/Web/Swift/kisiBootcamp/.build/x86_64-apple-macosx/debug/URLEncodedForm.swiftmodule /Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/lib/swift/macosx/x86_64/Darwin.swiftmodule /Users/Jorge/Desktop/Projects/Web/Swift/kisiBootcamp/.build/x86_64-apple-macosx/debug/Validation.swiftmodule /Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/lib/swift/macosx/x86_64/Foundation.swiftmodule /Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/lib/swift/macosx/x86_64/CoreFoundation.swiftmodule /Users/Jorge/Desktop/Projects/Web/Swift/kisiBootcamp/.build/x86_64-apple-macosx/debug/Crypto.swiftmodule /Users/Jorge/Desktop/Projects/Web/Swift/kisiBootcamp/.build/x86_64-apple-macosx/debug/Vapor.swiftmodule /Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/lib/swift/macosx/x86_64/CoreGraphics.swiftmodule /Users/Jorge/Desktop/Projects/Web/Swift/kisiBootcamp/.build/x86_64-apple-macosx/debug/NIOConcurrencyHelpers.swiftmodule /Users/Jorge/Desktop/Projects/Web/Swift/kisiBootcamp/.build/x86_64-apple-macosx/debug/Bits.swiftmodule /Users/Jorge/Desktop/Projects/Web/Swift/kisiBootcamp/.build/x86_64-apple-macosx/debug/NIOFoundationCompat.swiftmodule /Users/Jorge/Desktop/Projects/Web/Swift/kisiBootcamp/.build/x86_64-apple-macosx/debug/WebSocket.swiftmodule /Users/Jorge/Desktop/Projects/Web/Swift/kisiBootcamp/.build/x86_64-apple-macosx/debug/NIOWebSocket.swiftmodule /Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/lib/swift/macosx/x86_64/Swift.swiftmodule /Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/lib/swift/macosx/x86_64/IOKit.swiftmodule /Users/Jorge/Desktop/Projects/Web/Swift/kisiBootcamp/.build/x86_64-apple-macosx/debug/DatabaseKit.swiftmodule /Users/Jorge/Desktop/Projects/Web/Swift/kisiBootcamp/.build/x86_64-apple-macosx/debug/TemplateKit.swiftmodule /Users/Jorge/Desktop/Projects/Web/Swift/kisiBootcamp/.build/x86_64-apple-macosx/debug/Multipart.swiftmodule /Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/lib/swift/macosx/x86_64/SwiftOnoneSupport.swiftmodule /Users/Jorge/Desktop/Projects/Web/Swift/kisiBootcamp/.build/checkouts/swift-nio/Sources/CNIOSHA1/include/CNIOSHA1.h /usr/local/Cellar/libressl/2.9.2/include/openssl/asn1.h /usr/local/Cellar/libressl/2.9.2/include/openssl/tls1.h /usr/local/Cellar/libressl/2.9.2/include/openssl/dtls1.h /usr/local/Cellar/libressl/2.9.2/include/openssl/pkcs12.h /usr/local/Cellar/libressl/2.9.2/include/openssl/ssl2.h /usr/local/Cellar/libressl/2.9.2/include/openssl/pem2.h /usr/local/Cellar/libressl/2.9.2/include/openssl/ssl23.h /usr/local/Cellar/libressl/2.9.2/include/openssl/ssl3.h /usr/local/Cellar/libressl/2.9.2/include/openssl/x509v3.h /usr/local/Cellar/libressl/2.9.2/include/openssl/md5.h /usr/local/Cellar/libressl/2.9.2/include/openssl/pkcs7.h /usr/local/Cellar/libressl/2.9.2/include/openssl/x509.h /usr/local/Cellar/libressl/2.9.2/include/openssl/sha.h /usr/local/Cellar/libressl/2.9.2/include/openssl/dsa.h /usr/local/Cellar/libressl/2.9.2/include/openssl/ecdsa.h /usr/local/Cellar/libressl/2.9.2/include/openssl/rsa.h /Users/Jorge/Desktop/Projects/Web/Swift/kisiBootcamp/.build/checkouts/swift-nio/Sources/CNIOZlib/include/CNIOZlib.h /usr/local/Cellar/libressl/2.9.2/include/openssl/obj_mac.h /usr/local/Cellar/libressl/2.9.2/include/openssl/hmac.h /usr/local/Cellar/libressl/2.9.2/include/openssl/ec.h /Users/Jorge/Desktop/Projects/Web/Swift/kisiBootcamp/.build/checkouts/swift-nio/Sources/CNIOAtomics/include/cpp_magic.h /Users/Jorge/Desktop/Projects/Web/Swift/kisiBootcamp/.build/checkouts/swift-nio/Sources/CNIOLinux/include/ifaddrs-android.h /usr/local/Cellar/libressl/2.9.2/include/openssl/rand.h /usr/local/Cellar/libressl/2.9.2/include/openssl/conf.h /usr/local/Cellar/libressl/2.9.2/include/openssl/opensslconf.h /usr/local/Cellar/libressl/2.9.2/include/openssl/dh.h /usr/local/Cellar/libressl/2.9.2/include/openssl/ecdh.h /usr/local/Cellar/libressl/2.9.2/include/openssl/lhash.h /usr/local/Cellar/libressl/2.9.2/include/openssl/stack.h /usr/local/Cellar/libressl/2.9.2/include/openssl/safestack.h /usr/local/Cellar/libressl/2.9.2/include/openssl/ssl.h /Users/Jorge/Desktop/Projects/Web/Swift/kisiBootcamp/.build/checkouts/swift-nio-ssl/Sources/CNIOOpenSSL/include/c_nio_openssl.h /Users/Jorge/Desktop/Projects/Web/Swift/kisiBootcamp/.build/checkouts/crypto/Sources/CCryptoOpenSSL/include/c_crypto_openssl.h /usr/local/Cellar/libressl/2.9.2/include/openssl/pem.h /usr/local/Cellar/libressl/2.9.2/include/openssl/bn.h /Users/Jorge/Desktop/Projects/Web/Swift/kisiBootcamp/.build/checkouts/swift-nio/Sources/CNIODarwin/include/CNIODarwin.h /usr/local/Cellar/libressl/2.9.2/include/openssl/bio.h /usr/local/Cellar/libressl/2.9.2/include/openssl/crypto.h /usr/local/Cellar/libressl/2.9.2/include/openssl/srtp.h /usr/local/Cellar/libressl/2.9.2/include/openssl/evp.h /usr/local/Cellar/libressl/2.9.2/include/openssl/ossl_typ.h /usr/local/Cellar/libressl/2.9.2/include/openssl/buffer.h /Users/Jorge/Desktop/Projects/Web/Swift/kisiBootcamp/.build/checkouts/swift-nio/Sources/CNIOHTTPParser/include/CNIOHTTPParser.h /Users/Jorge/Desktop/Projects/Web/Swift/kisiBootcamp/.build/checkouts/swift-nio/Sources/CNIOHTTPParser/include/c_nio_http_parser.h /usr/local/Cellar/libressl/2.9.2/include/openssl/err.h /Users/Jorge/Desktop/Projects/Web/Swift/kisiBootcamp/.build/checkouts/swift-nio/Sources/CNIOAtomics/include/CNIOAtomics.h /usr/local/Cellar/libressl/2.9.2/include/openssl/opensslfeatures.h /usr/local/Cellar/libressl/2.9.2/include/openssl/objects.h /usr/local/Cellar/libressl/2.9.2/include/openssl/opensslv.h /Users/Jorge/Desktop/Projects/Web/Swift/kisiBootcamp/.build/checkouts/swift-nio/Sources/CNIOLinux/include/CNIOLinux.h /usr/local/Cellar/libressl/2.9.2/include/openssl/x509_vfy.h /Users/Jorge/Desktop/Projects/Web/Swift/kisiBootcamp/.build/x86_64-apple-macosx/debug/CNIOSHA1.build/module.modulemap /Users/Jorge/Desktop/Projects/Web/Swift/kisiBootcamp/.build/x86_64-apple-macosx/debug/CNIOOpenSSL.build/module.modulemap /Users/Jorge/Desktop/Projects/Web/Swift/kisiBootcamp/.build/x86_64-apple-macosx/debug/CCryptoOpenSSL.build/module.modulemap /Users/Jorge/Desktop/Projects/Web/Swift/kisiBootcamp/.build/x86_64-apple-macosx/debug/CNIOZlib.build/module.modulemap /Users/Jorge/Desktop/Projects/Web/Swift/kisiBootcamp/.build/x86_64-apple-macosx/debug/CNIODarwin.build/module.modulemap /Users/Jorge/Desktop/Projects/Web/Swift/kisiBootcamp/.build/x86_64-apple-macosx/debug/CNIOHTTPParser.build/module.modulemap /Users/Jorge/Desktop/Projects/Web/Swift/kisiBootcamp/.build/x86_64-apple-macosx/debug/CNIOAtomics.build/module.modulemap /Users/Jorge/Desktop/Projects/Web/Swift/kisiBootcamp/.build/x86_64-apple-macosx/debug/CNIOLinux.build/module.modulemap /Users/Jorge/Desktop/Projects/Web/Swift/kisiBootcamp/.build/checkouts/crypto/Sources/CBase32/include/module.modulemap /Users/Jorge/Desktop/Projects/Web/Swift/kisiBootcamp/.build/checkouts/crypto/Sources/CBcrypt/include/module.modulemap /Users/Jorge/Desktop/Projects/Web/Swift/kisiBootcamp/.build/checkouts/swift-nio-zlib-support/module.modulemap /Users/Jorge/Desktop/Projects/Web/Swift/kisiBootcamp/.build/checkouts/swift-nio-ssl-support/module.modulemap /Applications/Xcode.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX10.14.sdk/usr/include/objc/ObjectiveC.apinotes /Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/lib/swift/macosx/x86_64/Dispatch.apinotes /Applications/Xcode.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX10.14.sdk/usr/include/Darwin.apinotes /Applications/Xcode.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX10.14.sdk/System/Library/Frameworks/Foundation.framework/Headers/Foundation.apinotes /Applications/Xcode.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX10.14.sdk/System/Library/Frameworks/CoreGraphics.framework/Headers/CoreGraphics.apinotes /Applications/Xcode.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX10.14.sdk/System/Library/Frameworks/ApplicationServices.framework/Headers/ApplicationServices.apinotes /Applications/Xcode.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX10.14.sdk/System/Library/Frameworks/CoreText.framework/Headers/CoreText.apinotes /Applications/Xcode.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX10.14.sdk/System/Library/Frameworks/Security.framework/Headers/Security.apinotes
/Users/Jorge/Desktop/Projects/Web/Swift/kisiBootcamp/.build/x86_64-apple-macosx/debug/GoogleCloud.build/Storage/API/ObjectACLAPI~partial.swiftmodule : /Users/Jorge/Desktop/Projects/Web/Swift/kisiBootcamp/.build/checkouts/google-cloud-provider/Sources/GoogleCloud/Storage/API/ObjectACLAPI.swift /Users/Jorge/Desktop/Projects/Web/Swift/kisiBootcamp/.build/checkouts/google-cloud-provider/Sources/GoogleCloud/Storage/API/DefaultObjectACLAPI.swift /Users/Jorge/Desktop/Projects/Web/Swift/kisiBootcamp/.build/checkouts/google-cloud-provider/Sources/GoogleCloud/Storage/API/BucketAccessControlAPI.swift /Users/Jorge/Desktop/Projects/Web/Swift/kisiBootcamp/.build/checkouts/google-cloud-provider/Sources/GoogleCloud/Storage/API/ChannelsAPI.swift /Users/Jorge/Desktop/Projects/Web/Swift/kisiBootcamp/.build/checkouts/google-cloud-provider/Sources/GoogleCloud/Storage/API/StorageNotificationsAPI.swift /Users/Jorge/Desktop/Projects/Web/Swift/kisiBootcamp/.build/checkouts/google-cloud-provider/Sources/GoogleCloud/Storage/API/StorageObjectAPI.swift /Users/Jorge/Desktop/Projects/Web/Swift/kisiBootcamp/.build/checkouts/google-cloud-provider/Sources/GoogleCloud/Storage/API/StorageBucketAPI.swift /Users/Jorge/Desktop/Projects/Web/Swift/kisiBootcamp/.build/checkouts/google-cloud-provider/Sources/GoogleCloud/Common/OAuth/OAuthPayload.swift /Users/Jorge/Desktop/Projects/Web/Swift/kisiBootcamp/.build/checkouts/google-cloud-provider/Sources/GoogleCloud/Common/OAuth/OAuthRefreshable.swift /Users/Jorge/Desktop/Projects/Web/Swift/kisiBootcamp/.build/checkouts/google-cloud-provider/Sources/GoogleCloud/Storage/Models/Enums/StorageScope.swift /Users/Jorge/Desktop/Projects/Web/Swift/kisiBootcamp/.build/checkouts/google-cloud-provider/Sources/GoogleCloud/Common/GoogleCloudAPIConfig.swift /Users/Jorge/Desktop/Projects/Web/Swift/kisiBootcamp/.build/checkouts/google-cloud-provider/Sources/GoogleCloud/Storage/StorageConfig.swift /Users/Jorge/Desktop/Projects/Web/Swift/kisiBootcamp/.build/checkouts/google-cloud-provider/Sources/GoogleCloud/Common/OAuth/OAuthAccessToken.swift /Users/Jorge/Desktop/Projects/Web/Swift/kisiBootcamp/.build/checkouts/google-cloud-provider/Sources/GoogleCloud/Common/OAuth/OAuthCredentialLoader.swift /Users/Jorge/Desktop/Projects/Web/Swift/kisiBootcamp/.build/checkouts/google-cloud-provider/Sources/GoogleCloud/Provider.swift /Users/Jorge/Desktop/Projects/Web/Swift/kisiBootcamp/.build/checkouts/google-cloud-provider/Sources/GoogleCloud/Common/GoogleCloudError.swift /Users/Jorge/Desktop/Projects/Web/Swift/kisiBootcamp/.build/checkouts/google-cloud-provider/Sources/GoogleCloud/Storage/CloudStorageError.swift /Users/Jorge/Desktop/Projects/Web/Swift/kisiBootcamp/.build/checkouts/google-cloud-provider/Sources/GoogleCloud/Extensions.swift /Users/Jorge/Desktop/Projects/Web/Swift/kisiBootcamp/.build/checkouts/google-cloud-provider/Sources/GoogleCloud/Common/Credentials/Loaders.swift /Users/Jorge/Desktop/Projects/Web/Swift/kisiBootcamp/.build/checkouts/google-cloud-provider/Sources/GoogleCloud/Storage/Models/Enums/StorageClass.swift /Users/Jorge/Desktop/Projects/Web/Swift/kisiBootcamp/.build/checkouts/google-cloud-provider/Sources/GoogleCloud/Storage/Models/StorageObject.swift /Users/Jorge/Desktop/Projects/Web/Swift/kisiBootcamp/.build/checkouts/google-cloud-provider/Sources/GoogleCloud/Storage/Models/StorageBucket.swift /Users/Jorge/Desktop/Projects/Web/Swift/kisiBootcamp/.build/checkouts/google-cloud-provider/Sources/GoogleCloud/Common/Credentials/ApplicationDefault.swift /Users/Jorge/Desktop/Projects/Web/Swift/kisiBootcamp/.build/checkouts/google-cloud-provider/Sources/GoogleCloud/Common/OAuth/OAuthApplicationDefault.swift /Users/Jorge/Desktop/Projects/Web/Swift/kisiBootcamp/.build/checkouts/google-cloud-provider/Sources/GoogleCloud/Storage/StorageClient.swift /Users/Jorge/Desktop/Projects/Web/Swift/kisiBootcamp/.build/checkouts/google-cloud-provider/Sources/GoogleCloud/Common/Credentials/ServiceAccount.swift /Users/Jorge/Desktop/Projects/Web/Swift/kisiBootcamp/.build/checkouts/google-cloud-provider/Sources/GoogleCloud/Common/OAuth/OAuthServiceAccount.swift /Users/Jorge/Desktop/Projects/Web/Swift/kisiBootcamp/.build/checkouts/google-cloud-provider/Sources/GoogleCloud/Storage/StorageRequest.swift /Users/Jorge/Desktop/Projects/Web/Swift/kisiBootcamp/.build/checkouts/google-cloud-provider/Sources/GoogleCloud/Storage/Models/StorageBucketList.swift /Users/Jorge/Desktop/Projects/Web/Swift/kisiBootcamp/.build/checkouts/google-cloud-provider/Sources/GoogleCloud/Common/OAuth/OAuthComputeEngine+AppEngineFlex.swift /Users/Jorge/Desktop/Projects/Web/Swift/kisiBootcamp/.build/checkouts/google-cloud-provider/Sources/GoogleCloud/Storage/Models/IAMPolicy.swift /Users/Jorge/Desktop/Projects/Web/Swift/kisiBootcamp/.build/x86_64-apple-macosx/debug/NIOHTTP1.swiftmodule /Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/lib/swift/macosx/x86_64/ObjectiveC.swiftmodule /Users/Jorge/Desktop/Projects/Web/Swift/kisiBootcamp/.build/x86_64-apple-macosx/debug/NIOOpenSSL.swiftmodule /Users/Jorge/Desktop/Projects/Web/Swift/kisiBootcamp/.build/x86_64-apple-macosx/debug/NIO.swiftmodule /Users/Jorge/Desktop/Projects/Web/Swift/kisiBootcamp/.build/x86_64-apple-macosx/debug/HTTP.swiftmodule /Users/Jorge/Desktop/Projects/Web/Swift/kisiBootcamp/.build/x86_64-apple-macosx/debug/NIOTLS.swiftmodule /Users/Jorge/Desktop/Projects/Web/Swift/kisiBootcamp/.build/x86_64-apple-macosx/debug/JWT.swiftmodule /Users/Jorge/Desktop/Projects/Web/Swift/kisiBootcamp/.build/x86_64-apple-macosx/debug/Async.swiftmodule /Users/Jorge/Desktop/Projects/Web/Swift/kisiBootcamp/.build/x86_64-apple-macosx/debug/Command.swiftmodule /Users/Jorge/Desktop/Projects/Web/Swift/kisiBootcamp/.build/x86_64-apple-macosx/debug/Service.swiftmodule /Users/Jorge/Desktop/Projects/Web/Swift/kisiBootcamp/.build/x86_64-apple-macosx/debug/Console.swiftmodule /Users/Jorge/Desktop/Projects/Web/Swift/kisiBootcamp/.build/x86_64-apple-macosx/debug/Core.swiftmodule /Users/Jorge/Desktop/Projects/Web/Swift/kisiBootcamp/.build/x86_64-apple-macosx/debug/Logging.swiftmodule /Users/Jorge/Desktop/Projects/Web/Swift/kisiBootcamp/.build/x86_64-apple-macosx/debug/Debugging.swiftmodule /Users/Jorge/Desktop/Projects/Web/Swift/kisiBootcamp/.build/x86_64-apple-macosx/debug/Routing.swiftmodule /Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/lib/swift/macosx/x86_64/Dispatch.swiftmodule /Users/Jorge/Desktop/Projects/Web/Swift/kisiBootcamp/.build/x86_64-apple-macosx/debug/COperatingSystem.swiftmodule /Users/Jorge/Desktop/Projects/Web/Swift/kisiBootcamp/.build/x86_64-apple-macosx/debug/Random.swiftmodule /Users/Jorge/Desktop/Projects/Web/Swift/kisiBootcamp/.build/x86_64-apple-macosx/debug/URLEncodedForm.swiftmodule /Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/lib/swift/macosx/x86_64/Darwin.swiftmodule /Users/Jorge/Desktop/Projects/Web/Swift/kisiBootcamp/.build/x86_64-apple-macosx/debug/Validation.swiftmodule /Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/lib/swift/macosx/x86_64/Foundation.swiftmodule /Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/lib/swift/macosx/x86_64/CoreFoundation.swiftmodule /Users/Jorge/Desktop/Projects/Web/Swift/kisiBootcamp/.build/x86_64-apple-macosx/debug/Crypto.swiftmodule /Users/Jorge/Desktop/Projects/Web/Swift/kisiBootcamp/.build/x86_64-apple-macosx/debug/Vapor.swiftmodule /Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/lib/swift/macosx/x86_64/CoreGraphics.swiftmodule /Users/Jorge/Desktop/Projects/Web/Swift/kisiBootcamp/.build/x86_64-apple-macosx/debug/NIOConcurrencyHelpers.swiftmodule /Users/Jorge/Desktop/Projects/Web/Swift/kisiBootcamp/.build/x86_64-apple-macosx/debug/Bits.swiftmodule /Users/Jorge/Desktop/Projects/Web/Swift/kisiBootcamp/.build/x86_64-apple-macosx/debug/NIOFoundationCompat.swiftmodule /Users/Jorge/Desktop/Projects/Web/Swift/kisiBootcamp/.build/x86_64-apple-macosx/debug/WebSocket.swiftmodule /Users/Jorge/Desktop/Projects/Web/Swift/kisiBootcamp/.build/x86_64-apple-macosx/debug/NIOWebSocket.swiftmodule /Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/lib/swift/macosx/x86_64/Swift.swiftmodule /Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/lib/swift/macosx/x86_64/IOKit.swiftmodule /Users/Jorge/Desktop/Projects/Web/Swift/kisiBootcamp/.build/x86_64-apple-macosx/debug/DatabaseKit.swiftmodule /Users/Jorge/Desktop/Projects/Web/Swift/kisiBootcamp/.build/x86_64-apple-macosx/debug/TemplateKit.swiftmodule /Users/Jorge/Desktop/Projects/Web/Swift/kisiBootcamp/.build/x86_64-apple-macosx/debug/Multipart.swiftmodule /Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/lib/swift/macosx/x86_64/SwiftOnoneSupport.swiftmodule /Users/Jorge/Desktop/Projects/Web/Swift/kisiBootcamp/.build/checkouts/swift-nio/Sources/CNIOSHA1/include/CNIOSHA1.h /usr/local/Cellar/libressl/2.9.2/include/openssl/asn1.h /usr/local/Cellar/libressl/2.9.2/include/openssl/tls1.h /usr/local/Cellar/libressl/2.9.2/include/openssl/dtls1.h /usr/local/Cellar/libressl/2.9.2/include/openssl/pkcs12.h /usr/local/Cellar/libressl/2.9.2/include/openssl/ssl2.h /usr/local/Cellar/libressl/2.9.2/include/openssl/pem2.h /usr/local/Cellar/libressl/2.9.2/include/openssl/ssl23.h /usr/local/Cellar/libressl/2.9.2/include/openssl/ssl3.h /usr/local/Cellar/libressl/2.9.2/include/openssl/x509v3.h /usr/local/Cellar/libressl/2.9.2/include/openssl/md5.h /usr/local/Cellar/libressl/2.9.2/include/openssl/pkcs7.h /usr/local/Cellar/libressl/2.9.2/include/openssl/x509.h /usr/local/Cellar/libressl/2.9.2/include/openssl/sha.h /usr/local/Cellar/libressl/2.9.2/include/openssl/dsa.h /usr/local/Cellar/libressl/2.9.2/include/openssl/ecdsa.h /usr/local/Cellar/libressl/2.9.2/include/openssl/rsa.h /Users/Jorge/Desktop/Projects/Web/Swift/kisiBootcamp/.build/checkouts/swift-nio/Sources/CNIOZlib/include/CNIOZlib.h /usr/local/Cellar/libressl/2.9.2/include/openssl/obj_mac.h /usr/local/Cellar/libressl/2.9.2/include/openssl/hmac.h /usr/local/Cellar/libressl/2.9.2/include/openssl/ec.h /Users/Jorge/Desktop/Projects/Web/Swift/kisiBootcamp/.build/checkouts/swift-nio/Sources/CNIOAtomics/include/cpp_magic.h /Users/Jorge/Desktop/Projects/Web/Swift/kisiBootcamp/.build/checkouts/swift-nio/Sources/CNIOLinux/include/ifaddrs-android.h /usr/local/Cellar/libressl/2.9.2/include/openssl/rand.h /usr/local/Cellar/libressl/2.9.2/include/openssl/conf.h /usr/local/Cellar/libressl/2.9.2/include/openssl/opensslconf.h /usr/local/Cellar/libressl/2.9.2/include/openssl/dh.h /usr/local/Cellar/libressl/2.9.2/include/openssl/ecdh.h /usr/local/Cellar/libressl/2.9.2/include/openssl/lhash.h /usr/local/Cellar/libressl/2.9.2/include/openssl/stack.h /usr/local/Cellar/libressl/2.9.2/include/openssl/safestack.h /usr/local/Cellar/libressl/2.9.2/include/openssl/ssl.h /Users/Jorge/Desktop/Projects/Web/Swift/kisiBootcamp/.build/checkouts/swift-nio-ssl/Sources/CNIOOpenSSL/include/c_nio_openssl.h /Users/Jorge/Desktop/Projects/Web/Swift/kisiBootcamp/.build/checkouts/crypto/Sources/CCryptoOpenSSL/include/c_crypto_openssl.h /usr/local/Cellar/libressl/2.9.2/include/openssl/pem.h /usr/local/Cellar/libressl/2.9.2/include/openssl/bn.h /Users/Jorge/Desktop/Projects/Web/Swift/kisiBootcamp/.build/checkouts/swift-nio/Sources/CNIODarwin/include/CNIODarwin.h /usr/local/Cellar/libressl/2.9.2/include/openssl/bio.h /usr/local/Cellar/libressl/2.9.2/include/openssl/crypto.h /usr/local/Cellar/libressl/2.9.2/include/openssl/srtp.h /usr/local/Cellar/libressl/2.9.2/include/openssl/evp.h /usr/local/Cellar/libressl/2.9.2/include/openssl/ossl_typ.h /usr/local/Cellar/libressl/2.9.2/include/openssl/buffer.h /Users/Jorge/Desktop/Projects/Web/Swift/kisiBootcamp/.build/checkouts/swift-nio/Sources/CNIOHTTPParser/include/CNIOHTTPParser.h /Users/Jorge/Desktop/Projects/Web/Swift/kisiBootcamp/.build/checkouts/swift-nio/Sources/CNIOHTTPParser/include/c_nio_http_parser.h /usr/local/Cellar/libressl/2.9.2/include/openssl/err.h /Users/Jorge/Desktop/Projects/Web/Swift/kisiBootcamp/.build/checkouts/swift-nio/Sources/CNIOAtomics/include/CNIOAtomics.h /usr/local/Cellar/libressl/2.9.2/include/openssl/opensslfeatures.h /usr/local/Cellar/libressl/2.9.2/include/openssl/objects.h /usr/local/Cellar/libressl/2.9.2/include/openssl/opensslv.h /Users/Jorge/Desktop/Projects/Web/Swift/kisiBootcamp/.build/checkouts/swift-nio/Sources/CNIOLinux/include/CNIOLinux.h /usr/local/Cellar/libressl/2.9.2/include/openssl/x509_vfy.h /Users/Jorge/Desktop/Projects/Web/Swift/kisiBootcamp/.build/x86_64-apple-macosx/debug/CNIOSHA1.build/module.modulemap /Users/Jorge/Desktop/Projects/Web/Swift/kisiBootcamp/.build/x86_64-apple-macosx/debug/CNIOOpenSSL.build/module.modulemap /Users/Jorge/Desktop/Projects/Web/Swift/kisiBootcamp/.build/x86_64-apple-macosx/debug/CCryptoOpenSSL.build/module.modulemap /Users/Jorge/Desktop/Projects/Web/Swift/kisiBootcamp/.build/x86_64-apple-macosx/debug/CNIOZlib.build/module.modulemap /Users/Jorge/Desktop/Projects/Web/Swift/kisiBootcamp/.build/x86_64-apple-macosx/debug/CNIODarwin.build/module.modulemap /Users/Jorge/Desktop/Projects/Web/Swift/kisiBootcamp/.build/x86_64-apple-macosx/debug/CNIOHTTPParser.build/module.modulemap /Users/Jorge/Desktop/Projects/Web/Swift/kisiBootcamp/.build/x86_64-apple-macosx/debug/CNIOAtomics.build/module.modulemap /Users/Jorge/Desktop/Projects/Web/Swift/kisiBootcamp/.build/x86_64-apple-macosx/debug/CNIOLinux.build/module.modulemap /Users/Jorge/Desktop/Projects/Web/Swift/kisiBootcamp/.build/checkouts/crypto/Sources/CBase32/include/module.modulemap /Users/Jorge/Desktop/Projects/Web/Swift/kisiBootcamp/.build/checkouts/crypto/Sources/CBcrypt/include/module.modulemap /Users/Jorge/Desktop/Projects/Web/Swift/kisiBootcamp/.build/checkouts/swift-nio-zlib-support/module.modulemap /Users/Jorge/Desktop/Projects/Web/Swift/kisiBootcamp/.build/checkouts/swift-nio-ssl-support/module.modulemap /Applications/Xcode.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX10.14.sdk/usr/include/objc/ObjectiveC.apinotes /Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/lib/swift/macosx/x86_64/Dispatch.apinotes /Applications/Xcode.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX10.14.sdk/usr/include/Darwin.apinotes /Applications/Xcode.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX10.14.sdk/System/Library/Frameworks/Foundation.framework/Headers/Foundation.apinotes /Applications/Xcode.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX10.14.sdk/System/Library/Frameworks/CoreGraphics.framework/Headers/CoreGraphics.apinotes /Applications/Xcode.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX10.14.sdk/System/Library/Frameworks/ApplicationServices.framework/Headers/ApplicationServices.apinotes /Applications/Xcode.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX10.14.sdk/System/Library/Frameworks/CoreText.framework/Headers/CoreText.apinotes /Applications/Xcode.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX10.14.sdk/System/Library/Frameworks/Security.framework/Headers/Security.apinotes
/Users/Jorge/Desktop/Projects/Web/Swift/kisiBootcamp/.build/x86_64-apple-macosx/debug/GoogleCloud.build/Storage/API/ObjectACLAPI~partial.swiftdoc : /Users/Jorge/Desktop/Projects/Web/Swift/kisiBootcamp/.build/checkouts/google-cloud-provider/Sources/GoogleCloud/Storage/API/ObjectACLAPI.swift /Users/Jorge/Desktop/Projects/Web/Swift/kisiBootcamp/.build/checkouts/google-cloud-provider/Sources/GoogleCloud/Storage/API/DefaultObjectACLAPI.swift /Users/Jorge/Desktop/Projects/Web/Swift/kisiBootcamp/.build/checkouts/google-cloud-provider/Sources/GoogleCloud/Storage/API/BucketAccessControlAPI.swift /Users/Jorge/Desktop/Projects/Web/Swift/kisiBootcamp/.build/checkouts/google-cloud-provider/Sources/GoogleCloud/Storage/API/ChannelsAPI.swift /Users/Jorge/Desktop/Projects/Web/Swift/kisiBootcamp/.build/checkouts/google-cloud-provider/Sources/GoogleCloud/Storage/API/StorageNotificationsAPI.swift /Users/Jorge/Desktop/Projects/Web/Swift/kisiBootcamp/.build/checkouts/google-cloud-provider/Sources/GoogleCloud/Storage/API/StorageObjectAPI.swift /Users/Jorge/Desktop/Projects/Web/Swift/kisiBootcamp/.build/checkouts/google-cloud-provider/Sources/GoogleCloud/Storage/API/StorageBucketAPI.swift /Users/Jorge/Desktop/Projects/Web/Swift/kisiBootcamp/.build/checkouts/google-cloud-provider/Sources/GoogleCloud/Common/OAuth/OAuthPayload.swift /Users/Jorge/Desktop/Projects/Web/Swift/kisiBootcamp/.build/checkouts/google-cloud-provider/Sources/GoogleCloud/Common/OAuth/OAuthRefreshable.swift /Users/Jorge/Desktop/Projects/Web/Swift/kisiBootcamp/.build/checkouts/google-cloud-provider/Sources/GoogleCloud/Storage/Models/Enums/StorageScope.swift /Users/Jorge/Desktop/Projects/Web/Swift/kisiBootcamp/.build/checkouts/google-cloud-provider/Sources/GoogleCloud/Common/GoogleCloudAPIConfig.swift /Users/Jorge/Desktop/Projects/Web/Swift/kisiBootcamp/.build/checkouts/google-cloud-provider/Sources/GoogleCloud/Storage/StorageConfig.swift /Users/Jorge/Desktop/Projects/Web/Swift/kisiBootcamp/.build/checkouts/google-cloud-provider/Sources/GoogleCloud/Common/OAuth/OAuthAccessToken.swift /Users/Jorge/Desktop/Projects/Web/Swift/kisiBootcamp/.build/checkouts/google-cloud-provider/Sources/GoogleCloud/Common/OAuth/OAuthCredentialLoader.swift /Users/Jorge/Desktop/Projects/Web/Swift/kisiBootcamp/.build/checkouts/google-cloud-provider/Sources/GoogleCloud/Provider.swift /Users/Jorge/Desktop/Projects/Web/Swift/kisiBootcamp/.build/checkouts/google-cloud-provider/Sources/GoogleCloud/Common/GoogleCloudError.swift /Users/Jorge/Desktop/Projects/Web/Swift/kisiBootcamp/.build/checkouts/google-cloud-provider/Sources/GoogleCloud/Storage/CloudStorageError.swift /Users/Jorge/Desktop/Projects/Web/Swift/kisiBootcamp/.build/checkouts/google-cloud-provider/Sources/GoogleCloud/Extensions.swift /Users/Jorge/Desktop/Projects/Web/Swift/kisiBootcamp/.build/checkouts/google-cloud-provider/Sources/GoogleCloud/Common/Credentials/Loaders.swift /Users/Jorge/Desktop/Projects/Web/Swift/kisiBootcamp/.build/checkouts/google-cloud-provider/Sources/GoogleCloud/Storage/Models/Enums/StorageClass.swift /Users/Jorge/Desktop/Projects/Web/Swift/kisiBootcamp/.build/checkouts/google-cloud-provider/Sources/GoogleCloud/Storage/Models/StorageObject.swift /Users/Jorge/Desktop/Projects/Web/Swift/kisiBootcamp/.build/checkouts/google-cloud-provider/Sources/GoogleCloud/Storage/Models/StorageBucket.swift /Users/Jorge/Desktop/Projects/Web/Swift/kisiBootcamp/.build/checkouts/google-cloud-provider/Sources/GoogleCloud/Common/Credentials/ApplicationDefault.swift /Users/Jorge/Desktop/Projects/Web/Swift/kisiBootcamp/.build/checkouts/google-cloud-provider/Sources/GoogleCloud/Common/OAuth/OAuthApplicationDefault.swift /Users/Jorge/Desktop/Projects/Web/Swift/kisiBootcamp/.build/checkouts/google-cloud-provider/Sources/GoogleCloud/Storage/StorageClient.swift /Users/Jorge/Desktop/Projects/Web/Swift/kisiBootcamp/.build/checkouts/google-cloud-provider/Sources/GoogleCloud/Common/Credentials/ServiceAccount.swift /Users/Jorge/Desktop/Projects/Web/Swift/kisiBootcamp/.build/checkouts/google-cloud-provider/Sources/GoogleCloud/Common/OAuth/OAuthServiceAccount.swift /Users/Jorge/Desktop/Projects/Web/Swift/kisiBootcamp/.build/checkouts/google-cloud-provider/Sources/GoogleCloud/Storage/StorageRequest.swift /Users/Jorge/Desktop/Projects/Web/Swift/kisiBootcamp/.build/checkouts/google-cloud-provider/Sources/GoogleCloud/Storage/Models/StorageBucketList.swift /Users/Jorge/Desktop/Projects/Web/Swift/kisiBootcamp/.build/checkouts/google-cloud-provider/Sources/GoogleCloud/Common/OAuth/OAuthComputeEngine+AppEngineFlex.swift /Users/Jorge/Desktop/Projects/Web/Swift/kisiBootcamp/.build/checkouts/google-cloud-provider/Sources/GoogleCloud/Storage/Models/IAMPolicy.swift /Users/Jorge/Desktop/Projects/Web/Swift/kisiBootcamp/.build/x86_64-apple-macosx/debug/NIOHTTP1.swiftmodule /Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/lib/swift/macosx/x86_64/ObjectiveC.swiftmodule /Users/Jorge/Desktop/Projects/Web/Swift/kisiBootcamp/.build/x86_64-apple-macosx/debug/NIOOpenSSL.swiftmodule /Users/Jorge/Desktop/Projects/Web/Swift/kisiBootcamp/.build/x86_64-apple-macosx/debug/NIO.swiftmodule /Users/Jorge/Desktop/Projects/Web/Swift/kisiBootcamp/.build/x86_64-apple-macosx/debug/HTTP.swiftmodule /Users/Jorge/Desktop/Projects/Web/Swift/kisiBootcamp/.build/x86_64-apple-macosx/debug/NIOTLS.swiftmodule /Users/Jorge/Desktop/Projects/Web/Swift/kisiBootcamp/.build/x86_64-apple-macosx/debug/JWT.swiftmodule /Users/Jorge/Desktop/Projects/Web/Swift/kisiBootcamp/.build/x86_64-apple-macosx/debug/Async.swiftmodule /Users/Jorge/Desktop/Projects/Web/Swift/kisiBootcamp/.build/x86_64-apple-macosx/debug/Command.swiftmodule /Users/Jorge/Desktop/Projects/Web/Swift/kisiBootcamp/.build/x86_64-apple-macosx/debug/Service.swiftmodule /Users/Jorge/Desktop/Projects/Web/Swift/kisiBootcamp/.build/x86_64-apple-macosx/debug/Console.swiftmodule /Users/Jorge/Desktop/Projects/Web/Swift/kisiBootcamp/.build/x86_64-apple-macosx/debug/Core.swiftmodule /Users/Jorge/Desktop/Projects/Web/Swift/kisiBootcamp/.build/x86_64-apple-macosx/debug/Logging.swiftmodule /Users/Jorge/Desktop/Projects/Web/Swift/kisiBootcamp/.build/x86_64-apple-macosx/debug/Debugging.swiftmodule /Users/Jorge/Desktop/Projects/Web/Swift/kisiBootcamp/.build/x86_64-apple-macosx/debug/Routing.swiftmodule /Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/lib/swift/macosx/x86_64/Dispatch.swiftmodule /Users/Jorge/Desktop/Projects/Web/Swift/kisiBootcamp/.build/x86_64-apple-macosx/debug/COperatingSystem.swiftmodule /Users/Jorge/Desktop/Projects/Web/Swift/kisiBootcamp/.build/x86_64-apple-macosx/debug/Random.swiftmodule /Users/Jorge/Desktop/Projects/Web/Swift/kisiBootcamp/.build/x86_64-apple-macosx/debug/URLEncodedForm.swiftmodule /Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/lib/swift/macosx/x86_64/Darwin.swiftmodule /Users/Jorge/Desktop/Projects/Web/Swift/kisiBootcamp/.build/x86_64-apple-macosx/debug/Validation.swiftmodule /Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/lib/swift/macosx/x86_64/Foundation.swiftmodule /Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/lib/swift/macosx/x86_64/CoreFoundation.swiftmodule /Users/Jorge/Desktop/Projects/Web/Swift/kisiBootcamp/.build/x86_64-apple-macosx/debug/Crypto.swiftmodule /Users/Jorge/Desktop/Projects/Web/Swift/kisiBootcamp/.build/x86_64-apple-macosx/debug/Vapor.swiftmodule /Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/lib/swift/macosx/x86_64/CoreGraphics.swiftmodule /Users/Jorge/Desktop/Projects/Web/Swift/kisiBootcamp/.build/x86_64-apple-macosx/debug/NIOConcurrencyHelpers.swiftmodule /Users/Jorge/Desktop/Projects/Web/Swift/kisiBootcamp/.build/x86_64-apple-macosx/debug/Bits.swiftmodule /Users/Jorge/Desktop/Projects/Web/Swift/kisiBootcamp/.build/x86_64-apple-macosx/debug/NIOFoundationCompat.swiftmodule /Users/Jorge/Desktop/Projects/Web/Swift/kisiBootcamp/.build/x86_64-apple-macosx/debug/WebSocket.swiftmodule /Users/Jorge/Desktop/Projects/Web/Swift/kisiBootcamp/.build/x86_64-apple-macosx/debug/NIOWebSocket.swiftmodule /Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/lib/swift/macosx/x86_64/Swift.swiftmodule /Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/lib/swift/macosx/x86_64/IOKit.swiftmodule /Users/Jorge/Desktop/Projects/Web/Swift/kisiBootcamp/.build/x86_64-apple-macosx/debug/DatabaseKit.swiftmodule /Users/Jorge/Desktop/Projects/Web/Swift/kisiBootcamp/.build/x86_64-apple-macosx/debug/TemplateKit.swiftmodule /Users/Jorge/Desktop/Projects/Web/Swift/kisiBootcamp/.build/x86_64-apple-macosx/debug/Multipart.swiftmodule /Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/lib/swift/macosx/x86_64/SwiftOnoneSupport.swiftmodule /Users/Jorge/Desktop/Projects/Web/Swift/kisiBootcamp/.build/checkouts/swift-nio/Sources/CNIOSHA1/include/CNIOSHA1.h /usr/local/Cellar/libressl/2.9.2/include/openssl/asn1.h /usr/local/Cellar/libressl/2.9.2/include/openssl/tls1.h /usr/local/Cellar/libressl/2.9.2/include/openssl/dtls1.h /usr/local/Cellar/libressl/2.9.2/include/openssl/pkcs12.h /usr/local/Cellar/libressl/2.9.2/include/openssl/ssl2.h /usr/local/Cellar/libressl/2.9.2/include/openssl/pem2.h /usr/local/Cellar/libressl/2.9.2/include/openssl/ssl23.h /usr/local/Cellar/libressl/2.9.2/include/openssl/ssl3.h /usr/local/Cellar/libressl/2.9.2/include/openssl/x509v3.h /usr/local/Cellar/libressl/2.9.2/include/openssl/md5.h /usr/local/Cellar/libressl/2.9.2/include/openssl/pkcs7.h /usr/local/Cellar/libressl/2.9.2/include/openssl/x509.h /usr/local/Cellar/libressl/2.9.2/include/openssl/sha.h /usr/local/Cellar/libressl/2.9.2/include/openssl/dsa.h /usr/local/Cellar/libressl/2.9.2/include/openssl/ecdsa.h /usr/local/Cellar/libressl/2.9.2/include/openssl/rsa.h /Users/Jorge/Desktop/Projects/Web/Swift/kisiBootcamp/.build/checkouts/swift-nio/Sources/CNIOZlib/include/CNIOZlib.h /usr/local/Cellar/libressl/2.9.2/include/openssl/obj_mac.h /usr/local/Cellar/libressl/2.9.2/include/openssl/hmac.h /usr/local/Cellar/libressl/2.9.2/include/openssl/ec.h /Users/Jorge/Desktop/Projects/Web/Swift/kisiBootcamp/.build/checkouts/swift-nio/Sources/CNIOAtomics/include/cpp_magic.h /Users/Jorge/Desktop/Projects/Web/Swift/kisiBootcamp/.build/checkouts/swift-nio/Sources/CNIOLinux/include/ifaddrs-android.h /usr/local/Cellar/libressl/2.9.2/include/openssl/rand.h /usr/local/Cellar/libressl/2.9.2/include/openssl/conf.h /usr/local/Cellar/libressl/2.9.2/include/openssl/opensslconf.h /usr/local/Cellar/libressl/2.9.2/include/openssl/dh.h /usr/local/Cellar/libressl/2.9.2/include/openssl/ecdh.h /usr/local/Cellar/libressl/2.9.2/include/openssl/lhash.h /usr/local/Cellar/libressl/2.9.2/include/openssl/stack.h /usr/local/Cellar/libressl/2.9.2/include/openssl/safestack.h /usr/local/Cellar/libressl/2.9.2/include/openssl/ssl.h /Users/Jorge/Desktop/Projects/Web/Swift/kisiBootcamp/.build/checkouts/swift-nio-ssl/Sources/CNIOOpenSSL/include/c_nio_openssl.h /Users/Jorge/Desktop/Projects/Web/Swift/kisiBootcamp/.build/checkouts/crypto/Sources/CCryptoOpenSSL/include/c_crypto_openssl.h /usr/local/Cellar/libressl/2.9.2/include/openssl/pem.h /usr/local/Cellar/libressl/2.9.2/include/openssl/bn.h /Users/Jorge/Desktop/Projects/Web/Swift/kisiBootcamp/.build/checkouts/swift-nio/Sources/CNIODarwin/include/CNIODarwin.h /usr/local/Cellar/libressl/2.9.2/include/openssl/bio.h /usr/local/Cellar/libressl/2.9.2/include/openssl/crypto.h /usr/local/Cellar/libressl/2.9.2/include/openssl/srtp.h /usr/local/Cellar/libressl/2.9.2/include/openssl/evp.h /usr/local/Cellar/libressl/2.9.2/include/openssl/ossl_typ.h /usr/local/Cellar/libressl/2.9.2/include/openssl/buffer.h /Users/Jorge/Desktop/Projects/Web/Swift/kisiBootcamp/.build/checkouts/swift-nio/Sources/CNIOHTTPParser/include/CNIOHTTPParser.h /Users/Jorge/Desktop/Projects/Web/Swift/kisiBootcamp/.build/checkouts/swift-nio/Sources/CNIOHTTPParser/include/c_nio_http_parser.h /usr/local/Cellar/libressl/2.9.2/include/openssl/err.h /Users/Jorge/Desktop/Projects/Web/Swift/kisiBootcamp/.build/checkouts/swift-nio/Sources/CNIOAtomics/include/CNIOAtomics.h /usr/local/Cellar/libressl/2.9.2/include/openssl/opensslfeatures.h /usr/local/Cellar/libressl/2.9.2/include/openssl/objects.h /usr/local/Cellar/libressl/2.9.2/include/openssl/opensslv.h /Users/Jorge/Desktop/Projects/Web/Swift/kisiBootcamp/.build/checkouts/swift-nio/Sources/CNIOLinux/include/CNIOLinux.h /usr/local/Cellar/libressl/2.9.2/include/openssl/x509_vfy.h /Users/Jorge/Desktop/Projects/Web/Swift/kisiBootcamp/.build/x86_64-apple-macosx/debug/CNIOSHA1.build/module.modulemap /Users/Jorge/Desktop/Projects/Web/Swift/kisiBootcamp/.build/x86_64-apple-macosx/debug/CNIOOpenSSL.build/module.modulemap /Users/Jorge/Desktop/Projects/Web/Swift/kisiBootcamp/.build/x86_64-apple-macosx/debug/CCryptoOpenSSL.build/module.modulemap /Users/Jorge/Desktop/Projects/Web/Swift/kisiBootcamp/.build/x86_64-apple-macosx/debug/CNIOZlib.build/module.modulemap /Users/Jorge/Desktop/Projects/Web/Swift/kisiBootcamp/.build/x86_64-apple-macosx/debug/CNIODarwin.build/module.modulemap /Users/Jorge/Desktop/Projects/Web/Swift/kisiBootcamp/.build/x86_64-apple-macosx/debug/CNIOHTTPParser.build/module.modulemap /Users/Jorge/Desktop/Projects/Web/Swift/kisiBootcamp/.build/x86_64-apple-macosx/debug/CNIOAtomics.build/module.modulemap /Users/Jorge/Desktop/Projects/Web/Swift/kisiBootcamp/.build/x86_64-apple-macosx/debug/CNIOLinux.build/module.modulemap /Users/Jorge/Desktop/Projects/Web/Swift/kisiBootcamp/.build/checkouts/crypto/Sources/CBase32/include/module.modulemap /Users/Jorge/Desktop/Projects/Web/Swift/kisiBootcamp/.build/checkouts/crypto/Sources/CBcrypt/include/module.modulemap /Users/Jorge/Desktop/Projects/Web/Swift/kisiBootcamp/.build/checkouts/swift-nio-zlib-support/module.modulemap /Users/Jorge/Desktop/Projects/Web/Swift/kisiBootcamp/.build/checkouts/swift-nio-ssl-support/module.modulemap /Applications/Xcode.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX10.14.sdk/usr/include/objc/ObjectiveC.apinotes /Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/lib/swift/macosx/x86_64/Dispatch.apinotes /Applications/Xcode.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX10.14.sdk/usr/include/Darwin.apinotes /Applications/Xcode.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX10.14.sdk/System/Library/Frameworks/Foundation.framework/Headers/Foundation.apinotes /Applications/Xcode.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX10.14.sdk/System/Library/Frameworks/CoreGraphics.framework/Headers/CoreGraphics.apinotes /Applications/Xcode.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX10.14.sdk/System/Library/Frameworks/ApplicationServices.framework/Headers/ApplicationServices.apinotes /Applications/Xcode.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX10.14.sdk/System/Library/Frameworks/CoreText.framework/Headers/CoreText.apinotes /Applications/Xcode.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX10.14.sdk/System/Library/Frameworks/Security.framework/Headers/Security.apinotes
| D |
/// High-level wrappers for C-conversion functions.
module nxt.cconv;
/// Returns: `value` as a `string`.
void toStringInSink(const double value,
scope void delegate(scope const(char)[]) @safe sink,
in uint digitCount = 5)
@trusted
{
static immutable digitCountMax = 61;
assert(digitCount < digitCountMax);
char[3 + digitCountMax] buffer; // (sign + dot + null) and digits
gcvt(value, digitCount, buffer.ptr);
import core.stdc.string : cstrlen = strlen;
sink(buffer[0 .. cstrlen(buffer.ptr)]); // TODO: avoid
}
/// Returns: `value` as a `string`.
string toString(const double value,
in uint digitCount = 30)
@trusted pure nothrow
{
immutable length = 3 + digitCount; // (sign + dot + null) and digits
auto buffer = new char[length];
gcvt(value, digitCount, buffer.ptr);
import core.stdc.string : cstrlen = strlen;
return buffer[0 .. cstrlen(buffer.ptr)]; // TODO: avoid
}
///
@safe pure nothrow unittest
{
assert(0.0.toString(1) == `0`);
assert(0.1.toString(2) == `0.1`);
assert((-1.0).toString(1) == `-1`);
assert((-1.0).toString(2) == `-1`);
assert((-1.0).toString(3) == `-1`);
assert(3.14.toString(3) == `3.14`);
assert(3.141.toString(1) == `3`);
assert(3.141.toString(2) == `3.1`);
assert(3.141.toString(3) == `3.14`);
assert(3.141.toString(4) == `3.141`);
assert(3.141.toString(5) == `3.141`);
assert(1234567.123456789123456789.toString(7) == `1234567`);
assert(1234567.123456789123456789.toString(8) == `1234567.1`);
assert(1234567.123456789123456789.toString(9) == `1234567.12`);
assert(1234567.123456789123456789.toString(20) == `1234567.1234567892`);
}
private extern(C) pragma(inline, false)
{
pure nothrow @nogc:
char *gcvt(double number, int ndigit, char *buf);
}
| D |
/*******************************************************************************
* Copyright (c) 2000, 2005 IBM Corporation and others.
* All rights reserved. This program and the accompanying materials
* are made available under the terms of the Eclipse Public License v1.0
* which accompanies this distribution, and is available at
* http://www.eclipse.org/legal/epl-v10.html
*
* Contributors:
* IBM Corporation - initial API and implementation
* Port to the D programming language:
* Frank Benoit <benoit@tionex.de>
*******************************************************************************/
module dwtx.ui.internal.forms.widgets.SWTUtil;
import dwt.dnd.DragSource;
import dwt.dnd.DropTarget;
import dwt.widgets.Caret;
import dwt.widgets.Control;
import dwt.widgets.Display;
import dwt.widgets.Menu;
import dwt.widgets.ScrollBar;
import dwt.widgets.Shell;
import dwt.widgets.Widget;
/**
* Utility class to simplify access to some DWT resources.
*/
public class SWTUtil {
/**
* Returns the standard display to be used. The method first checks, if
* the thread calling this method has an associated disaply. If so, this
* display is returned. Otherwise the method returns the default display.
*/
public static Display getStandardDisplay() {
Display display;
display = Display.getCurrent();
if (display is null)
display = Display.getDefault();
return display;
}
/**
* Returns the shell for the given widget. If the widget doesn't represent
* a DWT object that manage a shell, <code>null</code> is returned.
*
* @return the shell for the given widget
*/
public static Shell getShell(Widget widget) {
if (null !is cast(Control)widget )
return (cast(Control) widget).getShell();
if (null !is cast(Caret)widget )
return (cast(Caret) widget).getParent().getShell();
if (null !is cast(DragSource)widget )
return (cast(DragSource) widget).getControl().getShell();
if (null !is cast(DropTarget)widget )
return (cast(DropTarget) widget).getControl().getShell();
if (null !is cast(Menu)widget )
return (cast(Menu) widget).getParent().getShell();
if (null !is cast(ScrollBar)widget )
return (cast(ScrollBar) widget).getParent().getShell();
return null;
}
}
| D |
module scrypt.scryptenc;
/*-
* Copyright 2009 Colin Percival
* All rights reserved.
*
* Redistribution and use in source and binary forms, with or without
* modification, are permitted provided that the following conditions
* are met:
* 1. Redistributions of source code must retain the above copyright
* notice, this list of conditions and the following disclaimer.
* 2. Redistributions in binary form must reproduce the above copyright
* notice, this list of conditions and the following disclaimer in the
* documentation and/or other materials provided with the distribution.
*
* THIS SOFTWARE IS PROVIDED BY THE AUTHOR AND CONTRIBUTORS ``AS IS'' AND
* ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
* IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE
* ARE DISCLAIMED. IN NO EVENT SHALL THE AUTHOR OR CONTRIBUTORS BE LIABLE
* FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL
* DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS
* OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION)
* HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT
* LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY
* OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
* SUCH DAMAGE.
*
* This file was originally written by Colin Percival as part of the Tarsnap
* online backup system.
*
* D binding created by Isak Andersson 2013 (BitPuffin@lavabit.com)
*/
import std.c.stdio;
alias ubyte uint8_t;
extern (C):
/**
* The parameters maxmem, maxmemfrac, and maxtime used by all of these
* functions are defined as follows:
* maxmem - maximum number of bytes of storage to use for V array (which is
* by far the largest consumer of memory). If this value is set to 0, no
* maximum will be enforced; any other value less than 1 MiB will be
* treated as 1 MiB.
* maxmemfrac - maximum fraction of available storage to use for the V array,
* where "available storage" is defined as the minimum out of the
* RLIMIT_AS, RLIMIT_DATA. and RLIMIT_RSS resource limits (if any are
* set). If this value is set to 0 or more than 0.5 it will be treated
* as 0.5; and this value will never cause a limit of less than 1 MiB to
* be enforced.
* maxtime - maximum amount of CPU time to spend computing the derived keys,
* in seconds. This limit is only approximately enforced; the CPU
* performance is estimated and parameter limits are chosen accordingly.
* For the encryption functions, the parameters to the scrypt key derivation
* function are chosen to make the key as strong as possible subject to the
* specified limits; for the decryption functions, the parameters used are
* compared to the computed limits and an error is returned if decrypting
* the data would take too much memory or CPU time.
*/
/**
* Return codes from scrypt(enc|dec)_(buf|file):
* 0 success
* 1 getrlimit or sysctl(hw.usermem) failed
* 2 clock_getres or clock_gettime failed
* 3 error computing derived key
* 4 could not read salt from /dev/urandom
* 5 error in OpenSSL
* 6 malloc failed
* 7 data is not a valid scrypt-encrypted block
* 8 unrecognized scrypt format
* 9 decrypting file would take too much memory
* 10 decrypting file would take too long
* 11 password is incorrect
* 12 error writing output file
* 13 error reading input file
*/
/**
* scryptenc_buf(inbuf, inbuflen, outbuf, passwd, passwdlen,
* maxmem, maxmemfrac, maxtime):
* Encrypt inbuflen bytes from inbuf, writing the resulting inbuflen + 128
* bytes to outbuf.
*/
int scryptenc_buf(const uint8_t *, size_t, uint8_t *,
const uint8_t *, size_t, size_t, double, double);
/**
* scryptdec_buf(inbuf, inbuflen, outbuf, outlen, passwd, passwdlen,
* maxmem, maxmemfrac, maxtime):
* Decrypt inbuflen bytes from inbuf, writing the result into outbuf and the
* decrypted data length to outlen. The allocated length of outbuf must
* be at least inbuflen.
*/
int scryptdec_buf(const uint8_t *, size_t, uint8_t *, size_t *,
const uint8_t *, size_t, size_t, double, double);
/**
* scryptenc_file(infile, outfile, passwd, passwdlen,
* maxmem, maxmemfrac, maxtime):
* Read a stream from infile and encrypt it, writing the resulting stream to
* outfile.
*/
int scryptenc_file(FILE *, FILE *, const uint8_t *, size_t,
size_t, double, double);
/**
* scryptdec_file(infile, outfile, passwd, passwdlen,
* maxmem, maxmemfrac, maxtime):
* Read a stream from infile and decrypt it, writing the resulting stream to
* outfile.
*/
int scryptdec_file(FILE *, FILE *, const uint8_t *, size_t,
size_t, double, double);
| D |
module day18_2;
import io = std.stdio, std.file, std.algorithm, std.range, std.typecons;
import std.conv, std.math, std.string : splitLines;
import std.algorithm.comparison : min;
alias Pnt = Tuple!(long, "x", long, "y");
string toStr(Pnt p) {
import std.format;
return format("(%s,%s)", p.x, p.y);
}
bool tryGetValue(K,V)(const V[K] aa, const K key, out V value) {
auto v = key in aa;
if (v is null) {
return false;
}
value = *v;
return true;
}
struct HashSet(T) {
int[T] _dict;
this(T[] arr) {
_dict = arr.map!(p => tuple(p, 0)).assocArray;
}
private this(int[T] d) {
_dict = d;
}
bool add(T val) {
auto prev = val in _dict;
_dict[val] = 0;
return prev is null;
}
bool remove(T val) {
return _dict.remove(val);
}
auto length() {
return _dict.length;
}
bool opBinaryRight(string op)(const T val) const {
static if (op == "in") {
return (val in _dict) !is null;
} else {
static assert(false, "Operator " ~ op ~ " not implemented");
}
}
HashSet!T dup() {
HashSet!T copy;
copy._dict = _dict.dup;
return copy;
}
HashSet!T dup() const {
// DLANG BUG: .dup of an AA retains the constness
// of its parameter, so the output is still const,
// and so we can't write a dup() const here.
// Presumably this is because we can't guarantee the
// constness of both keys and values.
// Perhaps there should be an "idup" for AAs.
int[T] dict;
foreach(kv; _dict.byKeyValue) {
dict[kv.key] = kv.value;
}
return HashSet(dict);
}
static HashSet!T fromArray(T[] arr) {
return HashSet(arr.map!(p => tuple(p, 0)).assocArray);
}
// 1) DLANG template gotcha:
// If this was:
// RangeImpl!T opSlice(T)()
// then it would compile with the error:
// "cannot deduce function from argument types `!()()`"
// I think because the extra (T) overshadows the parent class' (T) type
// and is really unnecessary here.
//
// 2) DLANG trick: use "inout" modifier on member,
// this transfers the mutability/immutability/constness
// of "this" to the returned value.
RangeImpl!T opSlice() inout {
return RangeImpl!T(_dict);
}
// DLANG TRICK: The following wrapper around AA's byKey()
// compiles only when using typeof(). The idea
// was to return it from opSlice, below, to avoid
// the extra allocation that keys() incurs.
// I tried Alias!() etc. but typeof() was the correct one
// to use.
struct RangeImpl(T) {
// import std.traits;
// import std.meta;
// alias byKeyAlias = Alias!(byKey!(int[T], T, int)(T.init));
// alias byKeyAlias = byKey;
// ReturnType!(byKey!(int[T], T, int)) keyRange;
// typeof(byKey( ( const(int[T]) ).init )) keyRange;
typeof( ( const(int[T]) ).init.byKey ) keyRange;
this(const int[T] d) {
keyRange = d.byKey();
}
bool empty() {
return keyRange.empty;
}
ref T front() {
return keyRange.front;
}
void popFront() {
keyRange.popFront();
}
}
}
auto deltas = [Pnt(0,-1), Pnt(0,1), Pnt(-1,0), Pnt(1,0)];
Pnt add(Pnt p1, Pnt p2) {
return Pnt(p1.x+p2.x, p1.y+p2.y);
}
// Build the graph, disregarding doors
// DLANG GOTCHA: Sending the graph here without using REF causes it to always be empty,
// since it starts out as empty in the calling function but when it's empty it has
// value semantics so it isn't really updated from here.
void buildGraph(dchar[Pnt] maze, Pnt start, ref Pnt[][Pnt] graph) {
void dfs(Pnt cur) {
deltas
.map!(d => add(cur, d))
.filter!(p => maze.get(p, '#') != '#')
.each!( (newPoint) {
graph[cur] ~= newPoint;
if (newPoint !in graph)
dfs(newPoint);
});
// DLANG BUG: Why can't the following be used instead of the .each!() above?
// using it causes the program to hang.
//
// .tee!(p => graph[cur] ~= p)
// .filter!(p => p !in graph)
// .each!(p => dfs(p));
}
dfs(start);
}
// Important characteristics of the shortest route from key a to b.
struct Route {
HashSet!dchar doors; // Doors on the route
HashSet!dchar keys; // Other keys encountered on the route
uint steps;
}
struct Locations {
Pnt[dchar] keyToPoint;
dchar[Pnt] pointToKey;
Pnt[dchar] doorToPoint;
dchar[Pnt] pointToDoor;
}
struct GraphData {
const Pnt[][Pnt] graph;
Pnt[] keys;
HashSet!Pnt keysHash;
}
GraphData preAllocateGraphData(const Pnt[][Pnt] graph) {
GraphData g = { graph };
g.keys = graph.keys;
g.keysHash = HashSet!Pnt.fromArray(g.keys);
return g;
}
Route[dchar] dijkstraShortestToAllOtherKeys(const Pnt start, GraphData graphData, Locations locs) {
import std.container.binaryheap;
auto graph = graphData.graph;
// Build shortest routes assuming there aren't any doors, but keep track
// of doors we see along the way.
Pnt[] heapStore;
heapStore.reserve(graphData.keys.length);
int[Pnt] dist;
Pnt[Pnt] prev;
auto comp = (Pnt a, Pnt b) => dist.get(a, int.max) > dist.get(b, int.max);
auto heap = BinaryHeap!(Pnt[], comp)(heapStore);
auto keysHash = graphData.keysHash.dup;
// OLD, non-performant code, without a priority queue:
// Pnt[] q = graph.keys; // Should be a priority queue
// HashSet!Pnt qAA = HashSet!Pnt.fromArray(q);
dist[start] = 0;
heap.insert(start);
dchar[Pnt] remainingKeys = locs.pointToKey.dup;
remainingKeys.remove(start);
dchar[Pnt] pointsToOtherKeys = remainingKeys.dup;
while(!heap.empty) {
// OLD, non-performant code, without a priority queue:
// auto minIndx = q.minIndex!( (a, b) => dist.get(a, int.max) < dist.get(b, int.max));
// auto u = q[minIndx];
// q = q.remove(minIndx);
auto u = heap.removeAny;
keysHash.remove(u);
// We can stop if we've gotten to all other keys
if (remainingKeys.remove(u) && remainingKeys.length == 0) {
break;
}
foreach(neighbor; graph[u].filter!(pnt => pnt in keysHash)) {
auto alt = dist.get(u, int.max - 1) + 1; // 1 = distance between any two nodes (node == square)
if (alt < dist.get(neighbor, int.max)) {
dist[neighbor] = alt;
prev[neighbor] = u;
heap.insert(neighbor);
}
}
} // while
Route[dchar] targetKeyToRoute;
auto reachableKeys = locs.pointToKey.byKeyValue
.filter!(kv => kv.key != start && kv.key in prev);
foreach(targetKV; reachableKeys) {
Route route;
Pnt next = targetKV.key;
while(next != start) {
route.steps++;
dchar* door = next in locs.pointToDoor;
if (door !is null) {
route.doors.add(*door);
}
dchar* otherKey = next in locs.pointToKey;
if (otherKey !is null) {
route.keys.add(*otherKey);
}
next = prev[next];
}
targetKeyToRoute[targetKV.value] = route;
}
return targetKeyToRoute;
}
Route[dchar][Pnt] buildKeysToRoutes(dchar[Pnt] maze, Locations locs, Pnt[] startPoints) {
Route[dchar][Pnt] keyToRoutes;
Pnt[][Pnt] graph;
// Build the graph of the four quarters
foreach(start; startPoints) {
buildGraph(maze, start, graph);
}
GraphData graphData = preAllocateGraphData(graph);
// Add routes from initial robots positions to all keys
foreach(start; startPoints) {
keyToRoutes[start] = dijkstraShortestToAllOtherKeys(start, graphData, locs);
}
// Add routes from all keys to all other keys
auto keysLocations = locs.keyToPoint.byValue;
foreach(keyLoc; keysLocations) {
keyToRoutes[keyLoc] = dijkstraShortestToAllOtherKeys(keyLoc, graphData, locs);
}
return keyToRoutes;
}
class State {
const Locations locs;
bool[dchar] doors;
bool[dchar] keys;
Pnt[] robotLocs;
uint steps;
uint treeDepth; // For debugging only
this(const Locations locs) {
this.locs = locs;
}
}
void drawMaze(const dchar[Pnt] maze, int indent, const State state) {
auto minx = maze.keys.map!(p => p.x).minElement;
auto maxx = maze.keys.map!(p => p.x).maxElement;
auto miny = maze.keys.map!(p => p.y).minElement;
auto maxy = maze.keys.map!(p => p.y).maxElement;
foreach(y; miny..maxy+1) {
foreach(_; 0..indent)
io.write(' ');
foreach(x; minx..maxx+1) {
Pnt p = Pnt(x, y);
dchar door, key;
if (maze[p] == '@')
io.write('.');
else if (state.robotLocs.any!(loc => loc == p))
io.write('@');
else if ((state.locs.pointToDoor.tryGetValue(p, door) && door !in state.doors) ||
(state.locs.pointToKey.tryGetValue(p, key) && key !in state.keys)) {
io.write('.');
} else {
io.write(maze[p]);
}
}
io.writeln();
}
}
struct MazeData {
const dchar[Pnt] maze;
const Route[dchar][Pnt] keyToRoutes;
uint[string] keysAndDoorsToNumStepsCache;
}
// maze parameter used only for debugging
uint step(const State state, ref MazeData mazeData) {
const Route[dchar][Pnt] keyToRoutes = mazeData.keyToRoutes;
const dchar[Pnt] maze = mazeData.maze;
// drawMaze(maze, state.treeDepth, state);
// io.writeln("Total steps: " ~ state.steps.to!string);
// io.writeln(state.keys.keys);
// io.writeln(state.doors.keys);
auto minSteps = uint.max;
foreach(robotInd, Pnt robotLoc; state.robotLocs) {
// Get reachable keys based on current closed doors
auto routesToOtherKeys = keyToRoutes[robotLoc];
// kv.Value.doors - doors in route.
// state.doors - currently locked doors.
// Include this only if all currently locked doors are NOT in route
// DLANG BUG: kv.value.doors.all!(d => d !in state.doors) compiled fine. It shouldn't have,
// since doors is an AA and the "all" function shouldn't have been able to compile
// with "d" as a key in state.doors. Maybe the "!in" operator is too permissive, or
// there's some sort of implicit conversion between the key-value of doors (of type bool[dchar]) and
// dchar, which doesn't do the correct thing.
auto unblockedRoutes = routesToOtherKeys.byKeyValue
.filter!(kv => kv.key in state.keys && kv.value.doors[].all!(d => d !in state.doors));
foreach(route; unblockedRoutes) {
// io.writeln("Considering route to " ~ route.key.text);
State newState = new State(state.locs);
newState.robotLocs = state.robotLocs.dup;
newState.robotLocs[robotInd] = state.locs.keyToPoint[route.key];
newState.steps = state.steps + route.value.steps;
newState.doors = state.doors.byKey.map!(k => tuple(k, true)).assocArray;
newState.keys = state.keys.byKey.map!(k => tuple(k, true)).assocArray;
newState.treeDepth = state.treeDepth + 1;
foreach(key; route.value.keys[]) {
auto door = key - 'a' + 'A';
newState.doors.remove(door);
newState.keys.remove(key);
}
if (newState.keys.length == 0) {
// io.writeln("returning, no keys, ", newState.steps);
return newState.steps;
}
// The key to the cache relies on both the (1) current position and (2) current keys
string robotLocsAsString = newState.robotLocs.map!toStr.join(",");
string keysAndDoors = robotLocsAsString ~ " " ~ newState.keys.byKey.array.sort.to!string;
uint* cachedDeltaSteps = keysAndDoors in mazeData.keysAndDoorsToNumStepsCache;
uint stepsFromSubState;
if (cachedDeltaSteps is null) {
// io.writeln(keysAndDoors ~ " not found in cache, recursing ";
stepsFromSubState = step(newState, mazeData);
// io.writeln("caching " ~ keysAndDoors ~ " -> " ~ stepsFromSubState.to!string ~ " - " ~ newState.steps.to!string);
mazeData.keysAndDoorsToNumStepsCache[keysAndDoors] = stepsFromSubState - newState.steps;
} else {
stepsFromSubState = newState.steps + *cachedDeltaSteps;
// io.writeln(keysAndDoors ~ " found in cache, using num of steps " ~ (*cachedDeltaSteps).to!string ~
// " -> " ~ stepsFromSubState.to!string);
}
minSteps = min(minSteps, stepsFromSubState);
}
}
return minSteps;
}
void main() {
dchar[Pnt] inputMaze;
Locations locs;
Pnt[][Pnt] graph;
Pnt startPoint;
auto lines = io.stdin.byLineCopy.array;
import std.uni: isLower;
Pnt[] startPoints;
foreach (j, line; lines) {
foreach(i, c; line) {
Pnt p = Pnt(i, j);
inputMaze[p] = c;
if (c == '@') {
startPoints ~= p;
} else if (c != '#' && c != '.') {
with (locs) {
if (c.isLower) {
keyToPoint[c] = p;
pointToKey[p] = c;
} else {
doorToPoint[c] = p;
pointToDoor[p] = c;
}
}
}
}
}
// io.writeln(startPoints);
// io.writeln(locs.keyToPoint.keys.sort.array);
// io.writeln(locs.doorToPoint.keys.sort.array);
auto keyToRoutes = buildKeysToRoutes(inputMaze, locs, startPoints);
State initalState = new State(locs);
with(initalState) {
doors = initalState.locs.doorToPoint.byKeyValue.map!(kv => tuple(kv.key, true)).assocArray;
keys = initalState.locs.keyToPoint.byKeyValue.map!(kv => tuple(kv.key, true)).assocArray;
robotLocs = startPoints;
steps = 0;
treeDepth = 0;
}
auto mazeData = MazeData(inputMaze, keyToRoutes);
auto minSteps = step(initalState, mazeData);
io.writeln(minSteps);
} | D |
instance BDT_1025_Bandit_H(Npc_Default)
{
name[0] = NAME_Bandit;
guild = GIL_BDT;
id = 1025;
voice = 9;
flags = 0;
npcType = NPCTYPE_MAIN;
aivar[AIV_EnemyOverride] = TRUE;
B_SetAttributesToChapter(self,3);
fight_tactic = FAI_HUMAN_STRONG;
EquipItem(self,ItMw_1h_Sld_Sword);
EquipItem(self,ItRw_Sld_Bow);
B_CreateAmbientInv(self);
B_SetNpcVisual(self,MALE,"Hum_Head_Thief",Face_B_Normal01,BodyTex_B,ITAR_BDT_H);
Mdl_SetModelFatness(self,0);
Mdl_ApplyOverlayMds(self,"Humans_Arrogance.mds");
B_GiveNpcTalents(self);
B_SetFightSkills(self,50);
daily_routine = Rtn_Start_1025;
};
func void Rtn_Start_1025()
{
TA_Stand_Guarding(8,0,22,0,"NW_FOREST_CAVE1_02");
TA_Stand_Guarding(22,0,8,0,"NW_FOREST_CAVE1_02");
};
| D |
module widgets.inputsgrid;
import std.string;
import std.file;
import std.path;
import std.stdio;
import gtk.Widget;
import gtk.Grid;
import gtk.Entry;
import gtk.Label;
import gtk.Button;
import gtk.Image;
import gtk.IconTheme;
import gtk.FileChooserDialog;
import gtk.FileFilter;
import gtk.Window;
import gdk.Pixbuf;
import helpers.functions;
class InputsGrid : Grid
{
Button avatarButton = null;
Entry usernameEntry = null;
Entry realNameEntry = null;
Grid inputsGrid = null;
Window parent = null;
string currentUser = null;
string newAvatarPath = null;
this(Window parent)
{
this.parent = parent;
this.avatarButton = new Button();
this.usernameEntry = new Entry();
this.usernameEntry.setHexpand(true); // only need to do this once I guess.
this.usernameEntry.setProperty("editable", false);
this.usernameEntry.setSensitive(false);
this.realNameEntry = new Entry();
this.layoutInputs();
}
void layoutInputs()
{
this.setColumnSpacing(10);
this.setRowSpacing(10);
this.setBorderWidth(10);
Label usernameLabel = new Label("Username:");
Label realNameLabel = new Label("Real Name:");
Label avatarLabel = new Label("Icon:");
this.attach(usernameLabel, 1, 0, 1, 1);
this.attach(this.usernameEntry, 2, 0, 1, 1);
this.attach(realNameLabel, 1, 1, 1, 1);
this.attach(this.realNameEntry, 2, 1, 1, 1);
this.attach(avatarLabel, 1, 2, 1, 1);
this.attach(this.avatarButton, 2, 2, 1, 1);
this.avatarButton.addOnPressed(&changeAvatar);
}
void changeAvatar(Button b)
{
auto filter = new FileFilter();
filter.addPattern("*.png");
auto fcd = new FileChooserDialog("Select an avatar", this.parent, FileChooserAction.OPEN);
fcd.addFilter(filter);
string newFaceFile = null;
int response = fcd.run();
if (response == ResponseType.OK)
{
newFaceFile = fcd.getFilename();
}
fcd.destroy();
if (newFaceFile)
{
putAvatarImageOntoButton(newFaceFile);
this.newAvatarPath = newFaceFile;
}
// if (this.currentUser.length && isRoot)
// {
// string accountsServiceFile = "/var/lib/AccountsService/icons/" ~ this.currentUser;
// if (exists(accountsServiceFile))
// {
// newFaceFile.copy(accountsServiceFile);
// }
// }
}
void fillInUserDetails(string username)
{
this.currentUser = username;
this.usernameEntry.setText(username);
string realName = getUserRealName(username);
if (realName)
{
this.realNameEntry.setText(realName);
}
putAvatarImageOntoButton(format("/home/%s/.face", username));
}
void putAvatarImageOntoButton(string imagePath)
{
if (exists(imagePath))
{
Image avatarImage = new Image(imagePath);
this.avatarButton.setImage(avatarImage);
}
else
{
IconTheme it = new IconTheme();
Image plusImage = new Image();
Pixbuf plusPixbuf = it.loadIcon("list-add", 20, GtkIconLookupFlags.FORCE_SVG);
plusImage.setFromPixbuf(plusPixbuf);
this.avatarButton.setImage(plusImage);
}
}
string getRealNameText()
{
return this.realNameEntry.getText();
}
}
| D |
/Users/abelfernandez/projects/vapor-server/Hello/.build/debug/Core.build/DataFile.swift.o : /Users/abelfernandez/projects/vapor-server/Hello/.build/checkouts/core.git-9210800844849382486/Sources/Core/RFC1123.swift /Users/abelfernandez/projects/vapor-server/Hello/.build/checkouts/core.git-9210800844849382486/Sources/Core/String+Polymorphic.swift /Users/abelfernandez/projects/vapor-server/Hello/.build/checkouts/core.git-9210800844849382486/Sources/Core/Sequence.swift /Users/abelfernandez/projects/vapor-server/Hello/.build/checkouts/core.git-9210800844849382486/Sources/Core/Collection+Safe.swift /Users/abelfernandez/projects/vapor-server/Hello/.build/checkouts/core.git-9210800844849382486/Sources/Core/Cache.swift /Users/abelfernandez/projects/vapor-server/Hello/.build/checkouts/core.git-9210800844849382486/Sources/Core/Extendable.swift /Users/abelfernandez/projects/vapor-server/Hello/.build/checkouts/core.git-9210800844849382486/Sources/Core/EmptyInitializable.swift /Users/abelfernandez/projects/vapor-server/Hello/.build/checkouts/core.git-9210800844849382486/Sources/Core/DataFile.swift /Users/abelfernandez/projects/vapor-server/Hello/.build/checkouts/core.git-9210800844849382486/Sources/Core/String+CaseInsensitiveCompare.swift /Users/abelfernandez/projects/vapor-server/Hello/.build/checkouts/core.git-9210800844849382486/Sources/Core/Semaphore.swift /Users/abelfernandez/projects/vapor-server/Hello/.build/checkouts/core.git-9210800844849382486/Sources/Core/String.swift /Users/abelfernandez/projects/vapor-server/Hello/.build/checkouts/core.git-9210800844849382486/Sources/Core/Dispatch.swift /Users/abelfernandez/projects/vapor-server/Hello/.build/checkouts/core.git-9210800844849382486/Sources/Core/Lock.swift /Users/abelfernandez/projects/vapor-server/Hello/.build/checkouts/core.git-9210800844849382486/Sources/Core/Portal.swift /Users/abelfernandez/projects/vapor-server/Hello/.build/checkouts/core.git-9210800844849382486/Sources/Core/FileProtocol.swift /Users/abelfernandez/projects/vapor-server/Hello/.build/checkouts/core.git-9210800844849382486/Sources/Core/StaticDataBuffer.swift /Users/abelfernandez/projects/vapor-server/Hello/.build/checkouts/core.git-9210800844849382486/Sources/Core/DispatchTime+Utilities.swift /Users/abelfernandez/projects/vapor-server/Hello/.build/checkouts/core.git-9210800844849382486/Sources/Core/Bits.swift /Users/abelfernandez/projects/vapor-server/Hello/.build/checkouts/core.git-9210800844849382486/Sources/Core/Exports.swift /Users/abelfernandez/projects/vapor-server/Hello/.build/checkouts/core.git-9210800844849382486/Sources/Core/Result.swift /Users/abelfernandez/projects/vapor-server/Hello/.build/checkouts/core.git-9210800844849382486/Sources/Core/Int+Hex.swift /Users/abelfernandez/projects/vapor-server/Hello/.build/checkouts/core.git-9210800844849382486/Sources/Core/Array.swift /Users/abelfernandez/projects/vapor-server/Hello/.build/checkouts/core.git-9210800844849382486/Sources/Core/WorkingDirectory.swift /Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/lib/swift/macosx/x86_64/ObjectiveC.apinotesc /Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/lib/swift/macosx/x86_64/Dispatch.apinotesc /Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/lib/swift/macosx/x86_64/Foundation.apinotesc /Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/lib/swift/macosx/x86_64/CoreGraphics.apinotesc /Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/lib/swift/macosx/x86_64/CoreText.apinotesc /Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/lib/swift/macosx/x86_64/ObjectiveC.swiftmodule /Users/abelfernandez/projects/vapor-server/Hello/.build/debug/libc.swiftmodule /Users/abelfernandez/projects/vapor-server/Hello/.build/debug/Debugging.swiftmodule /Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/lib/swift/macosx/x86_64/Dispatch.swiftmodule /Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/lib/swift/macosx/x86_64/Darwin.swiftmodule /Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/lib/swift/macosx/x86_64/Foundation.swiftmodule /Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/lib/swift/macosx/x86_64/CoreGraphics.swiftmodule /Users/abelfernandez/projects/vapor-server/Hello/.build/debug/Bits.swiftmodule /Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/lib/swift/macosx/x86_64/Swift.swiftmodule /Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/lib/swift/macosx/x86_64/IOKit.swiftmodule /Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/lib/swift/macosx/x86_64/SwiftOnoneSupport.swiftmodule /Users/abelfernandez/projects/vapor-server/Hello/.build/debug/CHTTP.build/module.modulemap /Users/abelfernandez/projects/vapor-server/Hello/.build/debug/CSQLite.build/module.modulemap
/Users/abelfernandez/projects/vapor-server/Hello/.build/debug/Core.build/DataFile~partial.swiftmodule : /Users/abelfernandez/projects/vapor-server/Hello/.build/checkouts/core.git-9210800844849382486/Sources/Core/RFC1123.swift /Users/abelfernandez/projects/vapor-server/Hello/.build/checkouts/core.git-9210800844849382486/Sources/Core/String+Polymorphic.swift /Users/abelfernandez/projects/vapor-server/Hello/.build/checkouts/core.git-9210800844849382486/Sources/Core/Sequence.swift /Users/abelfernandez/projects/vapor-server/Hello/.build/checkouts/core.git-9210800844849382486/Sources/Core/Collection+Safe.swift /Users/abelfernandez/projects/vapor-server/Hello/.build/checkouts/core.git-9210800844849382486/Sources/Core/Cache.swift /Users/abelfernandez/projects/vapor-server/Hello/.build/checkouts/core.git-9210800844849382486/Sources/Core/Extendable.swift /Users/abelfernandez/projects/vapor-server/Hello/.build/checkouts/core.git-9210800844849382486/Sources/Core/EmptyInitializable.swift /Users/abelfernandez/projects/vapor-server/Hello/.build/checkouts/core.git-9210800844849382486/Sources/Core/DataFile.swift /Users/abelfernandez/projects/vapor-server/Hello/.build/checkouts/core.git-9210800844849382486/Sources/Core/String+CaseInsensitiveCompare.swift /Users/abelfernandez/projects/vapor-server/Hello/.build/checkouts/core.git-9210800844849382486/Sources/Core/Semaphore.swift /Users/abelfernandez/projects/vapor-server/Hello/.build/checkouts/core.git-9210800844849382486/Sources/Core/String.swift /Users/abelfernandez/projects/vapor-server/Hello/.build/checkouts/core.git-9210800844849382486/Sources/Core/Dispatch.swift /Users/abelfernandez/projects/vapor-server/Hello/.build/checkouts/core.git-9210800844849382486/Sources/Core/Lock.swift /Users/abelfernandez/projects/vapor-server/Hello/.build/checkouts/core.git-9210800844849382486/Sources/Core/Portal.swift /Users/abelfernandez/projects/vapor-server/Hello/.build/checkouts/core.git-9210800844849382486/Sources/Core/FileProtocol.swift /Users/abelfernandez/projects/vapor-server/Hello/.build/checkouts/core.git-9210800844849382486/Sources/Core/StaticDataBuffer.swift /Users/abelfernandez/projects/vapor-server/Hello/.build/checkouts/core.git-9210800844849382486/Sources/Core/DispatchTime+Utilities.swift /Users/abelfernandez/projects/vapor-server/Hello/.build/checkouts/core.git-9210800844849382486/Sources/Core/Bits.swift /Users/abelfernandez/projects/vapor-server/Hello/.build/checkouts/core.git-9210800844849382486/Sources/Core/Exports.swift /Users/abelfernandez/projects/vapor-server/Hello/.build/checkouts/core.git-9210800844849382486/Sources/Core/Result.swift /Users/abelfernandez/projects/vapor-server/Hello/.build/checkouts/core.git-9210800844849382486/Sources/Core/Int+Hex.swift /Users/abelfernandez/projects/vapor-server/Hello/.build/checkouts/core.git-9210800844849382486/Sources/Core/Array.swift /Users/abelfernandez/projects/vapor-server/Hello/.build/checkouts/core.git-9210800844849382486/Sources/Core/WorkingDirectory.swift /Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/lib/swift/macosx/x86_64/ObjectiveC.apinotesc /Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/lib/swift/macosx/x86_64/Dispatch.apinotesc /Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/lib/swift/macosx/x86_64/Foundation.apinotesc /Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/lib/swift/macosx/x86_64/CoreGraphics.apinotesc /Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/lib/swift/macosx/x86_64/CoreText.apinotesc /Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/lib/swift/macosx/x86_64/ObjectiveC.swiftmodule /Users/abelfernandez/projects/vapor-server/Hello/.build/debug/libc.swiftmodule /Users/abelfernandez/projects/vapor-server/Hello/.build/debug/Debugging.swiftmodule /Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/lib/swift/macosx/x86_64/Dispatch.swiftmodule /Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/lib/swift/macosx/x86_64/Darwin.swiftmodule /Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/lib/swift/macosx/x86_64/Foundation.swiftmodule /Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/lib/swift/macosx/x86_64/CoreGraphics.swiftmodule /Users/abelfernandez/projects/vapor-server/Hello/.build/debug/Bits.swiftmodule /Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/lib/swift/macosx/x86_64/Swift.swiftmodule /Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/lib/swift/macosx/x86_64/IOKit.swiftmodule /Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/lib/swift/macosx/x86_64/SwiftOnoneSupport.swiftmodule /Users/abelfernandez/projects/vapor-server/Hello/.build/debug/CHTTP.build/module.modulemap /Users/abelfernandez/projects/vapor-server/Hello/.build/debug/CSQLite.build/module.modulemap
/Users/abelfernandez/projects/vapor-server/Hello/.build/debug/Core.build/DataFile~partial.swiftdoc : /Users/abelfernandez/projects/vapor-server/Hello/.build/checkouts/core.git-9210800844849382486/Sources/Core/RFC1123.swift /Users/abelfernandez/projects/vapor-server/Hello/.build/checkouts/core.git-9210800844849382486/Sources/Core/String+Polymorphic.swift /Users/abelfernandez/projects/vapor-server/Hello/.build/checkouts/core.git-9210800844849382486/Sources/Core/Sequence.swift /Users/abelfernandez/projects/vapor-server/Hello/.build/checkouts/core.git-9210800844849382486/Sources/Core/Collection+Safe.swift /Users/abelfernandez/projects/vapor-server/Hello/.build/checkouts/core.git-9210800844849382486/Sources/Core/Cache.swift /Users/abelfernandez/projects/vapor-server/Hello/.build/checkouts/core.git-9210800844849382486/Sources/Core/Extendable.swift /Users/abelfernandez/projects/vapor-server/Hello/.build/checkouts/core.git-9210800844849382486/Sources/Core/EmptyInitializable.swift /Users/abelfernandez/projects/vapor-server/Hello/.build/checkouts/core.git-9210800844849382486/Sources/Core/DataFile.swift /Users/abelfernandez/projects/vapor-server/Hello/.build/checkouts/core.git-9210800844849382486/Sources/Core/String+CaseInsensitiveCompare.swift /Users/abelfernandez/projects/vapor-server/Hello/.build/checkouts/core.git-9210800844849382486/Sources/Core/Semaphore.swift /Users/abelfernandez/projects/vapor-server/Hello/.build/checkouts/core.git-9210800844849382486/Sources/Core/String.swift /Users/abelfernandez/projects/vapor-server/Hello/.build/checkouts/core.git-9210800844849382486/Sources/Core/Dispatch.swift /Users/abelfernandez/projects/vapor-server/Hello/.build/checkouts/core.git-9210800844849382486/Sources/Core/Lock.swift /Users/abelfernandez/projects/vapor-server/Hello/.build/checkouts/core.git-9210800844849382486/Sources/Core/Portal.swift /Users/abelfernandez/projects/vapor-server/Hello/.build/checkouts/core.git-9210800844849382486/Sources/Core/FileProtocol.swift /Users/abelfernandez/projects/vapor-server/Hello/.build/checkouts/core.git-9210800844849382486/Sources/Core/StaticDataBuffer.swift /Users/abelfernandez/projects/vapor-server/Hello/.build/checkouts/core.git-9210800844849382486/Sources/Core/DispatchTime+Utilities.swift /Users/abelfernandez/projects/vapor-server/Hello/.build/checkouts/core.git-9210800844849382486/Sources/Core/Bits.swift /Users/abelfernandez/projects/vapor-server/Hello/.build/checkouts/core.git-9210800844849382486/Sources/Core/Exports.swift /Users/abelfernandez/projects/vapor-server/Hello/.build/checkouts/core.git-9210800844849382486/Sources/Core/Result.swift /Users/abelfernandez/projects/vapor-server/Hello/.build/checkouts/core.git-9210800844849382486/Sources/Core/Int+Hex.swift /Users/abelfernandez/projects/vapor-server/Hello/.build/checkouts/core.git-9210800844849382486/Sources/Core/Array.swift /Users/abelfernandez/projects/vapor-server/Hello/.build/checkouts/core.git-9210800844849382486/Sources/Core/WorkingDirectory.swift /Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/lib/swift/macosx/x86_64/ObjectiveC.apinotesc /Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/lib/swift/macosx/x86_64/Dispatch.apinotesc /Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/lib/swift/macosx/x86_64/Foundation.apinotesc /Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/lib/swift/macosx/x86_64/CoreGraphics.apinotesc /Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/lib/swift/macosx/x86_64/CoreText.apinotesc /Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/lib/swift/macosx/x86_64/ObjectiveC.swiftmodule /Users/abelfernandez/projects/vapor-server/Hello/.build/debug/libc.swiftmodule /Users/abelfernandez/projects/vapor-server/Hello/.build/debug/Debugging.swiftmodule /Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/lib/swift/macosx/x86_64/Dispatch.swiftmodule /Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/lib/swift/macosx/x86_64/Darwin.swiftmodule /Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/lib/swift/macosx/x86_64/Foundation.swiftmodule /Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/lib/swift/macosx/x86_64/CoreGraphics.swiftmodule /Users/abelfernandez/projects/vapor-server/Hello/.build/debug/Bits.swiftmodule /Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/lib/swift/macosx/x86_64/Swift.swiftmodule /Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/lib/swift/macosx/x86_64/IOKit.swiftmodule /Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/lib/swift/macosx/x86_64/SwiftOnoneSupport.swiftmodule /Users/abelfernandez/projects/vapor-server/Hello/.build/debug/CHTTP.build/module.modulemap /Users/abelfernandez/projects/vapor-server/Hello/.build/debug/CSQLite.build/module.modulemap
| D |
/*
TEST_OUTPUT:
---
fail_compilation/ice11553.d(22): Error: recursive template expansion while looking for `A!().A()`
---
*/
template A(alias T)
{
template A()
{
alias A = T!();
}
}
template B()
{
alias B = A!(.B);
}
static if (A!B) {}
| D |
#!/usr/bin/env -S rdmd -I..
module day22.part2;
import common.io;
import std.stdio;
import std.string;
import std.conv;
import std.algorithm;
import std.array;
import std.format : formattedRead;
import std.exception;
int game = 0;
long calculateScore(int[] player) {
long sum = 0;
ulong cardNum = player.length;
foreach(i, j; player) {
sum += ((cardNum-i) * j);
}
return sum;
}
enum bool log = false;
// NOTE: player cards are modified in place. Duplicate before recursive call...
int playGame(ref int[][2] player, int callerGame) {
string[string] playedRounds;
int myGame = ++game;
if(log) writefln("=== Game %s ===", game);
int round = 1;
int winner;
while(!(player[0].empty || player[1].empty)) {
if(log) writefln("-- Round %s Game %s --", round, myGame);
foreach (p; 0..2) {
if(log) writefln("Player %s deck: %s", p+1, player[p]);
}
string key = to!string(player);
if (key in playedRounds) {
if(log) writefln("Deja Vu at %s, declaring Player 1 the winner!", playedRounds[key]);
return 0;
}
playedRounds[key] = format("Round %s Game %s", round, myGame);
int[] taken;
foreach (p; 0..2) {
if(log) writefln("Player %s plays %s", p+1, player[p][0]);
taken ~= player[p][0];
player[p] = player[p][1..$];
}
if (taken[0] <= player[0].length && taken[1] <= player[1].length) {
int[][2] copy = player.dup;
// shorten to match card id
copy[0].length = taken[0];
copy[1].length = taken[1];
if(log) writeln("Playing new game to determine winner");
winner = playGame(copy, myGame);
}
else {
if (taken[0] > taken[1]) {
winner = 0;
}
else {
winner = 1;
}
}
if(log) writefln("Player %s wins the round!", winner+1);
if (winner == 0) {
player[winner] ~= taken;
}
else {
player[winner] ~= reverse(taken);
}
if(log) writeln();
round++;
// readln();
}
if (callerGame > 0) {
if(log) writefln("Back to game %s", callerGame);
}
return winner;
}
void main() {
File file = File("input", "rt");
int[][2] player;
player[0] = readParagraph(file)[1..$].map!(to!int).array;
player[1] = readParagraph(file)[1..$].map!(to!int).array;
int winner = playGame(player, 0);
writeln("=== Post-Game Results ===");
foreach (p; 0..2) {
writefln("Player %s deck: %s", p+1, player[p]);
}
// winner is still valid...
long sum = calculateScore(player[winner]);
writeln(sum);
}
| D |
build/Debug/Cygwin-Windows/HW10_6.o: HW10_6.cpp DynamicStack.h
DynamicStack.h:
| D |
/*
* This file is part of gtkD.
*
* gtkD is free software; you can redistribute it and/or modify
* it under the terms of the GNU Lesser General Public License as published by
* the Free Software Foundation; either version 2.1 of the License, or
* (at your option) any later version.
*
* gtkD is distributed in the hope that it will be useful,
* but WITHOUT ANY WARRANTY; without even the implied warranty of
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
* GNU Lesser General Public License for more details.
*
* You should have received a copy of the GNU Lesser General Public License
* along with gtkD; if not, write to the Free Software
* Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
*/
// generated automatically - do not change
// find conversion definition on APILookup.txt
// implement new conversion functionalities on the wrap.utils pakage
/*
* Conversion parameters:
* inFile = GtkPageSetupUnixDialog.html
* outPack = gtk
* outFile = PageSetupUnixDialog
* strct = GtkPageSetupUnixDialog
* realStrct=
* ctorStrct=
* clss = PageSetupUnixDialog
* interf =
* class Code: No
* interface Code: No
* template for:
* extend =
* implements:
* prefixes:
* - gtk_page_setup_unix_dialog_
* - gtk_
* omit structs:
* omit prefixes:
* omit code:
* omit signals:
* imports:
* - gtkD.glib.Str
* - gtkD.gtk.Widget
* - gtkD.gtk.Window
* - gtkD.gtk.PageSetup
* - gtkD.gtk.PrintSettings
* structWrap:
* - GtkPageSetup* -> PageSetup
* - GtkPrintSettings* -> PrintSettings
* - GtkWidget* -> Widget
* - GtkWindow* -> Window
* module aliases:
* local aliases:
* overrides:
*/
module gtkD.gtk.PageSetupUnixDialog;
public import gtkD.gtkc.gtktypes;
private import gtkD.gtkc.gtk;
private import gtkD.glib.ConstructionException;
private import gtkD.glib.Str;
private import gtkD.gtk.Widget;
private import gtkD.gtk.Window;
private import gtkD.gtk.PageSetup;
private import gtkD.gtk.PrintSettings;
private import gtkD.gtk.Dialog;
/**
* Description
* GtkPageSetupUnixDialog implements a page setup dialog for platforms
* which don't provide a native page setup dialog, like Unix. It can
* be used very much like any other GTK+ dialog, at the cost of
* the portability offered by the high-level printing API
* Printing support was added in GTK+ 2.10.
*/
public class PageSetupUnixDialog : Dialog
{
/** the main Gtk struct */
protected GtkPageSetupUnixDialog* gtkPageSetupUnixDialog;
public GtkPageSetupUnixDialog* getPageSetupUnixDialogStruct()
{
return gtkPageSetupUnixDialog;
}
/** the main Gtk struct as a void* */
protected override void* getStruct()
{
return cast(void*)gtkPageSetupUnixDialog;
}
/**
* Sets our main struct and passes it to the parent class
*/
public this (GtkPageSetupUnixDialog* gtkPageSetupUnixDialog)
{
if(gtkPageSetupUnixDialog is null)
{
this = null;
return;
}
//Check if there already is a D object for this gtk struct
void* ptr = getDObject(cast(GObject*)gtkPageSetupUnixDialog);
if( ptr !is null )
{
this = cast(PageSetupUnixDialog)ptr;
return;
}
super(cast(GtkDialog*)gtkPageSetupUnixDialog);
this.gtkPageSetupUnixDialog = gtkPageSetupUnixDialog;
}
/**
*/
/**
* Creates a new page setup dialog.
* Since 2.10
* Params:
* title = the title of the dialog, or NULL
* parent = transient parent of the dialog, or NULL
* Throws: ConstructionException GTK+ fails to create the object.
*/
public this (string title, Window parent)
{
// GtkWidget * gtk_page_setup_unix_dialog_new (const gchar *title, GtkWindow *parent);
auto p = gtk_page_setup_unix_dialog_new(Str.toStringz(title), (parent is null) ? null : parent.getWindowStruct());
if(p is null)
{
throw new ConstructionException("null returned by gtk_page_setup_unix_dialog_new(Str.toStringz(title), (parent is null) ? null : parent.getWindowStruct())");
}
this(cast(GtkPageSetupUnixDialog*) p);
}
/**
* Sets the GtkPageSetup from which the page setup
* dialog takes its values.
* Since 2.10
* Params:
* pageSetup = a GtkPageSetup
*/
public void setPageSetup(PageSetup pageSetup)
{
// void gtk_page_setup_unix_dialog_set_page_setup (GtkPageSetupUnixDialog *dialog, GtkPageSetup *page_setup);
gtk_page_setup_unix_dialog_set_page_setup(gtkPageSetupUnixDialog, (pageSetup is null) ? null : pageSetup.getPageSetupStruct());
}
/**
* Gets the currently selected page setup from the dialog.
* Since 2.10
* Returns: the current page setup
*/
public PageSetup getPageSetup()
{
// GtkPageSetup * gtk_page_setup_unix_dialog_get_page_setup (GtkPageSetupUnixDialog *dialog);
auto p = gtk_page_setup_unix_dialog_get_page_setup(gtkPageSetupUnixDialog);
if(p is null)
{
return null;
}
return new PageSetup(cast(GtkPageSetup*) p);
}
/**
* Sets the GtkPrintSettings from which the page setup dialog
* takes its values.
* Since 2.10
* Params:
* printSettings = a GtkPrintSettings
*/
public void setPrintSettings(PrintSettings printSettings)
{
// void gtk_page_setup_unix_dialog_set_print_settings (GtkPageSetupUnixDialog *dialog, GtkPrintSettings *print_settings);
gtk_page_setup_unix_dialog_set_print_settings(gtkPageSetupUnixDialog, (printSettings is null) ? null : printSettings.getPrintSettingsStruct());
}
/**
* Gets the current print settings from the dialog.
* Since 2.10
* Returns: the current print settings
*/
public PrintSettings getPrintSettings()
{
// GtkPrintSettings * gtk_page_setup_unix_dialog_get_print_settings (GtkPageSetupUnixDialog *dialog);
auto p = gtk_page_setup_unix_dialog_get_print_settings(gtkPageSetupUnixDialog);
if(p is null)
{
return null;
}
return new PrintSettings(cast(GtkPrintSettings*) p);
}
}
| D |
import std.stdio;
import example.api.examplerpc;
import example.api.example;
import hunt.service.remoting.invoker.ServiceInvokerFactory;
import hunt.service.RegistryConfig;
import neton.client.NetonOption;
import hunt.net;
import std.conv;
void main()
{
NetUtil.startEventLoop();
auto invokerFactory = new ServiceInvokerFactory();
RegistryConfig conf = {"127.0.0.1",50051,"example.provider"};
// invokerFactory.setRegistry(conf);
invokerFactory.setDirectUrl("tcp://127.0.0.1:7788");
auto client = invokerFactory.createClient!(HelloClient)();
assert(client !is null);
HelloRequest req = new HelloRequest();
foreach(num; 1 .. 10)
{
req.name = to!string(num);
auto res = client.sayHello(req);
writeln("response : ", res.echo);
}
}
| D |
/Users/oyo02699/apps/easycrm/easycrm-api/target/rls/debug/deps/traitobject-651b635d9f4755e2.rmeta: /Users/oyo02699/.cargo/registry/src/mirrors.ustc.edu.cn-61ef6e0cd06fb9b8/traitobject-0.1.0/src/lib.rs /Users/oyo02699/.cargo/registry/src/mirrors.ustc.edu.cn-61ef6e0cd06fb9b8/traitobject-0.1.0/src/impls.rs
/Users/oyo02699/apps/easycrm/easycrm-api/target/rls/debug/deps/libtraitobject-651b635d9f4755e2.rlib: /Users/oyo02699/.cargo/registry/src/mirrors.ustc.edu.cn-61ef6e0cd06fb9b8/traitobject-0.1.0/src/lib.rs /Users/oyo02699/.cargo/registry/src/mirrors.ustc.edu.cn-61ef6e0cd06fb9b8/traitobject-0.1.0/src/impls.rs
/Users/oyo02699/apps/easycrm/easycrm-api/target/rls/debug/deps/traitobject-651b635d9f4755e2.d: /Users/oyo02699/.cargo/registry/src/mirrors.ustc.edu.cn-61ef6e0cd06fb9b8/traitobject-0.1.0/src/lib.rs /Users/oyo02699/.cargo/registry/src/mirrors.ustc.edu.cn-61ef6e0cd06fb9b8/traitobject-0.1.0/src/impls.rs
/Users/oyo02699/.cargo/registry/src/mirrors.ustc.edu.cn-61ef6e0cd06fb9b8/traitobject-0.1.0/src/lib.rs:
/Users/oyo02699/.cargo/registry/src/mirrors.ustc.edu.cn-61ef6e0cd06fb9b8/traitobject-0.1.0/src/impls.rs:
| D |
/Users/nathaneidelson/Developer/CS51-Demo/Build/Intermediates/CS51-Demo.build/Debug-iphonesimulator/CS51-Demo.build/Objects-normal/x86_64/NEPhotoLogDetailViewController.o : /Users/nathaneidelson/Developer/CS51-Demo/CS51-Demo/Models/PhotoLog.swift /Users/nathaneidelson/Developer/CS51-Demo/CS51-Demo/NEPhotoLogDetailViewController.swift /Users/nathaneidelson/Developer/CS51-Demo/CS51-Demo/AppDelegate.swift /Users/nathaneidelson/Developer/CS51-Demo/CS51-Demo/NEPhotoLogTableViewController.swift /Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/lib/swift/iphonesimulator/x86_64/Swift.swiftmodule /Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/lib/swift/iphonesimulator/x86_64/SwiftOnoneSupport.swiftmodule /Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/lib/swift/iphonesimulator/x86_64/UIKit.swiftmodule /Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/lib/swift/iphonesimulator/x86_64/Foundation.swiftmodule /Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/lib/swift/iphonesimulator/x86_64/ObjectiveC.apinotesc /Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/lib/swift/iphonesimulator/x86_64/Dispatch.apinotesc /Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/lib/swift/iphonesimulator/x86_64/Darwin.swiftmodule /Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/lib/swift/iphonesimulator/x86_64/Dispatch.swiftmodule /Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/lib/swift/iphonesimulator/x86_64/ObjectiveC.swiftmodule /Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/lib/swift/iphonesimulator/x86_64/CoreGraphics.swiftmodule /Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/lib/swift/iphonesimulator/x86_64/CoreGraphics.apinotesc /Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/lib/swift/iphonesimulator/x86_64/Foundation.apinotesc /Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/lib/swift/iphonesimulator/x86_64/CoreText.apinotesc /Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/lib/swift/iphonesimulator/x86_64/UIKit.apinotesc /Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/lib/swift/iphonesimulator/x86_64/QuartzCore.swiftmodule /Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/lib/swift/iphonesimulator/x86_64/CoreImage.swiftmodule /Users/nathaneidelson/Developer/CS51-Demo/Build/Products/Debug-iphonesimulator/Alamofire/Alamofire.framework/Modules/Alamofire.swiftmodule/x86_64.swiftmodule /Users/nathaneidelson/Developer/CS51-Demo/Build/Products/Debug-iphonesimulator/Alamofire/Alamofire.framework/Headers/Alamofire-Swift.h /Users/nathaneidelson/Developer/CS51-Demo/Build/Products/Debug-iphonesimulator/Alamofire/Alamofire.framework/Headers/Alamofire-umbrella.h /Users/nathaneidelson/Developer/CS51-Demo/Build/Products/Debug-iphonesimulator/Alamofire/Alamofire.framework/Modules/module.modulemap
/Users/nathaneidelson/Developer/CS51-Demo/Build/Intermediates/CS51-Demo.build/Debug-iphonesimulator/CS51-Demo.build/Objects-normal/x86_64/NEPhotoLogDetailViewController~partial.swiftmodule : /Users/nathaneidelson/Developer/CS51-Demo/CS51-Demo/Models/PhotoLog.swift /Users/nathaneidelson/Developer/CS51-Demo/CS51-Demo/NEPhotoLogDetailViewController.swift /Users/nathaneidelson/Developer/CS51-Demo/CS51-Demo/AppDelegate.swift /Users/nathaneidelson/Developer/CS51-Demo/CS51-Demo/NEPhotoLogTableViewController.swift /Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/lib/swift/iphonesimulator/x86_64/Swift.swiftmodule /Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/lib/swift/iphonesimulator/x86_64/SwiftOnoneSupport.swiftmodule /Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/lib/swift/iphonesimulator/x86_64/UIKit.swiftmodule /Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/lib/swift/iphonesimulator/x86_64/Foundation.swiftmodule /Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/lib/swift/iphonesimulator/x86_64/ObjectiveC.apinotesc /Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/lib/swift/iphonesimulator/x86_64/Dispatch.apinotesc /Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/lib/swift/iphonesimulator/x86_64/Darwin.swiftmodule /Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/lib/swift/iphonesimulator/x86_64/Dispatch.swiftmodule /Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/lib/swift/iphonesimulator/x86_64/ObjectiveC.swiftmodule /Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/lib/swift/iphonesimulator/x86_64/CoreGraphics.swiftmodule /Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/lib/swift/iphonesimulator/x86_64/CoreGraphics.apinotesc /Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/lib/swift/iphonesimulator/x86_64/Foundation.apinotesc /Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/lib/swift/iphonesimulator/x86_64/CoreText.apinotesc /Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/lib/swift/iphonesimulator/x86_64/UIKit.apinotesc /Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/lib/swift/iphonesimulator/x86_64/QuartzCore.swiftmodule /Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/lib/swift/iphonesimulator/x86_64/CoreImage.swiftmodule /Users/nathaneidelson/Developer/CS51-Demo/Build/Products/Debug-iphonesimulator/Alamofire/Alamofire.framework/Modules/Alamofire.swiftmodule/x86_64.swiftmodule /Users/nathaneidelson/Developer/CS51-Demo/Build/Products/Debug-iphonesimulator/Alamofire/Alamofire.framework/Headers/Alamofire-Swift.h /Users/nathaneidelson/Developer/CS51-Demo/Build/Products/Debug-iphonesimulator/Alamofire/Alamofire.framework/Headers/Alamofire-umbrella.h /Users/nathaneidelson/Developer/CS51-Demo/Build/Products/Debug-iphonesimulator/Alamofire/Alamofire.framework/Modules/module.modulemap
/Users/nathaneidelson/Developer/CS51-Demo/Build/Intermediates/CS51-Demo.build/Debug-iphonesimulator/CS51-Demo.build/Objects-normal/x86_64/NEPhotoLogDetailViewController~partial.swiftdoc : /Users/nathaneidelson/Developer/CS51-Demo/CS51-Demo/Models/PhotoLog.swift /Users/nathaneidelson/Developer/CS51-Demo/CS51-Demo/NEPhotoLogDetailViewController.swift /Users/nathaneidelson/Developer/CS51-Demo/CS51-Demo/AppDelegate.swift /Users/nathaneidelson/Developer/CS51-Demo/CS51-Demo/NEPhotoLogTableViewController.swift /Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/lib/swift/iphonesimulator/x86_64/Swift.swiftmodule /Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/lib/swift/iphonesimulator/x86_64/SwiftOnoneSupport.swiftmodule /Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/lib/swift/iphonesimulator/x86_64/UIKit.swiftmodule /Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/lib/swift/iphonesimulator/x86_64/Foundation.swiftmodule /Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/lib/swift/iphonesimulator/x86_64/ObjectiveC.apinotesc /Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/lib/swift/iphonesimulator/x86_64/Dispatch.apinotesc /Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/lib/swift/iphonesimulator/x86_64/Darwin.swiftmodule /Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/lib/swift/iphonesimulator/x86_64/Dispatch.swiftmodule /Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/lib/swift/iphonesimulator/x86_64/ObjectiveC.swiftmodule /Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/lib/swift/iphonesimulator/x86_64/CoreGraphics.swiftmodule /Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/lib/swift/iphonesimulator/x86_64/CoreGraphics.apinotesc /Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/lib/swift/iphonesimulator/x86_64/Foundation.apinotesc /Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/lib/swift/iphonesimulator/x86_64/CoreText.apinotesc /Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/lib/swift/iphonesimulator/x86_64/UIKit.apinotesc /Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/lib/swift/iphonesimulator/x86_64/QuartzCore.swiftmodule /Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/lib/swift/iphonesimulator/x86_64/CoreImage.swiftmodule /Users/nathaneidelson/Developer/CS51-Demo/Build/Products/Debug-iphonesimulator/Alamofire/Alamofire.framework/Modules/Alamofire.swiftmodule/x86_64.swiftmodule /Users/nathaneidelson/Developer/CS51-Demo/Build/Products/Debug-iphonesimulator/Alamofire/Alamofire.framework/Headers/Alamofire-Swift.h /Users/nathaneidelson/Developer/CS51-Demo/Build/Products/Debug-iphonesimulator/Alamofire/Alamofire.framework/Headers/Alamofire-umbrella.h /Users/nathaneidelson/Developer/CS51-Demo/Build/Products/Debug-iphonesimulator/Alamofire/Alamofire.framework/Modules/module.modulemap
| D |
/Users/lizziesiegle/Desktop/server/DerivedData/server/Build/Intermediates/server.build/Debug/Kitura.build/Objects-normal/x86_64/RouterRequest.o : /Users/lizziesiegle/Desktop/server/Packages/Kitura-1.6.2/Sources/Kitura/Error.swift /Users/lizziesiegle/Desktop/server/Packages/Kitura-1.6.2/Sources/Kitura/FileResourceServer.swift /Users/lizziesiegle/Desktop/server/Packages/Kitura-1.6.2/Sources/Kitura/Headers.swift /Users/lizziesiegle/Desktop/server/Packages/Kitura-1.6.2/Sources/Kitura/HTTPVersion.swift /Users/lizziesiegle/Desktop/server/Packages/Kitura-1.6.2/Sources/Kitura/InternalError.swift /Users/lizziesiegle/Desktop/server/Packages/Kitura-1.6.2/Sources/Kitura/JSONPError.swift /Users/lizziesiegle/Desktop/server/Packages/Kitura-1.6.2/Sources/Kitura/Kitura.swift /Users/lizziesiegle/Desktop/server/Packages/Kitura-1.6.2/Sources/Kitura/LinkParameter.swift /Users/lizziesiegle/Desktop/server/Packages/Kitura-1.6.2/Sources/Kitura/MimeTypeAcceptor.swift /Users/lizziesiegle/Desktop/server/Packages/Kitura-1.6.2/Sources/Kitura/Router.swift /Users/lizziesiegle/Desktop/server/Packages/Kitura-1.6.2/Sources/Kitura/RouteRegex.swift /Users/lizziesiegle/Desktop/server/Packages/Kitura-1.6.2/Sources/Kitura/RouterElement.swift /Users/lizziesiegle/Desktop/server/Packages/Kitura-1.6.2/Sources/Kitura/RouterElementWalker.swift /Users/lizziesiegle/Desktop/server/Packages/Kitura-1.6.2/Sources/Kitura/RouterHandler.swift /Users/lizziesiegle/Desktop/server/Packages/Kitura-1.6.2/Sources/Kitura/RouterHTTPVerbs+Error.swift /Users/lizziesiegle/Desktop/server/Packages/Kitura-1.6.2/Sources/Kitura/RouterHTTPVerbs_generated.swift /Users/lizziesiegle/Desktop/server/Packages/Kitura-1.6.2/Sources/Kitura/RouterMethod.swift /Users/lizziesiegle/Desktop/server/Packages/Kitura-1.6.2/Sources/Kitura/RouterMiddleware.swift /Users/lizziesiegle/Desktop/server/Packages/Kitura-1.6.2/Sources/Kitura/RouterMiddlewareGenerator.swift /Users/lizziesiegle/Desktop/server/Packages/Kitura-1.6.2/Sources/Kitura/RouterMiddlewareWalker.swift /Users/lizziesiegle/Desktop/server/Packages/Kitura-1.6.2/Sources/Kitura/RouterParameterWalker.swift /Users/lizziesiegle/Desktop/server/Packages/Kitura-1.6.2/Sources/Kitura/RouterRequest.swift /Users/lizziesiegle/Desktop/server/Packages/Kitura-1.6.2/Sources/Kitura/RouterResponse.swift /Users/lizziesiegle/Desktop/server/Packages/Kitura-1.6.2/Sources/Kitura/SSLConfig.swift /Users/lizziesiegle/Desktop/server/Packages/Kitura-1.6.2/Sources/Kitura/String+Extensions.swift /Users/lizziesiegle/Desktop/server/Packages/Kitura-1.6.2/Sources/Kitura/TemplatingError.swift /Users/lizziesiegle/Desktop/server/Packages/Kitura-1.6.2/Sources/Kitura/bodyParser/BodyParser.swift /Users/lizziesiegle/Desktop/server/Packages/Kitura-1.6.2/Sources/Kitura/bodyParser/BodyParserProtocol.swift /Users/lizziesiegle/Desktop/server/Packages/Kitura-1.6.2/Sources/Kitura/bodyParser/JSONBodyParser.swift /Users/lizziesiegle/Desktop/server/Packages/Kitura-1.6.2/Sources/Kitura/bodyParser/MultiPartBodyParser.swift /Users/lizziesiegle/Desktop/server/Packages/Kitura-1.6.2/Sources/Kitura/bodyParser/ParsedBody.swift /Users/lizziesiegle/Desktop/server/Packages/Kitura-1.6.2/Sources/Kitura/bodyParser/Part.swift /Users/lizziesiegle/Desktop/server/Packages/Kitura-1.6.2/Sources/Kitura/bodyParser/RawBodyParser.swift /Users/lizziesiegle/Desktop/server/Packages/Kitura-1.6.2/Sources/Kitura/bodyParser/TextBodyParser.swift /Users/lizziesiegle/Desktop/server/Packages/Kitura-1.6.2/Sources/Kitura/bodyParser/URLEncodedBodyParser.swift /Users/lizziesiegle/Desktop/server/Packages/Kitura-1.6.2/Sources/Kitura/contentType/ContentType.swift /Users/lizziesiegle/Desktop/server/Packages/Kitura-1.6.2/Sources/Kitura/contentType/types.swift /Users/lizziesiegle/Desktop/server/Packages/Kitura-1.6.2/Sources/Kitura/staticFileServer/CacheRelatedHeadersSetter.swift /Users/lizziesiegle/Desktop/server/Packages/Kitura-1.6.2/Sources/Kitura/staticFileServer/CompositeHeadersSetter.swift /Users/lizziesiegle/Desktop/server/Packages/Kitura-1.6.2/Sources/Kitura/staticFileServer/FileServer.swift /Users/lizziesiegle/Desktop/server/Packages/Kitura-1.6.2/Sources/Kitura/staticFileServer/ResourcePathHandler.swift /Users/lizziesiegle/Desktop/server/Packages/Kitura-1.6.2/Sources/Kitura/staticFileServer/ResponseHeadersSetter.swift /Users/lizziesiegle/Desktop/server/Packages/Kitura-1.6.2/Sources/Kitura/staticFileServer/StaticFileServer.swift /Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/lib/swift/macosx/x86_64/Swift.swiftmodule /Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/lib/swift/macosx/x86_64/SwiftOnoneSupport.swiftmodule /Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/lib/swift/macosx/x86_64/Foundation.swiftmodule /Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/lib/swift/macosx/x86_64/Darwin.swiftmodule /Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/lib/swift/macosx/x86_64/Dispatch.swiftmodule /Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/lib/swift/macosx/x86_64/ObjectiveC.swiftmodule /Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/lib/swift/macosx/x86_64/CoreGraphics.swiftmodule /Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/lib/swift/macosx/x86_64/IOKit.swiftmodule /Users/lizziesiegle/Desktop/server/DerivedData/server/Build/Products/Debug/LoggerAPI.framework/Modules/LoggerAPI.swiftmodule/x86_64.swiftmodule /Users/lizziesiegle/Desktop/server/DerivedData/server/Build/Products/Debug/KituraNet.framework/Modules/KituraNet.swiftmodule/x86_64.swiftmodule /Users/lizziesiegle/Desktop/server/Packages/Kitura-net-1.6.2/Sources/CHTTPParser/include/module.modulemap /Users/lizziesiegle/Desktop/server/Packages/Kitura-net-1.6.2/Sources/CHTTPParser/include/utils.h /Users/lizziesiegle/Desktop/server/Packages/CCurl-0.2.3/module.modulemap /Users/lizziesiegle/Desktop/server/Packages/Kitura-net-1.6.2/Sources/CHTTPParser/include/http_parser.h /Users/lizziesiegle/Desktop/server/DerivedData/server/Build/Products/Debug/SSLService.framework/Modules/SSLService.swiftmodule/x86_64.swiftmodule /Users/lizziesiegle/Desktop/server/DerivedData/server/Build/Products/Debug/Socket.framework/Modules/Socket.swiftmodule/x86_64.swiftmodule /Users/lizziesiegle/Desktop/server/DerivedData/server/Build/Products/Debug/KituraTemplateEngine.framework/Modules/KituraTemplateEngine.swiftmodule/x86_64.swiftmodule /Users/lizziesiegle/Desktop/server/DerivedData/server/Build/Products/Debug/SwiftyJSON.framework/Modules/SwiftyJSON.swiftmodule/x86_64.swiftmodule
/Users/lizziesiegle/Desktop/server/DerivedData/server/Build/Intermediates/server.build/Debug/Kitura.build/Objects-normal/x86_64/RouterRequest~partial.swiftmodule : /Users/lizziesiegle/Desktop/server/Packages/Kitura-1.6.2/Sources/Kitura/Error.swift /Users/lizziesiegle/Desktop/server/Packages/Kitura-1.6.2/Sources/Kitura/FileResourceServer.swift /Users/lizziesiegle/Desktop/server/Packages/Kitura-1.6.2/Sources/Kitura/Headers.swift /Users/lizziesiegle/Desktop/server/Packages/Kitura-1.6.2/Sources/Kitura/HTTPVersion.swift /Users/lizziesiegle/Desktop/server/Packages/Kitura-1.6.2/Sources/Kitura/InternalError.swift /Users/lizziesiegle/Desktop/server/Packages/Kitura-1.6.2/Sources/Kitura/JSONPError.swift /Users/lizziesiegle/Desktop/server/Packages/Kitura-1.6.2/Sources/Kitura/Kitura.swift /Users/lizziesiegle/Desktop/server/Packages/Kitura-1.6.2/Sources/Kitura/LinkParameter.swift /Users/lizziesiegle/Desktop/server/Packages/Kitura-1.6.2/Sources/Kitura/MimeTypeAcceptor.swift /Users/lizziesiegle/Desktop/server/Packages/Kitura-1.6.2/Sources/Kitura/Router.swift /Users/lizziesiegle/Desktop/server/Packages/Kitura-1.6.2/Sources/Kitura/RouteRegex.swift /Users/lizziesiegle/Desktop/server/Packages/Kitura-1.6.2/Sources/Kitura/RouterElement.swift /Users/lizziesiegle/Desktop/server/Packages/Kitura-1.6.2/Sources/Kitura/RouterElementWalker.swift /Users/lizziesiegle/Desktop/server/Packages/Kitura-1.6.2/Sources/Kitura/RouterHandler.swift /Users/lizziesiegle/Desktop/server/Packages/Kitura-1.6.2/Sources/Kitura/RouterHTTPVerbs+Error.swift /Users/lizziesiegle/Desktop/server/Packages/Kitura-1.6.2/Sources/Kitura/RouterHTTPVerbs_generated.swift /Users/lizziesiegle/Desktop/server/Packages/Kitura-1.6.2/Sources/Kitura/RouterMethod.swift /Users/lizziesiegle/Desktop/server/Packages/Kitura-1.6.2/Sources/Kitura/RouterMiddleware.swift /Users/lizziesiegle/Desktop/server/Packages/Kitura-1.6.2/Sources/Kitura/RouterMiddlewareGenerator.swift /Users/lizziesiegle/Desktop/server/Packages/Kitura-1.6.2/Sources/Kitura/RouterMiddlewareWalker.swift /Users/lizziesiegle/Desktop/server/Packages/Kitura-1.6.2/Sources/Kitura/RouterParameterWalker.swift /Users/lizziesiegle/Desktop/server/Packages/Kitura-1.6.2/Sources/Kitura/RouterRequest.swift /Users/lizziesiegle/Desktop/server/Packages/Kitura-1.6.2/Sources/Kitura/RouterResponse.swift /Users/lizziesiegle/Desktop/server/Packages/Kitura-1.6.2/Sources/Kitura/SSLConfig.swift /Users/lizziesiegle/Desktop/server/Packages/Kitura-1.6.2/Sources/Kitura/String+Extensions.swift /Users/lizziesiegle/Desktop/server/Packages/Kitura-1.6.2/Sources/Kitura/TemplatingError.swift /Users/lizziesiegle/Desktop/server/Packages/Kitura-1.6.2/Sources/Kitura/bodyParser/BodyParser.swift /Users/lizziesiegle/Desktop/server/Packages/Kitura-1.6.2/Sources/Kitura/bodyParser/BodyParserProtocol.swift /Users/lizziesiegle/Desktop/server/Packages/Kitura-1.6.2/Sources/Kitura/bodyParser/JSONBodyParser.swift /Users/lizziesiegle/Desktop/server/Packages/Kitura-1.6.2/Sources/Kitura/bodyParser/MultiPartBodyParser.swift /Users/lizziesiegle/Desktop/server/Packages/Kitura-1.6.2/Sources/Kitura/bodyParser/ParsedBody.swift /Users/lizziesiegle/Desktop/server/Packages/Kitura-1.6.2/Sources/Kitura/bodyParser/Part.swift /Users/lizziesiegle/Desktop/server/Packages/Kitura-1.6.2/Sources/Kitura/bodyParser/RawBodyParser.swift /Users/lizziesiegle/Desktop/server/Packages/Kitura-1.6.2/Sources/Kitura/bodyParser/TextBodyParser.swift /Users/lizziesiegle/Desktop/server/Packages/Kitura-1.6.2/Sources/Kitura/bodyParser/URLEncodedBodyParser.swift /Users/lizziesiegle/Desktop/server/Packages/Kitura-1.6.2/Sources/Kitura/contentType/ContentType.swift /Users/lizziesiegle/Desktop/server/Packages/Kitura-1.6.2/Sources/Kitura/contentType/types.swift /Users/lizziesiegle/Desktop/server/Packages/Kitura-1.6.2/Sources/Kitura/staticFileServer/CacheRelatedHeadersSetter.swift /Users/lizziesiegle/Desktop/server/Packages/Kitura-1.6.2/Sources/Kitura/staticFileServer/CompositeHeadersSetter.swift /Users/lizziesiegle/Desktop/server/Packages/Kitura-1.6.2/Sources/Kitura/staticFileServer/FileServer.swift /Users/lizziesiegle/Desktop/server/Packages/Kitura-1.6.2/Sources/Kitura/staticFileServer/ResourcePathHandler.swift /Users/lizziesiegle/Desktop/server/Packages/Kitura-1.6.2/Sources/Kitura/staticFileServer/ResponseHeadersSetter.swift /Users/lizziesiegle/Desktop/server/Packages/Kitura-1.6.2/Sources/Kitura/staticFileServer/StaticFileServer.swift /Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/lib/swift/macosx/x86_64/Swift.swiftmodule /Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/lib/swift/macosx/x86_64/SwiftOnoneSupport.swiftmodule /Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/lib/swift/macosx/x86_64/Foundation.swiftmodule /Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/lib/swift/macosx/x86_64/Darwin.swiftmodule /Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/lib/swift/macosx/x86_64/Dispatch.swiftmodule /Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/lib/swift/macosx/x86_64/ObjectiveC.swiftmodule /Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/lib/swift/macosx/x86_64/CoreGraphics.swiftmodule /Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/lib/swift/macosx/x86_64/IOKit.swiftmodule /Users/lizziesiegle/Desktop/server/DerivedData/server/Build/Products/Debug/LoggerAPI.framework/Modules/LoggerAPI.swiftmodule/x86_64.swiftmodule /Users/lizziesiegle/Desktop/server/DerivedData/server/Build/Products/Debug/KituraNet.framework/Modules/KituraNet.swiftmodule/x86_64.swiftmodule /Users/lizziesiegle/Desktop/server/Packages/Kitura-net-1.6.2/Sources/CHTTPParser/include/module.modulemap /Users/lizziesiegle/Desktop/server/Packages/Kitura-net-1.6.2/Sources/CHTTPParser/include/utils.h /Users/lizziesiegle/Desktop/server/Packages/CCurl-0.2.3/module.modulemap /Users/lizziesiegle/Desktop/server/Packages/Kitura-net-1.6.2/Sources/CHTTPParser/include/http_parser.h /Users/lizziesiegle/Desktop/server/DerivedData/server/Build/Products/Debug/SSLService.framework/Modules/SSLService.swiftmodule/x86_64.swiftmodule /Users/lizziesiegle/Desktop/server/DerivedData/server/Build/Products/Debug/Socket.framework/Modules/Socket.swiftmodule/x86_64.swiftmodule /Users/lizziesiegle/Desktop/server/DerivedData/server/Build/Products/Debug/KituraTemplateEngine.framework/Modules/KituraTemplateEngine.swiftmodule/x86_64.swiftmodule /Users/lizziesiegle/Desktop/server/DerivedData/server/Build/Products/Debug/SwiftyJSON.framework/Modules/SwiftyJSON.swiftmodule/x86_64.swiftmodule
/Users/lizziesiegle/Desktop/server/DerivedData/server/Build/Intermediates/server.build/Debug/Kitura.build/Objects-normal/x86_64/RouterRequest~partial.swiftdoc : /Users/lizziesiegle/Desktop/server/Packages/Kitura-1.6.2/Sources/Kitura/Error.swift /Users/lizziesiegle/Desktop/server/Packages/Kitura-1.6.2/Sources/Kitura/FileResourceServer.swift /Users/lizziesiegle/Desktop/server/Packages/Kitura-1.6.2/Sources/Kitura/Headers.swift /Users/lizziesiegle/Desktop/server/Packages/Kitura-1.6.2/Sources/Kitura/HTTPVersion.swift /Users/lizziesiegle/Desktop/server/Packages/Kitura-1.6.2/Sources/Kitura/InternalError.swift /Users/lizziesiegle/Desktop/server/Packages/Kitura-1.6.2/Sources/Kitura/JSONPError.swift /Users/lizziesiegle/Desktop/server/Packages/Kitura-1.6.2/Sources/Kitura/Kitura.swift /Users/lizziesiegle/Desktop/server/Packages/Kitura-1.6.2/Sources/Kitura/LinkParameter.swift /Users/lizziesiegle/Desktop/server/Packages/Kitura-1.6.2/Sources/Kitura/MimeTypeAcceptor.swift /Users/lizziesiegle/Desktop/server/Packages/Kitura-1.6.2/Sources/Kitura/Router.swift /Users/lizziesiegle/Desktop/server/Packages/Kitura-1.6.2/Sources/Kitura/RouteRegex.swift /Users/lizziesiegle/Desktop/server/Packages/Kitura-1.6.2/Sources/Kitura/RouterElement.swift /Users/lizziesiegle/Desktop/server/Packages/Kitura-1.6.2/Sources/Kitura/RouterElementWalker.swift /Users/lizziesiegle/Desktop/server/Packages/Kitura-1.6.2/Sources/Kitura/RouterHandler.swift /Users/lizziesiegle/Desktop/server/Packages/Kitura-1.6.2/Sources/Kitura/RouterHTTPVerbs+Error.swift /Users/lizziesiegle/Desktop/server/Packages/Kitura-1.6.2/Sources/Kitura/RouterHTTPVerbs_generated.swift /Users/lizziesiegle/Desktop/server/Packages/Kitura-1.6.2/Sources/Kitura/RouterMethod.swift /Users/lizziesiegle/Desktop/server/Packages/Kitura-1.6.2/Sources/Kitura/RouterMiddleware.swift /Users/lizziesiegle/Desktop/server/Packages/Kitura-1.6.2/Sources/Kitura/RouterMiddlewareGenerator.swift /Users/lizziesiegle/Desktop/server/Packages/Kitura-1.6.2/Sources/Kitura/RouterMiddlewareWalker.swift /Users/lizziesiegle/Desktop/server/Packages/Kitura-1.6.2/Sources/Kitura/RouterParameterWalker.swift /Users/lizziesiegle/Desktop/server/Packages/Kitura-1.6.2/Sources/Kitura/RouterRequest.swift /Users/lizziesiegle/Desktop/server/Packages/Kitura-1.6.2/Sources/Kitura/RouterResponse.swift /Users/lizziesiegle/Desktop/server/Packages/Kitura-1.6.2/Sources/Kitura/SSLConfig.swift /Users/lizziesiegle/Desktop/server/Packages/Kitura-1.6.2/Sources/Kitura/String+Extensions.swift /Users/lizziesiegle/Desktop/server/Packages/Kitura-1.6.2/Sources/Kitura/TemplatingError.swift /Users/lizziesiegle/Desktop/server/Packages/Kitura-1.6.2/Sources/Kitura/bodyParser/BodyParser.swift /Users/lizziesiegle/Desktop/server/Packages/Kitura-1.6.2/Sources/Kitura/bodyParser/BodyParserProtocol.swift /Users/lizziesiegle/Desktop/server/Packages/Kitura-1.6.2/Sources/Kitura/bodyParser/JSONBodyParser.swift /Users/lizziesiegle/Desktop/server/Packages/Kitura-1.6.2/Sources/Kitura/bodyParser/MultiPartBodyParser.swift /Users/lizziesiegle/Desktop/server/Packages/Kitura-1.6.2/Sources/Kitura/bodyParser/ParsedBody.swift /Users/lizziesiegle/Desktop/server/Packages/Kitura-1.6.2/Sources/Kitura/bodyParser/Part.swift /Users/lizziesiegle/Desktop/server/Packages/Kitura-1.6.2/Sources/Kitura/bodyParser/RawBodyParser.swift /Users/lizziesiegle/Desktop/server/Packages/Kitura-1.6.2/Sources/Kitura/bodyParser/TextBodyParser.swift /Users/lizziesiegle/Desktop/server/Packages/Kitura-1.6.2/Sources/Kitura/bodyParser/URLEncodedBodyParser.swift /Users/lizziesiegle/Desktop/server/Packages/Kitura-1.6.2/Sources/Kitura/contentType/ContentType.swift /Users/lizziesiegle/Desktop/server/Packages/Kitura-1.6.2/Sources/Kitura/contentType/types.swift /Users/lizziesiegle/Desktop/server/Packages/Kitura-1.6.2/Sources/Kitura/staticFileServer/CacheRelatedHeadersSetter.swift /Users/lizziesiegle/Desktop/server/Packages/Kitura-1.6.2/Sources/Kitura/staticFileServer/CompositeHeadersSetter.swift /Users/lizziesiegle/Desktop/server/Packages/Kitura-1.6.2/Sources/Kitura/staticFileServer/FileServer.swift /Users/lizziesiegle/Desktop/server/Packages/Kitura-1.6.2/Sources/Kitura/staticFileServer/ResourcePathHandler.swift /Users/lizziesiegle/Desktop/server/Packages/Kitura-1.6.2/Sources/Kitura/staticFileServer/ResponseHeadersSetter.swift /Users/lizziesiegle/Desktop/server/Packages/Kitura-1.6.2/Sources/Kitura/staticFileServer/StaticFileServer.swift /Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/lib/swift/macosx/x86_64/Swift.swiftmodule /Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/lib/swift/macosx/x86_64/SwiftOnoneSupport.swiftmodule /Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/lib/swift/macosx/x86_64/Foundation.swiftmodule /Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/lib/swift/macosx/x86_64/Darwin.swiftmodule /Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/lib/swift/macosx/x86_64/Dispatch.swiftmodule /Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/lib/swift/macosx/x86_64/ObjectiveC.swiftmodule /Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/lib/swift/macosx/x86_64/CoreGraphics.swiftmodule /Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/lib/swift/macosx/x86_64/IOKit.swiftmodule /Users/lizziesiegle/Desktop/server/DerivedData/server/Build/Products/Debug/LoggerAPI.framework/Modules/LoggerAPI.swiftmodule/x86_64.swiftmodule /Users/lizziesiegle/Desktop/server/DerivedData/server/Build/Products/Debug/KituraNet.framework/Modules/KituraNet.swiftmodule/x86_64.swiftmodule /Users/lizziesiegle/Desktop/server/Packages/Kitura-net-1.6.2/Sources/CHTTPParser/include/module.modulemap /Users/lizziesiegle/Desktop/server/Packages/Kitura-net-1.6.2/Sources/CHTTPParser/include/utils.h /Users/lizziesiegle/Desktop/server/Packages/CCurl-0.2.3/module.modulemap /Users/lizziesiegle/Desktop/server/Packages/Kitura-net-1.6.2/Sources/CHTTPParser/include/http_parser.h /Users/lizziesiegle/Desktop/server/DerivedData/server/Build/Products/Debug/SSLService.framework/Modules/SSLService.swiftmodule/x86_64.swiftmodule /Users/lizziesiegle/Desktop/server/DerivedData/server/Build/Products/Debug/Socket.framework/Modules/Socket.swiftmodule/x86_64.swiftmodule /Users/lizziesiegle/Desktop/server/DerivedData/server/Build/Products/Debug/KituraTemplateEngine.framework/Modules/KituraTemplateEngine.swiftmodule/x86_64.swiftmodule /Users/lizziesiegle/Desktop/server/DerivedData/server/Build/Products/Debug/SwiftyJSON.framework/Modules/SwiftyJSON.swiftmodule/x86_64.swiftmodule
| D |
/*
Copyright (c) 1996 Blake McBride
All rights reserved.
Redistribution and use in source and binary forms, with or without
modification, are permitted provided that the following conditions are
met:
1. Redistributions of source code must retain the above copyright
notice, this list of conditions and the following disclaimer.
2. Redistributions in binary form must reproduce the above copyright
notice, this list of conditions and the following disclaimer in the
documentation and/or other materials provided with the distribution.
THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS
"AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT
LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR
A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT
HOLDER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,
DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY
THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
(INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE
OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
*/
#include <math.h>
defclass IntegerAssociation : Association {
int iKey;
iValue;
};
cmeth gNewWithIntObj, <vNew> (int key, value)
{
object assoc;
ivType *iv;
ChkArgNul(value, 3);
assoc = gNew(super);
iv = ivPtr(assoc);
iKey = key;
iValue = value;
return assoc;
}
imeth gDeepCopy()
{
object nobj;
nobj = gDeepCopy(super);
ivPtr(nobj)->iValue = iValue ? gDeepCopy(iValue) : NULL;
return nobj;
}
imeth gValue()
{
return iValue;
}
imeth gChangeValue(value)
{
object ret;
ChkArgNul(value, 2);
ret = iValue;
iValue = value;
return ret;
}
imeth int gIntKey()
{
return iKey;
}
imeth gChangeIntKey(int key)
{
iKey = key;
return self;
}
imeth object gDeepDispose()
{
if (iValue)
gDeepDispose(iValue);
return gDispose(super);
}
imeth gStringRepValue()
{
object s, t;
t = iValue ? gStringRepValue(iValue) : gNewWithStr(String, "(null)");
s = vSprintf(String, "( %d, ", iKey);
vBuild(s, NULL, t, " )", NULL);
gDispose(t);
return s;
}
imeth int gHash()
{
double t;
t = .6125423371 * (unsigned) iKey;
t = t < 0.0 ? -t : t;
return (int) (BIG_INT * (t - floor(t)));
}
imeth int gCompare(arg)
{
int sv, ov;
ChkArg(arg, 2);
if ((sv=iKey) < (ov=gIntKey(arg)))
return -1;
else if (sv == ov)
return 0;
else
return 1;
}
| D |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.