uml

Statecharts: Limit the number of time a state gets executed

送分小仙女□ 提交于 2019-12-11 10:48:00
问题 How can I graphically represent within Statechart Diagrams that a state never gets executed more than a certain amount of times? So that it doesn't end in an infinite loop. Something like assert enterPIN(int p) <= 3 and then branch to another state, if condition violated. Should I include it somehow in the guard? Or in the state activities? EDIT: (CheckPIN)--[invalid]-->(counter| + inc.)--[counter>3]-->(retainCard) ^ | |-----[counter<=3]-----| Something in this direction? Legend: (StateName |

How can I model a custom exception association in a class diagram?

笑着哭i 提交于 2019-12-11 10:32:30
问题 Reading here, it seems modelling a custom exception class using a generalisation is common place. What it doesn't mention is how I can model an association with a class that could potentially throw the custom exception. Note, I'm not asking how to model the sequence behaviour when it comes to raising the exception; I'm specifically wanting to model the association. Or is this a misuse of the class diagram? 回答1: Probably like this: Note that <<throws>> isn't a standard UML stereotype. There's

UML Use case: Waiting for another use case to finish

你说的曾经没有我的故事 提交于 2019-12-11 09:57:01
问题 I'm trying to model a use case, basically it's how a round is played in a quiz-show. the actor in the use case is the quizmaster; he asks the questions to the participants. There's a lot going on in this use case but my problem comes down to the point where the quizmaster has to wait for a player to buzz his button and give an answer to a question he has asked so it can be judged (Right or wrong). There's a seperate use case the actor "Candidate" follows to answer the question the quizmaster

Is this a correct UML activity diagram?

末鹿安然 提交于 2019-12-11 09:30:04
问题 Made this diagram for my tictactoe game. It is an activity diagram here is a link: http://i58.tinypic.com/fo26n4.png tell me if it is correct. Thanks Is it correct? What am i doing wrong? 回答1: No. The problems are: you haven't created the loop for each move. Put there a switch X-O for every turn Tie a player to X and to O. Check winner sounds strange. Look for three in line would be better. Add declare current player as a winner . 来源: https://stackoverflow.com/questions/22404304/is-this-a

Interfaces in UML component diagram

☆樱花仙子☆ 提交于 2019-12-11 09:17:21
问题 In the UML class diagram the interface is equivalent to the interface concept in programming languages (a set of methods that the class that implement the interface should implement). I want to know if the interface in the component diagram has the same meaning. Are the interfaces mentioned in the component diagram the same interfaces that are detailed in the class diagram or should I treat every method in the component diagram as a separate interface? 回答1: There is actually no real

Interaction between HTML/Javascript coder and server scripting language coder?

|▌冷眼眸甩不掉的悲伤 提交于 2019-12-11 09:14:46
问题 I don't want my PHP coder to write Javascript anymore. I want to separate javascript coding and php coding. How should I write documentation about this interaction? Let's imagine really simple ajax request. As for me documentation should contain sequence flow diagram. user is clicking "edit" button preloader is shown to user ajax request is sent to url /ajax_request/category/{category_id}/; we are expecting answer in json format timer has started; if answer is not recieved within 10 seconds -

Generating Sequence Diagrams Using UMLGraph

断了今生、忘了曾经 提交于 2019-12-11 09:04:03
问题 I am using UMLGraph to generate sequence diagrams. I have a problem using the pic2plot program to generate svg images. It clips the image and parts of the image don't show. This problem is also documented in the FAQ: How can I prevent clipped SVG images in sequence diagrams? This appears to be a limitation of pic2plot. You can work around it, by increasing the width and height values appearing in the SVG XML file that pic2plot generates. However, I have tried but failed to change the width

how to relate data with function in uml class diagram

吃可爱长大的小学妹 提交于 2019-12-11 08:46:31
问题 I have two private data structures and five functions in my class, How can I represent the relation between the functions and the data structures in class. Eg: Two of those functions uses the First data structure and three other functions uses the second data structure. Also How can I represent relation between the functions in the class. eg : among the 5 functions two are public and three are private, one public function in the class calls the other three private functions. If this is not

php uml reverse engineering [closed]

一个人想着一个人 提交于 2019-12-11 08:42:43
问题 Closed. This question is off-topic. It is not currently accepting answers. Want to improve this question? Update the question so it's on-topic for Stack Overflow. Closed 4 years ago . I'm strugglying with UML diagrams as I just need to draw diagram to visualize better the dozen of classes I've created : I'm lost with these classes every time I come back from a break. So I'd need to draw them back from sources. I know it's not a real new topic (for example this one) but I spent the whole night

activity diagram in uml regarding parallel activities

跟風遠走 提交于 2019-12-11 08:24:32
问题 I had a doubt regarding parallel activities that occur in the system. How can we represent those in the diagram? Is there always a need of fork or the decision element can also be used? Eg.: The user can choose among "Add Book" , "Search Book", "Search User" and "Update profile". So after the user logs in the system he can choose among the above operations. Below is the image of my activity diagram. 回答1: According to http://www.uml-diagrams.org/activity-diagrams-reference.html the .. Fork