Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

(Partial) TIMOB-9543: BlackBerry: Implement BufferStream #133

Merged
merged 3 commits into from Aug 16, 2012

Conversation

dlifshitz-maca
Copy link

Reviewer: Harut

[Issues Fixed]
(Partial) TIMOB-9543: BlackBerry: Implement BufferStream
(Partial) TIMOB-10257: BlackBerry: Implement Titanium.IOStream

[Added]
TiBufferStreamObject.cpp
TiBufferStreamObject.h
TiIOStreamObject.cpp
TiIOStreamObject.h
TiStreamObject.cpp
TiStreamObject.h

[Changes]
TiTitaniumObject.cpp
- function onCreateStaticMembers
  - add TiBufferStreamObject and TiStreamObject

bootstrap.js
- add temporary code to show how to add a function to the API using JavaScript

[Tests]
Test 1: Test new JavaScript function
var bs = Ti.Stream.createStream();
bs.demoFunc();

Expected: Should print the following:
[DEBUG]:demoFunc is being run

[Issues Fixed]
(Partial) TIMOB-9543: BlackBerry: Implement BufferStream
(Partial) TIMOB-10257: BlackBerry: Implement Titanium.IOStream

[Added]
TiBufferStreamObject.cpp
TiBufferStreamObject.h
TiIOStreamObject.cpp
TiIOStreamObject.h
TiStreamObject.cpp
TiStreamObject.h

[Changes]
TiTitaniumObject.cpp
- function onCreateStaticMembers
  - add TiBufferStreamObject and TiStreamObject

bootstrap.js
- add temporary code to show how to add a function to the API using JavaScript

[Tests]
Test 1: Test new JavaScript function
var bs = Ti.Stream.createStream();
bs.demoFunc();

Expected: Should print the following:
[DEBUG]:demoFunc is being run
}

Handle<Value> TiStreamObject::_createStream(void* /*userContext*/, TiObject* /*caller*/, const Arguments& args)
{

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

according to documentation , creatStream should take one and only one argument, do we need to check it here?

Copy link
Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This will be done in a later PR.

@Harutyun
Copy link

Is it what we need to make anvil run? (don't we need to implement functions, properties for buffersstream and iostream in this jira task?)

@Harutyun
Copy link

Reviewed

@dlifshitz-maca
Copy link
Author

This is just a partial patch. the functions, etc will come later in another PR.
Also, IOStream is just an interface but there's nothing to define since virtual functions are not the same in JS.

(Partial) TIMOB-10257: BlackBerry: Implement Titanium.IOStream

updated apidoc
fixed onCreateStaticMembers calls in TiBufferStreamObject and TiIOStreamObject
@dlifshitz-maca
Copy link
Author

Updated patch for apidoc and onCreateStaticMembers

@Harutyun
Copy link

Approved

Conflicts:
	blackberry/tibb/TiTitaniumObject.cpp
dlifshitz-maca added a commit that referenced this pull request Aug 16, 2012
(Partial) TIMOB-9543: BlackBerry: Implement BufferStream
@dlifshitz-maca dlifshitz-maca merged commit ae59e69 into Macadamian:blackberry Aug 16, 2012
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
2 participants