Skip to content
This repository has been archived by the owner on Apr 22, 2019. It is now read-only.

Commit

Permalink
Docs update
Browse files Browse the repository at this point in the history
  • Loading branch information
Oleh Kulykov committed Mar 20, 2017
1 parent 7b76fd7 commit 0bc12ac
Show file tree
Hide file tree
Showing 8 changed files with 45 additions and 45 deletions.
2 changes: 1 addition & 1 deletion .travis.yml
Original file line number Diff line number Diff line change
Expand Up @@ -28,7 +28,7 @@ before_script:
# - rm ndk.tar
# - cd ..
- cd build
- cmake -DCMAKE_INSTALL_PREFIX:PATH=~/fayecpp-install-dir -DCMAKE_BUILD_TYPE=Release -DFAYECPP_BUILD_NUMBER=$TRAVIS_BUILD_NUMBER ..
- cmake -DCMAKE_INSTALL_PREFIX:PATH=~/fayecpp-install-dir -DCMAKE_BUILD_TYPE=Release -DLWS_WITH_SSL:BOOL=OFF -DFAYECPP_BUILD_NUMBER=$TRAVIS_BUILD_NUMBER ..
- cd ..

script:
Expand Down
6 changes: 5 additions & 1 deletion CHANGELOG
Original file line number Diff line number Diff line change
@@ -1,4 +1,8 @@
Changes on version 1.2.0 (current):
Changes on version 1.2.1 (current):
- Update Libwebsockets to version 2.1.1.
- Update jansson to version 2.10.

Changes on version 1.2.0:
- Update Libwebsockets to version 2.0.0.
- Update jansson to version 2.8.
- Update client info message.
Expand Down
2 changes: 1 addition & 1 deletion CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -33,7 +33,7 @@ set(CPACK_PACKAGE_VERSION_MINOR "2")
set(CPACK_PACKAGE_VERSION "${CPACK_PACKAGE_VERSION_MAJOR}.${CPACK_PACKAGE_VERSION_MINOR}")
set(CPACK_PACKAGE_VENDOR "[email protected]")
set(CPACK_PACKAGE_DESCRIPTION_SUMMARY "${PACKAGE} ${PACKAGE_VERSION}")
set(SOVERSION "1.2.0")
set(SOVERSION "1.2.1")
set(CPACK_SOURCE_PACKAGE_FILE_NAME "${CPACK_PACKAGE_NAME}-${CPACK_PACKAGE_VERSION}")
set(VERSION "${CPACK_PACKAGE_VERSION}")

Expand Down
2 changes: 1 addition & 1 deletion FayeCpp.podspec
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@ Pod::Spec.new do |s|

# Common settings
s.name = "FayeCpp"
s.version = "1.2.0"
s.version = "1.2.1"
s.summary = "Faye C++ lightweight, cross-platform client with Objective-C client wrapper."
s.description = <<-DESC
Faye C++ lightweight, cross-platform client with Objective-C client wrapper.
Expand Down
2 changes: 1 addition & 1 deletion LICENSE
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
The MIT License (MIT)

Copyright (c) 2014 - 2016 Kulykov Oleh <[email protected]>
Copyright (c) 2014 - 2017 Kulykov Oleh <[email protected]>

Permission is hereby granted, free of charge, to any person obtaining a copy
of this software and associated documentation files (the "Software"), to deal
Expand Down
68 changes: 30 additions & 38 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -206,45 +206,39 @@ using namespace FayeCpp;
### Client delegate
```cpp
class FayeDelegate : public FayeCpp::Delegate
{
class FayeDelegate : public FayeCpp::Delegate {
public:
// override all FayeCpp::Delegate methods.
virtual void onFayeTransportConnected(FayeCpp::Client * client)
{
virtual void onFayeTransportConnected(FayeCpp::Client * client) {
// ....
}
virtual void onFayeClientReceivedMessageFromChannel(FayeCpp::Client * client,
const FayeCpp::REVariantMap & message,
const FayeCpp::REString & channel)
{
}
virtual void onFayeClientReceivedMessageFromChannel(FayeCpp::Client * client,
const FayeCpp::REVariantMap & message,
const FayeCpp::REString & channel) {
// Print channel which received message
RELog::log("Received message from channel: \"%s\"", channel.UTF8String());
// Iterate all message (VariantMap) pairs
REVariantMap::Iterator iterator = message.iterator();
while (iterator.next())
{
iterator.key(); // get key
iterator.value(); // get value for key
}
// .....
}
RELog::log("Received message from channel: \"%s\"", channel.UTF8String());
// Iterate all message (VariantMap) pairs
REVariantMap::Iterator iterator = message.iterator();
while (iterator.next()) {
iterator.key(); // get key
iterator.value(); // get value for key
}
// .....
}
// overide other methods
FayeDelegate()
{
FayeDelegate() {
// .....
}
virtual ~FayeDelegate()
{
virtual ~FayeDelegate() {
// ......
}
}
};
```
Expand Down Expand Up @@ -347,16 +341,14 @@ self.client = [[FayeCppClient alloc] init];
```objective-c
#pragma mark - FayeCpp client delegate
- (void) onFayeClientConnected:(FayeCppClient *) client
{
NSLog(@"On faye client connected");
- (void) onFayeClientConnected:(FayeCppClient *) client {
NSLog(@"On faye client connected");
}
- (void) onFayeClient:(FayeCppClient *) client
receivedMessage:(NSDictionary *) message
fromChannel:(NSString *) channel
{
NSLog(@"On faye client received message: \n%@ \nfrom channel: %@", message, channel);
receivedMessage:(NSDictionary *) message
fromChannel:(NSString *) channel {
NSLog(@"On faye client received message: \n%@ \nfrom channel: %@", message, channel);
}
// implement other delegate messages if needed ...
```
Expand All @@ -380,7 +372,7 @@ self.client = [[FayeCppClient alloc] init];
```objective-c
[_client sendMessage:@{@"text" : @"Hello world", @"other_params" : @[]}
toChannel:@"/faye_channel_1"];
toChannel:@"/faye_channel_1"];
```
Expand Down
2 changes: 1 addition & 1 deletion appveyor.yml
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
version: 1.2.0.{build}
version: 1.2.1.{build}


os: Visual Studio 2015
Expand Down
6 changes: 5 additions & 1 deletion fayecpp.h
Original file line number Diff line number Diff line change
Expand Up @@ -29,6 +29,10 @@
* Faye C++ client main and one header file.
* All class interfaces added to namespace, preventing include files mess(yes, this is unusual structure, but lightweight).
*
* Changes on version 1.2.1 (current):
* - Update Libwebsockets to version 2.1.1.
* - Update jansson to version 2.10.
*
* Changes on version 1.2.0 (current):
* - Update Libwebsockets to version 2.0.0.
* - Update jansson to version 2.8.
Expand Down Expand Up @@ -143,7 +147,7 @@

#define FAYECPP_VERSION_MAJOR 1
#define FAYECPP_VERSION_MINOR 2
#define FAYECPP_VERSION_PATCH 0
#define FAYECPP_VERSION_PATCH 1


#if !defined(HAVE_SUITABLE_QT_VERSION)
Expand Down

0 comments on commit 0bc12ac

Please sign in to comment.