Questions tagged [state-saving]

57 questions
2
votes
1 answer

Issue with cPickle

all. I'm currently trying to use cPickle to create a 'save_game' function for my Roguelike. save_game() pickles the game-state properly, but if I exit the game, the load_game() function flatly refuses to acknowledge that the pickled file exists when…
2
votes
1 answer

JSF composite component - weird behavior when trying to save state

I'm using Glassfish 3.2.2 and JSF 2.1.11 I'm trying to create a composite component that will take as parameters a string and a max number of characters and then will show only the max amount of characters, but it will have a "more" link next to it,…
jc12
  • 1,411
  • 1
  • 18
  • 24
1
vote
1 answer

React useEffect cleanup function to save state to a database without running into closure probelms

I understand that this is an issue of closures. I have state in a reducer in my component, which, upon unmount, I would like to save to a database. const [localState, dispatch] = useReducer(myReducer, initialState); const handleUnmount = () => { …
1
vote
0 answers

How do I save the step where the user left off in the wizard using Wicked gem?

Context I'm new to app development in Rails so please let me know if I am missing something obvious about saving/storing states in Rails. I'm using the Wicked gem in my app to guide users through a medical assessment that has the following…
oamandawi
  • 405
  • 5
  • 15
1
vote
0 answers

ClassCastException:

When I'm trying to click on the submit button, initially method is calling and executing but when I'm trying to click the same submit button for the second time I'm facing the below issue in response: Below is the code:
Madhu
  • 11
  • 1
1
vote
2 answers

this.setState not functioning properly

I don't know why but after I log in and then log out I am unable to switch between the signup and login panel in "AuthForm.jsx" the "this.setState" will not work. I have expounded on the code breaking into somany pieces to see where it could go…
Mr Day2Day
  • 73
  • 1
  • 7
1
vote
0 answers

Composite component recursion

I want to do a recursive call to the composite component. Those. something like ...
1
vote
0 answers

Minimum number of bytes for view state in MyFaces server side state saving

What is the minimum number of bytes for view state in MyFaces when server side state saving method is used?
1
vote
0 answers

When Don't Keep Activities option on, onSavedInstanceState is giving null in Activity A

Flow Image I am facing a strange issue related to saving the state in Android. When I turn on Don't Keep Activities option in Android(From Developer Option). Then if I launch Activity B(which launches Fragment B) from Fragment A (launched by…
craftizmv
  • 71
  • 6
1
vote
0 answers

StateHelper strange behavior difference for put and add

I'm currently implementing a backing component for a composite component. I'm using the state helper to keep the internal state during requests and I found a strange behavior I can't explain to myself. The composite component has a button which…
grubi
  • 155
  • 2
  • 16
1
vote
3 answers

saving data structure c++ to disk

I have a very complex data structure with pointers to various parts of the memory. It takes a while to build and I would like to save the "memory" used by that structure to the disk. Then, when the program is launched again, it would just memory map…
madreblu
  • 373
  • 5
  • 15
1
vote
1 answer

jquery datatable - state save not working for first time

We are using the jquery datatable for the table to save the state. Its not working for the first time, but it works fine next time. We need to retain the filter and paging even after the page refresh, but its not working for the first time. Below is…
Prasad
  • 58,881
  • 64
  • 151
  • 199
1
vote
2 answers

How to save state of activity on android on back key press

I'm having an issue with an android app I'm writing that seems like it should be a common issue but I can't find any information on it. I have a scoreboard activity in my app that just stores a grid of scores in textviews, it's the kind of thing…
Moe Zus
  • 33
  • 1
  • 5
1
vote
0 answers

State Saving and mutable model class

I am currently working on an application that got quite recently ported from JSF 1.2 to JSF 2 (Mojarra 2.1.21 + Seam 2.3). There is one page that has quite a lot of similar constructs (this isnt exact syntax and I know that ELs would not compile in…
Rafal G.
  • 4,252
  • 1
  • 25
  • 41