栏目分类:
子分类:
返回
名师互学网用户登录
快速导航关闭
当前搜索
当前分类
子分类
实用工具
热门搜索
名师互学网 > IT > 软件开发 > 后端开发 > Java

EE308 LAB9

Java 更新时间: 发布时间: IT归档 最新发布 模块sitemap 名妆网 法律咨询 聚返吧 英语巴士网 伯小乐 网商动力

EE308 LAB9

The link Your Class

https://bbs.csdn.net/forums/MUEE308FZ

The link of Requirement of This Assignment

https://bbs.csdn.net/topics/603386400

MU STU ID and FZU STU ID

19104553_831902205

Directory

Background

Question1

Question2 

Question3 

Question4

Question5

Question6 

Question7 


Background

        Live-streaming sale, through some Internet platforms, is a new way of service using live-streaming technology for close commodity display, consultation response, and shopping guide. Merchants can open their own live broadcast room, or employ professional anchors to recommend goods. At present, not only many celebrities flock into this field, but some big companies’ executives are also frequently involved. Please try to design a comprehensive live-streaming sale system.


Question1

List some actors that interact with this system. Explain the relevance of each actor.

  • Merchant: People who give their products’ instructions to anchors and make anchors promote these products by using anchors’ tricks. 
  • Anchor: People who try their best to promote products and attract consumers to buy.
  • Consumer: People who watch the live-streaming broadcast, listen to the anchors and decide which products they will buy.
  • Live Broadcast platform company: People who check whether products or anchors are illegal and provide technical support for the live broadcast.

Question2 

Prepare a use case diagram for this system.


Question3 

Prepare a normal scenario for each use case.

  • Use case: Live-streaming Broadcast

Participant: Live Broadcast Platform Company, Anchor and Consumer

Description: A platform provided by live broadcast platform company will complete basic settings and make all the preparations. Anchor can begin their live-streaming broadcast by clicking on a button “start” on the platform and the broadcasting room will be ready. And anchor will begin their broadcast to promote products even if there are nobody watching. Consumer can watch the broadcast by clicking on a button “watch” and enter the broadcasting room to watch live-streaming broadcast.

  • Use case: Purchase Product

Participant: Live Broadcast Platform Company and Consumer

Description: Consumer can purchase products they want and pay money to the platform. Platform will receive these money, process orders and give the orders and money to merchant.

  • Use case: Process Orders

Participant: Live Broadcast Platform Company and Merchant

Description: The platform will receive the buying request of consumer and give merchant orders to make them prepare the delivery of product.

  • Use case: Regulate the Platform

Participant: Live Broadcast Platform Company, Anchor and Merchant

Description: Merchant should provide introductions of product and product itself for the live broadcast platform company before the broadcast to check whether they are illegal. The company will provide the broadcasting room for the merchant if the product is legal. The company will also supervise the actions of anchor to let them obey the rules.

  • Use case: Technical Support and System Maintenance

Participant: Live Broadcast Platform Company

Description: Live broadcast platform company should provide technical support and system maintenance for this live-streaming sale system. They should maintain this system daily and solve each problem users encounter. They can also provide some functions such as searching, recommending and paying which are sub-use cases.


Question4

Prepare sequence diagrams or activity diagrams for primary scenarios. By the way, each scenario can be described by a sequence diagram or an activity diagram, but both diagrams must be used in the question. 

  • Live-stream Broadcast:

Sequence diagram:

Activity diagram:

  • Regulate the Platform

Sequence diagram:


 

Activity diagram:

  • Technical Support and System Maintenance

Sequence diagram:

 Activity diagram:


Question5

Prepare a class diagram for this system. Explain which principles of object-oriented are applied in your design.

Object-oriented principles applied in my design:

  • Single Responsibility Principle (SRP): Every object should have a single responsibility, and that responsibility should be entirely encapsulated by the class.
  • Law of Demeter (LoD): Each unit should have only limited knowledge about other units: only units "closely" related to the current unit.

Question6 

Prepare state diagrams for primary classes.

  • For Consumer:

  • For anchor: 


Question7 

Prepare a class diagram for this system. Explain which principles of object-oriented are applied in your design.

  • Anchor.java
import java.util.*;


public class Anchor {

    
    public Anchor() {
    }

    
    public string name;

    
    public string id;

    
    public string qualification;




    
    public void startLiveStreaming() {
        // TODO implement here
    }

    
    public void applyForLiveStreaming() {
        // TODO implement here
    }

}
  •  Consumer.java
import java.util.*;


public class Consumer {

    
    public Consumer() {
    }

    
    public string name;

    
    public string id;



    
    public void watch() {
        // TODO implement here
    }

    
    public void pay() {
        // TODO implement here
    }

    
    public void searchForIntersest() {
        // TODO implement here
    }

}
  •  live_streamingSaleSystem.java
import java.util.*;


public class live_streamingSaleSystem {

    
    public live_streamingSaleSystem() {
    }





    
    public void checkQualificationOfAnchor() {
        // TODO implement here
    }

    
    public void giveApprovalOfAnchor() {
        // TODO implement here
    }

}
  • liveBroadcastPlatformCompany.java 
import java.util.*;


public class liveBroadcastPlatformCompany {

    
    public liveBroadcastPlatformCompany() {
    }

    
    public string name;

    
    public string brand;




    
    public void superviseLiveStreaming() {
        // TODO implement here
    }

    
    public void checkQualificationOfMerchant() {
        // TODO implement here
    }

    
    public void lookForProblemsInSystem() {
        // TODO implement here
    }

    
    public void solveProblems() {
        // TODO implement here
    }

    
    public void modifyCodes() {
        // TODO implement here
    }

}
  • Merchant.java
import java.util.*;


public class Merchant {

    
    public Merchant() {
    }

    
    public string name;

    
    public string brand;

    
    public string product;





    
    public void processOrders() {
        // TODO implement here
    }

    
    public void deliverProducts() {
        // TODO implement here
    }

    
    public void provideIntroductionOfProductAndProductItself() {
        // TODO implement here
    }

}

转载请注明:文章转载自 www.mshxw.com
本文地址:https://www.mshxw.com/it/531285.html
我们一直用心在做
关于我们 文章归档 网站地图 联系我们

版权所有 (c)2021-2022 MSHXW.COM

ICP备案号:晋ICP备2021003244-6号