This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#include <iostream> | |
#include <vector> | |
#include <queue> | |
#include <string> | |
using namespace std; | |
struct door{ | |
int _x; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#include <iostream> | |
#include <vector> | |
#include <queue> | |
#include <string> | |
using namespace std; | |
int main(int argc, char **argv) { |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
syntax = "Proto3"; | |
package Tutorial; | |
message Person { | |
string name = 1; | |
int32 id = 2; | |
string email = 3; | |
} | |
enum PhoneType { | |
MOBILE = 0; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#include <iostream> | |
#include <fstream> | |
#include <string> | |
#include "addressbook.pb.h" | |
using namespace std; | |
void PromptForAddress(protobuf_example::Person * person) | |
{ | |
cout << "Enter person ID number: "; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#include <iostream> | |
#include <fstream> | |
#include <string> | |
#include "addressbook.pb.h" | |
using namespace std; | |
void ListPeople( const protobuf_example::AddressBook& _address_book) | |
{ |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
android { | |
... | |
dataBinding { | |
enabled = true | |
} | |
} | |
dependecies { | |
... |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<?xml version="1.0" encoding="utf-8"?> | |
<layout xmlns:android="http://schemas.android.com/apk/res/android" | |
xmlns:tools="http://schemas.android.com/tools"> | |
<data> | |
<variable | |
name="user" | |
type="com.example.fabio.databind.Person" /> | |
</data> | |
<LinearLayout | |
android:orientation="vertical" |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
package com.example.fabio.databind | |
import android.databinding.DataBindingUtil | |
import android.support.v7.app.AppCompatActivity | |
import android.os.Bundle | |
import com.example.fabio.databind.databinding.ActivityMainBinding | |
class MainActivity : AppCompatActivity() { |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#ifndef __ENTRYPOINT_H_ | |
#define __ENTRYPOINT_H_ | |
extern "C" | |
{ | |
DECLSPEC bool StartDLL(); | |
DECLSPEC bool StopDLL(); | |
DECLSPEC bool InjectMock(void *mock); | |
} | |
#endif |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Service *pService = NULL; | |
DECLSPEC bool StartDLL() | |
{ | |
bool ret = true; | |
if(!pService) | |
{ | |
if(!(pService = Service::getInstance())) | |
{ | |
ret = false; |
OlderNewer