Questions tagged [application-lifecycle]

It is usually used in enterprise programming contexts where application, session and request scopes (lifecycles) can be distinguished. In this case specific objects (e.g. an EJB if speaking about Java EE) can have different lifecycles according to these scopes managed by the container infrastructure.

221 questions
3
votes
3 answers

Method should call once and only once in its lifecycle

I have a method which is actually a scheduler which runs a process in every one hour and create a log file every hour. I want to call this method once in the application life cycle so I call it from a static block. But I feel this is not working…
NIVESH SENGAR
  • 1,285
  • 5
  • 19
  • 43
3
votes
1 answer

What are the typical tools used to get a Rails application from development to production?

As an experienced .NET developer, I am interested in learning the Ruby on Rails development process. I have experience with ASP.NET WebForms and MVC, and I have used PHP as well. I have gone through some basic RoR tutorials and was able to get them…
John Rasch
  • 62,489
  • 19
  • 106
  • 139
3
votes
1 answer

Is application:didFinishLaunchingWithOptions: really a good place to initialize cocos2d and its OpenGL ES view?

Cocos2d templates and the usual sample projects initialize cocos openGL ES view and other stuff in the applicationDidFinishLaunching / application:didFinishLaunchingWithOptions: method. In relation to the last method, Apple iOS Programming Guide…
Lio
  • 4,225
  • 4
  • 33
  • 40
3
votes
1 answer

didChangeAppLifecycleState is not working Flutter

I have the app of more than 20 screens , I want to perform a task if user is inactive/idle for a certain time. I am trying to get the app's lifecycle at root of app. But i am not getting print statements on my logcat. What wrong I have done…
Nibha Jain
  • 7,742
  • 11
  • 47
  • 71
3
votes
1 answer

viewWillAppear not called apparently due to my view hierarchy

This appears to be a well documented problem, yet the solutions online have not worked. Here's just a sample list of posts that failed to provide me with a working answer: ViewWillAppear not executing code viewWillAppear not getting…
michaeldebo
  • 3,065
  • 4
  • 14
  • 20
3
votes
2 answers

What is the proper way to get root view controller in iOS 13?

class TopViewController: UIViewController { override func viewDidLoad() { super.viewDidLoad() //Code Block 1 let controller = getTopController() print(controller)// Prints out MyTestProject.TopViewController …
Prajeet Shrestha
  • 7,978
  • 3
  • 34
  • 63
3
votes
1 answer

Flutter: How to track app lifecycle without a widget

I'm involved with the FlutterSound project which is shipped as a package containing an api that, for the purposes of this question, doesn't contain a widget. The api needs to handle events when the application changes its state…
Brett Sutton
  • 3,900
  • 2
  • 28
  • 53
3
votes
3 answers

Activity seems to be created before application object

I have been receiving some crash reports in the Play Store which initially seemed crazy to me. Some activities (in 1 case, it's a broadcast receiver) are crashing in onCreate()/onResume() due to NullPointerException. These activities are using…
3
votes
1 answer

Aspnet Core - Application Started event

I am trying to find an event that notify that and aspnet core application is now ready to server http requests. I tried to use the IApplicationLifetime.ApplicationStarted but the event is raised before the application is ready to handle…
Linvi
  • 2,077
  • 1
  • 14
  • 28
3
votes
5 answers

Finishing android app on HOME button click

How to finish the application on HOME button click?
user523046
  • 151
  • 1
  • 2
  • 5
3
votes
1 answer

Best approach to maintain skeleton for my projects with git

For few years I was looking for way to manage multiple projects I'm working on. Every single one is different in some way, but the core of application in common for all. When I implemented some new features in current project, it was hard to use…
Edke
  • 161
  • 1
  • 1
  • 6
3
votes
1 answer

ASP.NET Application Level vs. Session Level and Global.asax...confused

The following text is from the book I'm reading, 'MCTS Self-Paced Training Kit (Exam 70-515) Web Applications Development with ASP.NET 4". It gives the rundown of the Application Life Cycle. A user first makes a request for a page in your…
contactmatt
  • 18,116
  • 40
  • 128
  • 186
3
votes
1 answer

Close secondary view completely in UWP

I am using a secondary view to run my media files, but When I close my secondary view with close button on it (while media is still playing) the secondary view/window closes but the media somehow keeps playing because I can hear the sound and source…
Muhammad Touseef
  • 4,357
  • 4
  • 31
  • 75
3
votes
1 answer

Android Storing Socket.io object for multiple activities

I am making my first Socket.io based android application. The socket sends and receives data from a web service. There are a number of screens in the application for different features. How do i use the same socket connection in these different…
3
votes
3 answers

Android - losing variables data when partially closing an app

I am using a class with static values called DB (for Data Base) in my application. When I first run the app, a static byte array from this class is filled and used. Then, when I partially close my app (not closing it definitily just put in…
Roman Panaget
  • 1,578
  • 12
  • 21