wpf - can I use MVP with MVVM -




i got source-code , trying understand using documentation.

in documentation, says code has used both mvp , mvvm in combination make project.

can answer these following questions of mine:-

  1. what point of using 2 design pattern in single project(both mvp , mvvm) ?
  2. how can simple know looking @ source code if made using mvp,mvc or other design pattern?
  3. can tell me ....what layers in design pattern? how many minimum layers gonna use make project in design pattern? , benefit of having many layers possible?
  4. what difference between java logic , android logic? coz we're separating apart java android logic better testing environment using design pattern. give example.

if code using mvc see following:

  1. models: models contain data information. not call or use controller , view. contains business logic , ways represent data. of data, in form, may displayed in view. can contain logic retrieve data source.

  2. controller: acts connection between view , model. view calls controller , controller calls model. informs model and/or view change appropriate.

  3. view: deals ui part. interacts user.

for mvvm (model view view model):

viewmodel:

  1. it representation of state of view.
  2. it holds data that’s displayed in view.
  3. responds view events, aka presentation logic.
  4. calls other functionalities business logic processing.
  5. never directly asks view display anything.

now let's see mvp (model view presenter):

similar traditional mvc controller replaced presenter. presenter, unlike controller responsible changing view well. the view not call presenter.

now questions:

what point of using 2 design pattern in single project(both mvp , mvvm)?
ans: may need. both closely related , said might useful mix 2 solve particular type of problem.

how can simple know looking @ source code if made using mvp,mvc or other design pattern?

ans: read explanation provided. try see pattern closely matches code. there might multiple design patterns used.

can tell me ....what layers in design pattern? how many minimum layers gonna use make project in design pattern? , benefit of having many layers possible?
ans: there no such hard , fast rule on number of layers. make code reusable, maintainable, open extension , follow best practices of software engineering important follow design patterns.

what difference between java logic , android logic? coz we're separating apart java android logic better testing environment using design pattern. give example.

ans: there no such thing called java logic , android logic.





wiki

Comments

Popular posts from this blog

Asterisk AGI Python Script to Dialplan does not work -

python - Read npy file directly from S3 StreamingBody -

kotlin - Out-projected type in generic interface prohibits the use of metod with generic parameter -