Reactive programming models asynchronous data streams as signals that produce events over time. ReactiveCocoa is a framework that implements reactive programming in Objective-C. It uses signals to represent asynchronous data streams and operators to transform and combine signals. ReactiveCocoa code separates the logic to produce and consume data, making it more modular, reusable, testable and by reducing state and mutability. While the syntax is different, learning to think reactively can improve code quality and stability.
En vieux bourlingueur du langage Swift, Grégoire Lhotellier viendra nous présenter les séquences et les collections du nouveau langage d’Apple. Il nous briefera sur l’essentiel de ce qu’il faut en savoir et ce qu’elles changent par rapport à leurs équivalent Objective-C.
Donner le goût du ReactiveCocoa. L’objectif de la présentation étant de nous expliquer comment migrer du code lié au KVO vers une implémentation ReactiveCocoa. Cette approche du KVO par ReactiveCocoa permet de comprendre très facilement les bases et l’intérêt de ce nouveau framework et de s’y mettre facilement et progressivement.
Un talk sur Realm, nom d’une startup Californienne qui publie un framework éponyme de persistence de données. Venez découvrir ce framework et vous changerez (à jamais) votre façon de concevoir la persistence de données.
This talk was given at JSSummit 2013. Entitled "Avoiding Callback Hell with Async.js", my talk focused on common pitfalls with asynchronous functions and callbacks in JavaScript, and using the async.js library and its advanced control flows to create cleaner, more manageable code.
This is my talk on ReactiveCocoa at @cocoaheads_at in Vienna. I gave an introduction to reactive programming with RAC and an overview of signals and subscribers, and how they can be used to create useful patterns.
A few slides about asynchrnous programming in Node, from callback hell to control flows using promises, thunks and generators, providing the right amount of abstraction to write great code.
All examples available on https://github.com/troch/node-control-flow.
Presented at YOW! Connected 2015 (Melbourne) by Jeames Bone & Mark Corbyn:
"There are many great resources for getting started with Functional Reactive Programming and ReactiveCocoa, but what’s the next step? ReactiveCocoa is not just a nice wrapper for KVO, Signals can be used to model many common problems in Cocoa including managing the state of your UI, notifications and even business logic. Adopting ReactiveCocoa can make for more modular, self-documenting code — while still integrating easily with other APIs and your existing code. We would like to share with you some interesting, practical examples where we’ve used ReactiveCocoa to solve problems in our app. Our goal is to inspire you to consider how ReactiveCocoa can be applied in your own apps."
En vieux bourlingueur du langage Swift, Grégoire Lhotellier viendra nous présenter les séquences et les collections du nouveau langage d’Apple. Il nous briefera sur l’essentiel de ce qu’il faut en savoir et ce qu’elles changent par rapport à leurs équivalent Objective-C.
Donner le goût du ReactiveCocoa. L’objectif de la présentation étant de nous expliquer comment migrer du code lié au KVO vers une implémentation ReactiveCocoa. Cette approche du KVO par ReactiveCocoa permet de comprendre très facilement les bases et l’intérêt de ce nouveau framework et de s’y mettre facilement et progressivement.
Un talk sur Realm, nom d’une startup Californienne qui publie un framework éponyme de persistence de données. Venez découvrir ce framework et vous changerez (à jamais) votre façon de concevoir la persistence de données.
This talk was given at JSSummit 2013. Entitled "Avoiding Callback Hell with Async.js", my talk focused on common pitfalls with asynchronous functions and callbacks in JavaScript, and using the async.js library and its advanced control flows to create cleaner, more manageable code.
This is my talk on ReactiveCocoa at @cocoaheads_at in Vienna. I gave an introduction to reactive programming with RAC and an overview of signals and subscribers, and how they can be used to create useful patterns.
A few slides about asynchrnous programming in Node, from callback hell to control flows using promises, thunks and generators, providing the right amount of abstraction to write great code.
All examples available on https://github.com/troch/node-control-flow.
Presented at YOW! Connected 2015 (Melbourne) by Jeames Bone & Mark Corbyn:
"There are many great resources for getting started with Functional Reactive Programming and ReactiveCocoa, but what’s the next step? ReactiveCocoa is not just a nice wrapper for KVO, Signals can be used to model many common problems in Cocoa including managing the state of your UI, notifications and even business logic. Adopting ReactiveCocoa can make for more modular, self-documenting code — while still integrating easily with other APIs and your existing code. We would like to share with you some interesting, practical examples where we’ve used ReactiveCocoa to solve problems in our app. Our goal is to inspire you to consider how ReactiveCocoa can be applied in your own apps."
The fundamentals and advance application of Node will be covered. We will explore the design choices that make Node.js unique, how this changes the way applications are built and how systems of applications work most effectively in this model. You will learn how to create modular code that’s robust, expressive and clear. Understand when to use callbacks, event emitters and streams.
Presentation I gave to the node.dc meetup group March 13, 2013 on using Promises and the Q library to make flow of control easier to reason about in Javascript code using async and callbacks
All you need to know about the JavaScript event loopSaša Tatar
Learn the difference between JavaScript Engine, JavaScript Runtime, what is JavaScript event loop and why we should care.
At the end the presentation goes through a couple of examples and implementations of throttle and debounce utility functions.
The next version of JavaScript, ES6, is starting to arrive. Many of its features are simple enhancements to the language we already have: things like arrow functions, class syntax, and destructuring. But other features will change the way we program JavaScript, fundamentally expanding the capabilities of the language and reshaping our future codebases. In this talk we'll focus on two of these, discovering the the myriad possibilities of generators and the many tricks you can pull of with template strings.
ReactiveCocoa is an elegant framework that radically changes the way we structure our applications and handle flows of data. However, it's beauty is somewhat marred by Objective-C!
In this talk Colin will cover the basics of ReactiveCocoa and the principles of Functional Reactive Programming. Through simple practical examples he will show how ReactiveCocoa and Swift form a beautiful partnership.
Most AWS APIs will have limits on the amount of data you can send in one request and sometimes you really need to send a lot of data! To try to maximise the amount of data you can send, while still staying within the limits, some APIs support sending gzip-compressed payloads. But how can you send a gzipped request when using the Python SDK for AWS (boto3)? Well, I needed to answer this question recently and it turned out not to be as easy as I anticipated… Let’s jump into this rabbit hole together and let’s find out the answer!
Reactive Programming Patterns with RxSwiftFlorent Pillet
In this introduction to reactive programming and RxSwift you'll learn how common problems are solved in a reactive way to improve your architecture and write more reliable code.
ECMAScript is the name of the international standard that defines JavaScript. ES6 → ECMAScript 2015. Latest ECMAScript version is ES7 which is ECMAScript 2016.
Basically it is a superset of es5
The fundamentals and advance application of Node will be covered. We will explore the design choices that make Node.js unique, how this changes the way applications are built and how systems of applications work most effectively in this model. You will learn how to create modular code that’s robust, expressive and clear. Understand when to use callbacks, event emitters and streams.
Presentation I gave to the node.dc meetup group March 13, 2013 on using Promises and the Q library to make flow of control easier to reason about in Javascript code using async and callbacks
All you need to know about the JavaScript event loopSaša Tatar
Learn the difference between JavaScript Engine, JavaScript Runtime, what is JavaScript event loop and why we should care.
At the end the presentation goes through a couple of examples and implementations of throttle and debounce utility functions.
The next version of JavaScript, ES6, is starting to arrive. Many of its features are simple enhancements to the language we already have: things like arrow functions, class syntax, and destructuring. But other features will change the way we program JavaScript, fundamentally expanding the capabilities of the language and reshaping our future codebases. In this talk we'll focus on two of these, discovering the the myriad possibilities of generators and the many tricks you can pull of with template strings.
ReactiveCocoa is an elegant framework that radically changes the way we structure our applications and handle flows of data. However, it's beauty is somewhat marred by Objective-C!
In this talk Colin will cover the basics of ReactiveCocoa and the principles of Functional Reactive Programming. Through simple practical examples he will show how ReactiveCocoa and Swift form a beautiful partnership.
Most AWS APIs will have limits on the amount of data you can send in one request and sometimes you really need to send a lot of data! To try to maximise the amount of data you can send, while still staying within the limits, some APIs support sending gzip-compressed payloads. But how can you send a gzipped request when using the Python SDK for AWS (boto3)? Well, I needed to answer this question recently and it turned out not to be as easy as I anticipated… Let’s jump into this rabbit hole together and let’s find out the answer!
Reactive Programming Patterns with RxSwiftFlorent Pillet
In this introduction to reactive programming and RxSwift you'll learn how common problems are solved in a reactive way to improve your architecture and write more reliable code.
ECMAScript is the name of the international standard that defines JavaScript. ES6 → ECMAScript 2015. Latest ECMAScript version is ES7 which is ECMAScript 2016.
Basically it is a superset of es5
Did we all around the globe sit down together and decide to follow Capitalism? Was Capitalism in the same form since beginning than now? In fact, it would be unrealistic to say that we decided to pick Capitalism. We just derived into it. And the concepts, forms and philosophy of Capitalism evolved over time.
.........................
Dr. Alan Greenspan, Lawrence
Summers from Harvard, Austan Goolgbee, US President’s Council of Economic Advisors are few of the thinks tanks attending the gathering (October 2011).
...................
How is then the New of Form of Capitalism going to shape like? If we recollect from the beginning paragraph, we notice, one of the major advantages of Capitalism was conceived to be “Less Control of Government over markets”. The New Capitalism is believed to start changing its current hue from this point.
............................
Why would Formative Capitalism would survive during recession and depressions? And why should we believe that to? The simplest reason is: because the performance of Formative Capitalists
isn’t just countercyclical, skyrocketing during the downturn and then collapsing.
NCrafts.IO 2015 - Future of User eXperiencesVincent Guigui
Kinect, Oculus, Holograms, Wearables, Smart Objects...
Over the past few years, we have seen a rise of the new devices and sensors coming to our everyday life.
This session will explain the principles of interfaces, what is innovation and how to use these new devices to create more natural and more personal computing experiences by blurring the line between our world and the digital one.
Video available on NCrafts Vimeo Channel: https://vimeo.com/131932860
Breathtaking in every sense of the word, nothing signals your arrival like the Predator 68. Piercing through waves with ease, its exhilarating performance is matched only by its unmistakable styling.
Exquisite interior options and captivating design are prominent throughout the entire yacht - a classic example of Sunseeker design ingenuity. The extravagant sliding roof adds a sense of occasion to every journey. Built to both thrill and inspire, you can’t help but fall for this symbol of success.
C++ is a middle-level programming language developed by Bjarne Stroustrup starting in 1979 at Bell Labs. C++ runs on a variety of platforms, such as Windows, Mac OS, and the various versions of UNIX.
This reference will take you through simple and practical approach while learning C++ Programming language.
eact is a library for building HTML user interfaces. It is the "view" in a Model-View-Controller application. Created by the UI wizards at Facebook, top websites like Instagram, Netflix, Airbnb, Bleacher Report and Feedly use it. React is the 6th most starred project on GitHub and grows more popular every day.
In this two-day workshop, we will introduce you to React. On the first day, we will work through a series of increasingly more complicated tutorial exercises. Along the way, we will explain concepts like JSX, immutability, statefulness, one-way data flow, components, and virtual DOM.
With the basics out of the way, we will spend the second-day building a complex application which will put React through its paces and give us a chance to explore most of its features. Then we will learn how to think in React. We will show you how to go from design to components to working application. We will wrap the weekend with a quick preview of React Native, which allows you to use your React skills to create cross-platform mobile apps.
A short and fast journey through some of the profiling options available in the Ruby 2.x world, including a look at flamegraphs and new ways of tracking memory usage in the MRI.
This talk will present R as a programming language suited for solving data analysis and modeling problems, MLflow as an open source project to help organizations manage their machine learning lifecycle and the intersection of both by adding support for R in MLflow. It will be highly interactive and touch on some of the technical implementation choices taken while making R available in MLflow. It will also demonstrate using MLflow tracking, projects, and models directly from R as well as reusing R models in MLflow to interoperate with other programming languages and technologies.
ASTs are an incredibly powerful tool for understanding and manipulating JavaScript. We'll explore this topic by looking at examples from ESLint, a pluggable static analysis tool, and Browserify, a client-side module bundler. Through these examples we'll see how ASTs can be great for analyzing and even for modifying your JavaScript. This talk should be interesting to anyone that regularly builds apps in JavaScript either on the client-side or on the server-side.
Emerging Languages: A Tour of the HorizonAlex Payne
A tour of a number of new programming languages, organized by the job they're best suited for. Presented at Philadelphia Emerging Technology for the Enterprise 2012.
ave time learning on your own. Start Building with React, MongoDB, Express, & Node. The MERN Stack.
Learning a new JavaScript framework is difficult. You can spend weeks learning new concepts. If an online example doesn’t work, you may spend countless hours Googling, searching Stack Overflow and blogs for the solution.
Take the fast track and learn from an experienced Senior Software Engineer and professional instructor!
About this Course
This highly interactive course features a large amount of student labs and hands-on coding. You will be taught how to assemble the complete stack required to build a modern web app using React.js, MongoDB (a NoSQL database) and Express (a framework for web application servers). This course will also cover many other tools that go into building a complete web application: React Router, React-Bootstrap, Redux, Babel, and Webpack.
What You Will Learn
• How to use modern JavaScript features
• Webpack
• Node & Express
• Reading and writing data to a MongoDB database
• Babel
• React
• State Management with Redux
• Mongoose
• And More!
Node has captured the attention of early adopters by clearly differentiating itself as being asynchronous from the ground up while remaining accessible. Now that server side JavaScript is at the cutting edge of the asynchronous, real time web, it is in a much better position to establish itself as the go to language for also making synchronous, CRUD webapps and gain a stronger foothold on the server.
This talk covers the current state of server side JavaScript beyond Node. It introduces Common Node, a synchronous CommonJS compatibility layer using node-fibers which bridges the gap between the different platforms. We look into Common Node's internals, compare its performance to that of other implementations such as RingoJS and go through some ideal use cases.
Experience our free, in-depth three-part Tendenci Platform Corporate Membership Management workshop series! In Session 1 on May 14th, 2024, we began with an Introduction and Setup, mastering the configuration of your Corporate Membership Module settings to establish membership types, applications, and more. Then, on May 16th, 2024, in Session 2, we focused on binding individual members to a Corporate Membership and Corporate Reps, teaching you how to add individual members and assign Corporate Representatives to manage dues, renewals, and associated members. Finally, on May 28th, 2024, in Session 3, we covered questions and concerns, addressing any queries or issues you may have.
For more Tendenci AMS events, check out www.tendenci.com/events
Check out the webinar slides to learn more about how XfilesPro transforms Salesforce document management by leveraging its world-class applications. For more details, please connect with sales@xfilespro.com
If you want to watch the on-demand webinar, please click here: https://www.xfilespro.com/webinars/salesforce-document-management-2-0-smarter-faster-better/
Large Language Models and the End of ProgrammingMatt Welsh
Talk by Matt Welsh at Craft Conference 2024 on the impact that Large Language Models will have on the future of software development. In this talk, I discuss the ways in which LLMs will impact the software industry, from replacing human software developers with AI, to replacing conventional software with models that perform reasoning, computation, and problem-solving.
Enterprise Resource Planning System includes various modules that reduce any business's workload. Additionally, it organizes the workflows, which drives towards enhancing productivity. Here are a detailed explanation of the ERP modules. Going through the points will help you understand how the software is changing the work dynamics.
To know more details here: https://blogs.nyggs.com/nyggs/enterprise-resource-planning-erp-system-modules/
Software Engineering, Software Consulting, Tech Lead.
Spring Boot, Spring Cloud, Spring Core, Spring JDBC, Spring Security,
Spring Transaction, Spring MVC,
Log4j, REST/SOAP WEB-SERVICES.
May Marketo Masterclass, London MUG May 22 2024.pdfAdele Miller
Can't make Adobe Summit in Vegas? No sweat because the EMEA Marketo Engage Champions are coming to London to share their Summit sessions, insights and more!
This is a MUG with a twist you don't want to miss.
Prosigns: Transforming Business with Tailored Technology SolutionsProsigns
Unlocking Business Potential: Tailored Technology Solutions by Prosigns
Discover how Prosigns, a leading technology solutions provider, partners with businesses to drive innovation and success. Our presentation showcases our comprehensive range of services, including custom software development, web and mobile app development, AI & ML solutions, blockchain integration, DevOps services, and Microsoft Dynamics 365 support.
Custom Software Development: Prosigns specializes in creating bespoke software solutions that cater to your unique business needs. Our team of experts works closely with you to understand your requirements and deliver tailor-made software that enhances efficiency and drives growth.
Web and Mobile App Development: From responsive websites to intuitive mobile applications, Prosigns develops cutting-edge solutions that engage users and deliver seamless experiences across devices.
AI & ML Solutions: Harnessing the power of Artificial Intelligence and Machine Learning, Prosigns provides smart solutions that automate processes, provide valuable insights, and drive informed decision-making.
Blockchain Integration: Prosigns offers comprehensive blockchain solutions, including development, integration, and consulting services, enabling businesses to leverage blockchain technology for enhanced security, transparency, and efficiency.
DevOps Services: Prosigns' DevOps services streamline development and operations processes, ensuring faster and more reliable software delivery through automation and continuous integration.
Microsoft Dynamics 365 Support: Prosigns provides comprehensive support and maintenance services for Microsoft Dynamics 365, ensuring your system is always up-to-date, secure, and running smoothly.
Learn how our collaborative approach and dedication to excellence help businesses achieve their goals and stay ahead in today's digital landscape. From concept to deployment, Prosigns is your trusted partner for transforming ideas into reality and unlocking the full potential of your business.
Join us on a journey of innovation and growth. Let's partner for success with Prosigns.
Developing Distributed High-performance Computing Capabilities of an Open Sci...Globus
COVID-19 had an unprecedented impact on scientific collaboration. The pandemic and its broad response from the scientific community has forged new relationships among public health practitioners, mathematical modelers, and scientific computing specialists, while revealing critical gaps in exploiting advanced computing systems to support urgent decision making. Informed by our team’s work in applying high-performance computing in support of public health decision makers during the COVID-19 pandemic, we present how Globus technologies are enabling the development of an open science platform for robust epidemic analysis, with the goal of collaborative, secure, distributed, on-demand, and fast time-to-solution analyses to support public health.
OpenFOAM solver for Helmholtz equation, helmholtzFoam / helmholtzBubbleFoamtakuyayamamoto1800
In this slide, we show the simulation example and the way to compile this solver.
In this solver, the Helmholtz equation can be solved by helmholtzFoam. Also, the Helmholtz equation with uniformly dispersed bubbles can be simulated by helmholtzBubbleFoam.
In 2015, I used to write extensions for Joomla, WordPress, phpBB3, etc and I ...Juraj Vysvader
In 2015, I used to write extensions for Joomla, WordPress, phpBB3, etc and I didn't get rich from it but it did have 63K downloads (powered possible tens of thousands of websites).
Understanding Globus Data Transfers with NetSageGlobus
NetSage is an open privacy-aware network measurement, analysis, and visualization service designed to help end-users visualize and reason about large data transfers. NetSage traditionally has used a combination of passive measurements, including SNMP and flow data, as well as active measurements, mainly perfSONAR, to provide longitudinal network performance data visualization. It has been deployed by dozens of networks world wide, and is supported domestically by the Engagement and Performance Operations Center (EPOC), NSF #2328479. We have recently expanded the NetSage data sources to include logs for Globus data transfers, following the same privacy-preserving approach as for Flow data. Using the logs for the Texas Advanced Computing Center (TACC) as an example, this talk will walk through several different example use cases that NetSage can answer, including: Who is using Globus to share data with my institution, and what kind of performance are they able to achieve? How many transfers has Globus supported for us? Which sites are we sharing the most data with, and how is that changing over time? How is my site using Globus to move data internally, and what kind of performance do we see for those transfers? What percentage of data transfers at my institution used Globus, and how did the overall data transfer performance compare to the Globus users?
Climate Science Flows: Enabling Petabyte-Scale Climate Analysis with the Eart...Globus
The Earth System Grid Federation (ESGF) is a global network of data servers that archives and distributes the planet’s largest collection of Earth system model output for thousands of climate and environmental scientists worldwide. Many of these petabyte-scale data archives are located in proximity to large high-performance computing (HPC) or cloud computing resources, but the primary workflow for data users consists of transferring data, and applying computations on a different system. As a part of the ESGF 2.0 US project (funded by the United States Department of Energy Office of Science), we developed pre-defined data workflows, which can be run on-demand, capable of applying many data reduction and data analysis to the large ESGF data archives, transferring only the resultant analysis (ex. visualizations, smaller data files). In this talk, we will showcase a few of these workflows, highlighting how Globus Flows can be used for petabyte-scale climate analysis.
Into the Box Keynote Day 2: Unveiling amazing updates and announcements for modern CFML developers! Get ready for exciting releases and updates on Ortus tools and products. Stay tuned for cutting-edge innovations designed to boost your productivity.
Exploring Innovations in Data Repository Solutions - Insights from the U.S. G...Globus
The U.S. Geological Survey (USGS) has made substantial investments in meeting evolving scientific, technical, and policy driven demands on storing, managing, and delivering data. As these demands continue to grow in complexity and scale, the USGS must continue to explore innovative solutions to improve its management, curation, sharing, delivering, and preservation approaches for large-scale research data. Supporting these needs, the USGS has partnered with the University of Chicago-Globus to research and develop advanced repository components and workflows leveraging its current investment in Globus. The primary outcome of this partnership includes the development of a prototype enterprise repository, driven by USGS Data Release requirements, through exploration and implementation of the entire suite of the Globus platform offerings, including Globus Flow, Globus Auth, Globus Transfer, and Globus Search. This presentation will provide insights into this research partnership, introduce the unique requirements and challenges being addressed and provide relevant project progress.
Listen to the keynote address and hear about the latest developments from Rachana Ananthakrishnan and Ian Foster who review the updates to the Globus Platform and Service, and the relevance of Globus to the scientific community as an automation platform to accelerate scientific discovery.
Accelerate Enterprise Software Engineering with PlatformlessWSO2
Key takeaways:
Challenges of building platforms and the benefits of platformless.
Key principles of platformless, including API-first, cloud-native middleware, platform engineering, and developer experience.
How Choreo enables the platformless experience.
How key concepts like application architecture, domain-driven design, zero trust, and cell-based architecture are inherently a part of Choreo.
Demo of an end-to-end app built and deployed on Choreo.
First Steps with Globus Compute Multi-User EndpointsGlobus
In this presentation we will share our experiences around getting started with the Globus Compute multi-user endpoint. Working with the Pharmacology group at the University of Auckland, we have previously written an application using Globus Compute that can offload computationally expensive steps in the researcher's workflows, which they wish to manage from their familiar Windows environments, onto the NeSI (New Zealand eScience Infrastructure) cluster. Some of the challenges we have encountered were that each researcher had to set up and manage their own single-user globus compute endpoint and that the workloads had varying resource requirements (CPUs, memory and wall time) between different runs. We hope that the multi-user endpoint will help to address these challenges and share an update on our progress here.
12. Signal of current GPS position (CLLocation)
@100 @450 @300 @140
time
Signal of numerical values (NSNumber)
@270
Signal of boolean values (NSNumber)
@YES @NO @YES
13. Signal of current GPS position (CLLocation)
@100 @450 @300 @140
time
Signal of numerical values (NSNumber)
@270
Signal of boolean values (NSNumber)
@YES @NO @YES
Signals(send(events(over(
&me
A"signal"is"a"push,driven"stream.
It#produces#three#types#of#events:
• next"values
• an"error
• a"comple+on
24. Other&opera*ons
• flatten flattenMap zip zipWith startWith
• delay throttle sample timeout
• take takeUntil skip ignoreValues
• try catch then switch if and or not
• replay replayLast repeat retry
..."and"a"lot"more"...
32. Transforming+exis.ng+signals
- (RACSignal *)colorForUnreadCount {
return [RACObserve(self.model,unreadCount) // this is a signal
// 'map' subscribes to the signal above and returns
// a new signal that sends a color for each new unreadCount
map:^id(NSNumber *unread) {
NSInteger count = unread.integerValue;
return count < 10 ? [UIColor blackColor] :
count < 20 ? [UIColor orangeColor] :
[UIColor redColor];
}];
}
33. Transforming+exis.ng+signals
// using the signal created in the previous slide
[[model colorForUnreadCount] subscribeNext:^(UIColor *color) {
self.unreadLabel.textColor = color;
}];
// a shorter way to write this (for simple binding cases)
// see <ReactiveCocoa/RACSusbscriptingAssignmentTrampoline.h>
RAC(self.unreadLabel, textColor) = model.colorForUnreadCount;
34. Dynamic(signals
- (RACSignal *)post:(NSDictionary *)formData toURL:(NSURL *)url {
return [RACSignal createSignal:^(id<RACSubscriber> subscriber)] {
// use AFNetworking to post form data
NSURLSessionDataTask *task = [self.sessionManager POST:url parameters:data
success:^(NSURLSessionDataTask *t, NSDictionary *responseObject) {
if (responseObject)
[subscriber sendNext:responseObject];
[subscriber sendCompleted];
}
failure:^(NSURLSessionDataTask *t, NSError *error) {
[subscriber sendError:error];
}
];
return [RACDisposable disposableWithBlock:^{
[task cancel];
}];
}];
}
35. Dynamic(signals
// use signal defined in previous slide
RACSignal *postSignal = [manager post:@{@"name": @"Florent"} toURL:someURL];
[postSignal subscribeNext:^(NSDictionary *response) {
NSLog(@"Server answered POST with %@", response);
} error:^(NSError *error) {
NSLog(@"POST failed with error: %@", error);
} completed:{
NSLog(@"POST was successful");
}]
41. Schedulers
// A one-time timer that fires after 1 second on main thread
RACDisposable *timer = [[RACScheduler mainThreadScheduler]
afterDelay:1.0
schedule:^{
NSLog(@"Delayed logging");
}];
// We can cancel this at any time
[timer dispose];