CN114449026B - Method for recording online learning duration and related equipment - Google Patents

Method for recording online learning duration and related equipment Download PDF

Info

Publication number
CN114449026B
CN114449026B CN202111546761.3A CN202111546761A CN114449026B CN 114449026 B CN114449026 B CN 114449026B CN 202111546761 A CN202111546761 A CN 202111546761A CN 114449026 B CN114449026 B CN 114449026B
Authority
CN
China
Prior art keywords
client
learning
duration
recording
random code
Prior art date
Legal status (The legal status is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the status listed.)
Active
Application number
CN202111546761.3A
Other languages
Chinese (zh)
Other versions
CN114449026A (en
Inventor
高军涛
Current Assignee (The listed assignees may be inaccurate. Google has not performed a legal analysis and makes no representation or warranty as to the accuracy of the list.)
Beijing Honghe Aixue Education Technology Co ltd
Original Assignee
Beijing Honghe Aixue Education Technology Co ltd
Priority date (The priority date is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the date listed.)
Filing date
Publication date
Application filed by Beijing Honghe Aixue Education Technology Co ltd filed Critical Beijing Honghe Aixue Education Technology Co ltd
Priority to CN202111546761.3A priority Critical patent/CN114449026B/en
Publication of CN114449026A publication Critical patent/CN114449026A/en
Application granted granted Critical
Publication of CN114449026B publication Critical patent/CN114449026B/en
Active legal-status Critical Current
Anticipated expiration legal-status Critical

Links

Classifications

    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04LTRANSMISSION OF DIGITAL INFORMATION, e.g. TELEGRAPHIC COMMUNICATION
    • H04L67/00Network arrangements or protocols for supporting network services or applications
    • H04L67/14Session management
    • H04L67/146Markers for unambiguous identification of a particular session, e.g. session cookie or URL-encoding
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F21/00Security arrangements for protecting computers, components thereof, programs or data against unauthorised activity
    • G06F21/30Authentication, i.e. establishing the identity or authorisation of security principals
    • G06F21/31User authentication
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06QINFORMATION AND COMMUNICATION TECHNOLOGY [ICT] SPECIALLY ADAPTED FOR ADMINISTRATIVE, COMMERCIAL, FINANCIAL, MANAGERIAL OR SUPERVISORY PURPOSES; SYSTEMS OR METHODS SPECIALLY ADAPTED FOR ADMINISTRATIVE, COMMERCIAL, FINANCIAL, MANAGERIAL OR SUPERVISORY PURPOSES, NOT OTHERWISE PROVIDED FOR
    • G06Q50/00Systems or methods specially adapted for specific business sectors, e.g. utilities or tourism
    • G06Q50/10Services
    • G06Q50/20Education
    • G06Q50/205Education administration or guidance
    • GPHYSICS
    • G07CHECKING-DEVICES
    • G07CTIME OR ATTENDANCE REGISTERS; REGISTERING OR INDICATING THE WORKING OF MACHINES; GENERATING RANDOM NUMBERS; VOTING OR LOTTERY APPARATUS; ARRANGEMENTS, SYSTEMS OR APPARATUS FOR CHECKING NOT PROVIDED FOR ELSEWHERE
    • G07C1/00Registering, indicating or recording the time of events or elapsed time, e.g. time-recorders for work people
    • G07C1/10Registering, indicating or recording the time of events or elapsed time, e.g. time-recorders for work people together with the recording, indicating or registering of other data, e.g. of signs of identity
    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04LTRANSMISSION OF DIGITAL INFORMATION, e.g. TELEGRAPHIC COMMUNICATION
    • H04L67/00Network arrangements or protocols for supporting network services or applications
    • H04L67/14Session management
    • H04L67/141Setup of application sessions

Abstract

The application provides a method for recording online learning duration and related equipment, wherein the method comprises the following steps: receiving a first request message, wherein the first request message comprises a first user unique identifier and a first client random code; controlling a first client to perform online learning, and recording a first learning duration; receiving a second request message, wherein the second request message comprises a second user unique identifier and a second client random code; when the unique identifiers of the two users are the same and the random codes of the two clients are different, stopping online learning of the first client and recording of the first learning duration, controlling the second client to perform online learning, and recording the second learning duration; and taking the sum of the first learning duration and the second learning duration as the online learning duration of the target user corresponding to the unique identification of the first user. The online learning method and the online learning system ensure that the same user can only learn online at one client at the same time, and accurately and conveniently record the online learning time of the user.

Description

Method for recording online learning duration and related equipment
Technical Field
The application relates to the technical field of online education, in particular to a method for recording online learning duration and related equipment.
Background
In an educational informatization scenario, when a learner performs a live or on-demand course study on a learning platform, the background will typically perform data statistics and analysis on the process, where the learning duration is an important item of learning data. If a learner opens multiple clients (the clients may be App applications or browsers, etc.) simultaneously using the same account, the records of the learning duration may be superimposed. When a learner uses a plurality of clients to play to learn at the same time, the learning effect is affected. Therefore, in the recording process of the online learning duration, the influence of the multiterminal play needs to be eliminated.
However, in the related art, the processing mode of the multi-terminal simultaneous learning problem is complicated, and the multi-terminal mutual exclusion has a certain delay and does not respond in real time. The method has the advantages that the recording of the learning duration is complex, the efficiency is low, the accuracy of the recording of the duration is low, and the problem of repeated accumulation of the playing duration is easy to generate.
Disclosure of Invention
Therefore, the application aims to provide a method for recording online learning time and related equipment, so that the method for recording online learning time is provided, has multiple ends of mutually exclusive responses and is convenient to record learning time, and is suitable for live broadcasting lessons and video lessons.
Based on the above object, the present application provides a method for recording online learning duration, comprising:
receiving a first request message, wherein the first request message comprises a first user unique identifier and a first client random code;
controlling a first client corresponding to the first client random code to perform online learning, and recording a first learning duration;
receiving a second request message, wherein the second request message comprises a second user unique identifier and a second client random code;
in response to determining that the first user unique identifier is the same as the second user unique identifier and the first client random code is different from the second client random code, stopping online learning of the first client and recording of the first learning duration, controlling a second client corresponding to the second client random code to perform online learning, and recording a second learning duration;
and taking the sum of the first learning duration and the second learning duration as the online learning duration of the target user corresponding to the unique identification of the first user.
In some embodiments, the controlling the first client corresponding to the first client random code to perform online learning, and recording a first learning duration includes:
Sending first request success information to the first client to control the first client to perform online learning;
establishing a first message channel connected with the first client, and determining the first learning duration according to data received by the first message channel.
In some embodiments, the determining the first learning duration according to the data received by the first message channel includes:
receiving a first initial moment sent by the first client through the first message channel;
receiving a first moment sent by the first client at intervals of a certain duration;
and subtracting the first initial time from the latest received first time to obtain the first learning duration.
In some embodiments, the stopping the online learning of the first client and the recording of the first learning duration includes:
sending disconnection information to the first client to stop online learning of the first client;
disconnecting the first message channel with the first client to stop recording of the first learning duration.
In some embodiments, after the sending the disconnection information to the first client, the method further includes:
Receiving a third moment sent by the first client through the first message channel;
and subtracting the first initial time from the third time to obtain the first learning duration.
In some embodiments, the controlling the second client corresponding to the second client random code to perform online learning, and recording a second learning duration includes:
sending second request success information to the second client to control the second client to perform online learning;
and establishing a second message channel connected with the second client, and determining the second learning duration according to the data received by the second message channel.
In some embodiments, the determining the second learning duration according to the data received by the second message channel includes:
receiving a second initial moment sent by the second client through the second message channel;
receiving a second moment sent by the second client at intervals of a certain duration;
and subtracting the second initial time from the latest received second time to obtain the second learning duration.
Based on the same conception, the application also provides a device for recording the online learning time length, which comprises the following steps:
A first message receiving module configured to receive a first request message, the first request message comprising a first user unique identification and a first client random code;
the first learning module is configured to control a first client corresponding to the first client random code to perform online learning and record a first learning duration;
a second message receiving module configured to receive a second request message, the second request message comprising a second user unique identification and a second client random code;
the second learning module is configured to respond to the fact that the first user unique identifier is the same as the second user unique identifier, the first client random code is different from the second client random code, stop online learning of the first client and recording of the first learning duration, control the second client corresponding to the second client random code to perform online learning, and record second learning duration;
and the duration module is configured to take the sum of the first learning duration and the second learning duration as the online learning duration of the target user corresponding to the first user unique identifier.
Based on the same conception, the application also provides an electronic device comprising a memory, a processor and a computer program stored on the memory and executable on the processor, the processor implementing the method according to any one of the above when executing the program.
Based on the same conception, the present application also provides a non-transitory computer readable storage medium storing computer instructions for causing the computer to implement the method as described in any one of the above.
From the above, the method for recording online learning duration and the related device provided by the application can obtain the first user unique identifier and the first client random code carried by the first request message when the first request message is received; controlling a first client corresponding to the first client random code to perform online learning, and recording a first learning duration; when a second request message is received, a second user unique identifier and a second client random code carried by the second request message are obtained; when the unique identifier of the first user is the same as the unique identifier of the second user and the random code of the first client is different from the random code of the second client, stopping online learning of the first client and recording of the first learning duration, controlling the second client corresponding to the random code of the second client to perform online learning, and recording the second learning duration; and taking the sum of the first learning duration and the second learning duration as the online learning duration of the target user corresponding to the unique identification of the first user. Therefore, in the online learning process, whether the same user opens another client for learning can be judged according to the unique user identification and the client random code, and online learning by the same user by simultaneously opening a plurality of clients is avoided. The online learning of the client is stopped, and the recording of the learning time of the client is stopped, so that the response is rapid, the learning time of only one client can be recorded at the same time, and the repeated accumulation of the learning time is avoided. And adding the learning time lengths of the same user on each client to obtain the total learning time length, and accurately and conveniently recording the online learning time length of the user.
Drawings
In order to more clearly illustrate the technical solutions of the present application or related art, the drawings that are required to be used in the description of the embodiments or related art will be briefly described below, and it is apparent that the drawings in the following description are only embodiments of the present application, and other drawings may be obtained according to the drawings without inventive effort to those of ordinary skill in the art.
FIG. 1 is a flowchart of a method for recording online learning duration according to an embodiment of the present application;
FIG. 2 is a schematic diagram illustrating interaction between a client and a server according to an embodiment of the present application;
FIG. 3 is a schematic diagram of an apparatus for recording online learning duration according to an embodiment of the present application;
fig. 4 is a schematic structural diagram of an electronic device according to an embodiment of the application.
Detailed Description
The present application will be further described in detail below with reference to specific embodiments and with reference to the accompanying drawings, in order to make the objects, technical solutions and advantages of the present application more apparent.
It should be noted that unless otherwise defined, technical or scientific terms used in the embodiments of the present application should be given the ordinary meaning as understood by one of ordinary skill in the art to which the present application belongs. The terms "first," "second," and the like, as used in embodiments of the present application, do not denote any order, quantity, or importance, but rather are used to distinguish one element from another. The word "comprising" or "comprises", and the like, means that elements or items preceding the word are included in the element or item listed after the word and equivalents thereof, but does not exclude other elements or items. The terms "connected" or "connected," and the like, are not limited to physical or mechanical connections, but may include electrical connections, whether direct or indirect.
As described in the background section, in the teaching platform, a user performs a study of a live or on-demand course using the teaching platform, and data statistics analysis is required for the process, in which the learning duration is an important learning data. In order to prevent users from using the same account and opening a plurality of clients at the same time, training effects are affected when learning is performed, and therefore multi-terminal learning scenes need to be processed.
In the related art, for the processing of multi-terminal playing, a client side continuously polls and cooperates with a server side to judge whether a user views video lessons in a plurality of browsers at the same time. However, the method for processing the multi-terminal playing video in the related art is too complicated and not timely. Whether another playing page is opened is judged by a mode of generating a time stamp, and the processing mode needs to continuously generate the time stamp and calculate the interval time. When the second client is already opened for learning, but the second playing page cannot be found in time when the calculation interval time is not yet reached, and delay occurs in processing the multi-terminal problem. For the multi-terminal processing mode, the calculation mode is complex, and response has delay.
In the related art, the calculation mode of the total playing time length when multi-terminal playing occurs is more complicated. The calculation of the duration is not only required to record according to the playing and stopping of the video, but also is required to judge whether the time interval accords with the preset time interval. It is necessary to determine whether to continue recording the duration by continuously receiving the calculated time interval when recording the duration is performed. The time length recording mode is complex, and when delay occurs on the multi-terminal processing problem, the time length recording can correspondingly delay. When the second client is opened to play the video, the problem of multiple ends is possibly found to be untimely, the duration of the first client is recorded, meanwhile, the second client also starts to record the duration, the playing durations of the two clients are overlapped, errors are generated in the recording of the total duration, and the accuracy is low.
In view of this, one or more embodiments of the present disclosure provide a solution for recording online learning duration, where in the online learning process, the solution can determine whether the same user opens another client to learn according to the unique identifier of the user and the random code of the client, so as to avoid that the same user opens multiple clients to learn online at the same time. The online learning of the client is stopped, and the recording of the learning time of the client is stopped, so that the response is rapid, the learning time of only one client can be recorded at the same time, and the repeated accumulation of the learning time is avoided. And adding the learning time lengths of the same user on each client to obtain the total learning time length, and accurately and conveniently recording the online learning time length of the user. The technical scheme of each specific embodiment of the application is described below.
Referring to fig. 1, a method of recording online learning duration according to one embodiment of the present specification includes the steps of:
step S101, a first request message is received, where the first request message includes a first user unique identifier and a first client random code.
In this step, after receiving the first request message, the first user unique identifier and the first client random code in the first request message are obtained. The first user unique identification is generated after the user logs in, and the user unique identification is identity information of the user. Each user can be distinguished according to the unique user identification, and cross errors of data recording are avoided when other data are recorded. When a user opens a first client, a first client random code is generated. The client random code is identification information of the client, and the client can be determined according to the client random code. Thus, the user and the client can be determined from the first request message.
As a specific application scene, a user opens a learning platform, inputs an account number and a password to log in, obtains user information, and generates a unique user identifier according to the user information. And creating a session, and storing the user information and the user unique identification into the session. When each user logs in, a corresponding session is created, and one session corresponds to one user, so that information record disorder is avoided. When the user logs out, the corresponding session also disappears. After the user logs in, the video playing page is opened for online learning, and the opened client generates a client random code, and the client random code is stored for marking the client. When a request message is sent to a server, the stored user unique identification and the client random code are found and are put into the request message as request parameters to be sent to the server together.
Step S102, controlling a first client corresponding to the first client random code to perform online learning, and recording a first learning duration.
In this step, a first user unique identifier and a first client random code in the first request information are recorded, and a corresponding first client is determined according to the first client random code, and the first client can obtain the corresponding authority of online learning. While the first client performs online learning, the server records a first learning duration of the first client. The online learning can be live-broadcast class learning or recorded-broadcast class learning.
Step S103, a second request message is received, wherein the second request message comprises a second user unique identifier and a second client random code.
In this step, after receiving the second request message, the second user unique identifier and the second client random code in the second request message are obtained to mark the user and the client.
Step S104, in response to determining that the first user unique identifier is the same as the second user unique identifier, the first client random code is different from the second client random code, stopping online learning of the first client and recording of the first learning duration, controlling the second client corresponding to the second client random code to perform online learning, and recording of the second learning duration.
In this step, when recording the second user unique identification and the second client random code contained in the second request message is performed, the server finds that the user unique identification and the client random code have been recorded. Thus, comparing the first user unique identifier with the second user unique identifier, the same user unique identifier will be considered to be the same user. And comparing the first client random code with the second client random code, wherein the client random code is identification information of the client, and the random codes of different clients are different. If the first user unique identification and the second user unique identification are the same, the description is the same user. And the first client random code is different from the second client random code, then the description is two different clients. By comparing the unique user identifier and the client random code in the two request messages, whether one user opens two clients simultaneously can be judged.
And determining that the same user opens a second client, stopping online learning of the first client and stopping recording of the first learning duration in order to avoid online learning of multiple ends. And simultaneously recording a second user unique identifier and a second client random code in the second request information, and determining a corresponding second client according to the second client random code, wherein the second client obtains corresponding learning permission. While the second client performs online learning, the server records a second learning duration at the second client. When the multi-terminal problem occurs, the learning of the previous client is stopped, and the online learning is started on the new client, so that multi-terminal conflict during playing is avoided. The second client may be a different tab located in the same browser as the first client, or may be a tab located in a different browser than the first client, or may be an H5 client, which is not limited herein.
Step 105, taking the sum of the first learning duration and the second learning duration as the online learning duration of the target user corresponding to the first user unique identifier.
In the step, the calculation of the total online learning time length is to determine the learning time lengths of the same user and different clients according to the unique user identification, and then accumulate the learning time lengths of the same user on the clients to obtain the total online learning time length, so that the online learning time length can be recorded more simply and conveniently.
In one particular implementation scenario, referring to FIG. 2, a process for server and client interaction is presented. And the user logs in the learning platform, and opens the first client to perform online learning. After the first client is opened, first request information needs to be sent to the server to request to start playing the video. The first request information includes parameters including a first user unique identification and a first client random code. After receiving the first request message, the server records the first user unique identification and the first client random code and responds to the first client. And after receiving the first request success message, the first client starts playing the video, and simultaneously, the learning duration is recorded locally. And in the process of playing the video by the first client, continuously reporting the first learning duration to the server, and updating and recording the first learning duration by the server. When the user opens another client, the second client also needs to send request information to the server before playing the video, and requests to start playing the video. The second request information includes parameters including a second user unique identifier and a second client random code. And after receiving the second request message, the server records the unique identifier of the second user and the random code of the second client. In the recording process, the server finds that the unique user identification and the client random code exist, compares the unique user identification with the client random code, and judges whether the same user opens two clients to perform online learning. When the unique identification of the user is found to be the same and the random codes of the clients are different, the same user is indicated to open two clients at the same time. At this time, the server needs to respond to the two clients, and keeps one client to continue online learning. And thus sending disconnection information to the first client, stopping online learning of the first client, and simultaneously stopping recording of the learning duration of the first client. And sending the learning duration of the video termination to the server while the first client stops playing the video, so as to obtain the total duration of the learning of the user on the first client. And sending second request success information to the second client, starting playing the learning video after the second client receives the second request success information, and recording a second learning duration. And in the online learning process of the second client, continuously reporting a second learning duration to the server, and updating and recording the second learning duration by the server.
From the above, it can be seen that in the online learning process, the embodiment of the application can determine whether the same user opens another client for learning according to the unique user identifier and the client random code, thereby avoiding that the same user opens a plurality of clients for online learning at the same time. The online learning of the client is stopped, and the recording of the learning time of the client is stopped, so that the response is rapid, the learning time of only one client can be recorded at the same time, and the repeated accumulation of the learning time is avoided. And adding the learning time lengths of the same user on each client to obtain the total learning time length, and accurately and conveniently recording the online learning time length of the user.
In some embodiments, controlling the first client corresponding to the first client random code to perform online learning, and recording a first learning duration, including:
and sending first request success information to the first client to control the first client to perform online learning.
Establishing a first message channel connected with the first client, and determining the first learning duration according to data received by the first message channel.
In this embodiment, the first request success information is sent to the first client, and the first client starts playing the learning video after receiving the first request success information. The learning video may be a recorded lesson local to the client or a live lesson, which is not specifically limited herein. And simultaneously, a first message channel connected with the first client is established, and the first client locally records first learning duration data. A first message channel is established between the server and the first client, and two ports of the first message channel are respectively connected to the server and the first client. The first message channel conforms to a message protocol when transmitting the first learning duration. In the transmission process, the transmission efficiency is higher, and the response is timely. In the online learning process of the first client, the first message channel always keeps a connection state, and the first learning duration can be directly transmitted to the server through the message channel. When the first client performs online learning, the first message channel always exists, and when the first learning duration is recorded, whether the first learning duration is continuously recorded or not is not required to be judged, and the first message channel can be directly used for transmitting. When the first learning duration is transmitted, the first client does not need to send a message transmission request to the server every time, so that response time is reduced.
In the online learning process, first learning duration data are received through a first message channel, and first learning duration is determined according to the first learning duration data. The first learning duration may be a learning duration directly recorded locally at the first client, where the first learning duration is sent to the server at intervals of a certain duration. Or starting on-line learning at the first client, setting a fixed interval time in advance, sending a time length recording message to the server every time the first client has a fixed interval time, accumulating the time length recording message on the original time length after the server receives the request, and accumulating a fixed interval time length every time the time length recording message is received, so as to obtain the first learning time length. The recording manner of the first learning period is not particularly limited herein.
In some embodiments, determining the first learning duration from the data received by the first message channel includes:
and receiving a first initial moment sent by the first client through the first message channel.
And receiving the first moment sent by the first client at intervals of a certain duration.
And subtracting the first initial time from the latest received first time to obtain the first learning duration.
In this embodiment, for the data received according to the first message channel, the determining the first learning duration may be that, when online learning starts on the first client, a first initial time sent by the first client is received through the first message channel, where the first initial time is a time when online learning starts on the first client. And receiving the first moment sent by the first client at intervals of a certain time length, wherein the first moment is continuously updated. Subtracting the first initial time from the latest received first time to obtain a first learning time, and continuously updating the first learning time. The first moment sent by the first client is received at certain intervals, so that online learning can be ensured not to be disconnected. The method for calculating the time length is quicker by subtracting the first initial time from the received latest first time. And the record of the first learning duration is not influenced by the first moment received before, the latest first learning duration is not influenced when errors occur in the data transmission process, and the recorded first learning duration has higher accuracy.
In some embodiments, stopping online learning of the first client and recording of the first learning duration includes:
And sending disconnection information to the first client to stop online learning of the first client.
Disconnecting the first message channel with the first client to stop recording of the first learning duration.
In this embodiment, after the first client receives the disconnection information, the online learning of the first client is stopped. And meanwhile, the first message channel is disconnected, and after the first message channel is disconnected, the first client cannot continuously report the learning duration to the server, so that the first client stops online learning and records of the first learning duration. After the first message channel is disconnected, if the first client is still recording learning duration, the first message channel connected with the server is disconnected when the server is reported, and the duration cannot be continuously uploaded. Therefore, the problem that the first learning duration is continuously reported is avoided, the record of the first learning duration is more accurate, and the problem that a plurality of client learning durations are repeatedly recorded is avoided.
In some embodiments, after sending the disconnect information to the first client, further comprising:
and receiving a third moment sent by the first client through the first message channel.
And subtracting the first initial time from the third time to obtain the first learning duration.
In this embodiment, after receiving the disconnection information, the first client reports a third time to the server, where the third time is a termination time when the first client stops online learning. Subtracting the first initial time from the third time to obtain a final first learning duration. The obtained first learning duration is the total duration of the user learning at the first client, and is used for accumulating the total duration of the user learning at other clients to obtain the total learning duration of the user.
In some embodiments, controlling the second client corresponding to the second client random code to perform online learning, and recording a second learning duration, including:
and sending second request success information to the second client to control the second client to perform online learning.
And establishing a second message channel connected with the second client, and determining the second learning duration according to the data received by the second message channel.
In this embodiment, the second request success information is sent to the second client, and the second client starts playing the learning video after receiving the second request success information. The learning video may be a recorded lesson local to the client or a live lesson, which is not particularly limited herein. And simultaneously, a second message channel connected with a second client is established, and the second client locally records second learning duration data. And a second message channel is established between the server and the second client, and two ports of the second message channel are respectively connected to the server and the second client. And the second message channel accords with the message protocol when the second learning duration is transmitted. In the online learning process of the second client, the second message channel is always kept in a connection state, and the second learning duration can be directly transmitted to the server through the message channel without judging whether to continuously record the second learning duration. When the second learning duration is transmitted, the second client does not need to send a message transmission request to the server every time, and response time is reduced.
And in the online learning process, receiving second learning duration data through a second message channel, and determining a second learning duration according to the second learning duration data. The second learning duration may be a learning duration locally and directly recorded at the second client, where the second learning duration is sent to the server at intervals of a certain duration. Or starting on-line learning at the second client, setting a fixed interval time in advance, sending a time length recording message to the server every time the second client has a fixed interval time, accumulating the time length recording message on the original time length after the server receives the request, and accumulating a fixed interval time length every time the time length recording message is received. The recording manner of the second learning period is not particularly limited herein.
In some embodiments, determining the second learning duration from the data received by the second message channel includes:
and receiving a second initial moment sent by the second client through the second message channel.
And receiving a second moment sent by the second client at intervals of a certain duration.
And subtracting the second initial time from the latest received second time to obtain the second learning duration.
In this embodiment, for the data received according to the second message channel, the determining the second learning duration may be when online learning starts on the second client, and the second initial time sent by the second client is received through the second message channel, where the second initial time is a time when online learning starts on the second client. And receiving a second moment sent by the second client at intervals of a certain time length, wherein the second moment is continuously updated. Subtracting the second initial time from the latest received second time to obtain a second learning time, and continuously updating the second learning time. The second moment sent by the second client is received at certain intervals, so that online learning can be ensured not to be disconnected. The method for calculating the time length is quicker by subtracting the second initial time from the latest second time received. And the record of the second learning duration is not influenced by the second moment received before, the latest second learning duration is not influenced when errors occur in the data transmission process, and the recorded second learning duration has higher accuracy.
It should be noted that, the method of the embodiment of the present application may be performed by a single device, for example, a computer or a server. The method of the embodiment can also be applied to a distributed scene, and is completed by mutually matching a plurality of devices. In the case of such a distributed scenario, one of the devices may perform only one or more steps of the method of an embodiment of the present application, the devices interacting with each other to accomplish the method.
It should be noted that the foregoing describes some embodiments of the present application. Other embodiments are within the scope of the following claims. In some cases, the actions or steps recited in the claims may be performed in a different order than in the embodiments described above and still achieve desirable results. In addition, the processes depicted in the accompanying figures do not necessarily require the particular order shown, or sequential order, to achieve desirable results. In some embodiments, multitasking and parallel processing are also possible or may be advantageous.
Based on the same inventive concept, the application also provides a device for recording the online learning time length, which corresponds to the method of any embodiment.
Referring to fig. 3, the apparatus for recording online learning duration includes:
a first message receiving module 301 configured to receive a first request message, the first request message comprising a first user unique identification and a first client random code;
the first learning module 302 is configured to control a first client corresponding to the first client random code to perform online learning, and record a first learning duration;
a second message receiving module 303 configured to receive a second request message, the second request message comprising a second user unique identification and a second client random code;
A second learning module 304 configured to, in response to determining that the first user unique identifier is the same as the second user unique identifier and the first client random code is different from the second client random code, stop online learning of the first client and recording of the first learning duration, control a second client corresponding to the second client random code to perform online learning, and record a second learning duration;
a duration module 305, configured to take the sum of the first learning duration and the second learning duration as an online learning duration of the target user corresponding to the first user unique identifier.
As an alternative embodiment, the first learning module 302 is further configured to:
sending first request success information to the first client to control the first client to perform online learning;
establishing a first message channel connected with the first client, and determining the first learning duration according to data received by the first message channel.
As an alternative embodiment, the first learning module 302 is further configured to:
receiving a first initial moment sent by the first client through the first message channel;
Receiving a first moment sent by the first client at intervals of a certain duration;
and subtracting the first initial time from the latest received first time to obtain the first learning duration.
As an alternative embodiment, the second learning module 304 is further configured to:
sending disconnection information to the first client to stop online learning of the first client;
disconnecting the first message channel with the first client to stop recording of the first learning duration.
As an alternative embodiment, the second learning module 304 is further configured to:
receiving a third moment sent by the first client through the first message channel;
and subtracting the first initial time from the third time to obtain the first learning duration.
As an alternative embodiment, the second learning module 304 is further configured to:
sending second request success information to the second client to control the second client to perform online learning;
and establishing a second message channel connected with the second client, and determining the second learning duration according to the data received by the second message channel.
As an alternative embodiment, the second learning module 304 is further configured to:
receiving a second initial moment sent by the second client through the second message channel;
receiving a second moment sent by the second client at intervals of a certain duration;
and subtracting the second initial time from the latest received second time to obtain the second learning duration.
For convenience of description, the above devices are described as being functionally divided into various modules, respectively. Of course, the functions of each module may be implemented in the same piece or pieces of software and/or hardware when implementing the present application.
The device of the foregoing embodiment is used for implementing the corresponding method for recording the online learning duration in any of the foregoing embodiments, and has the beneficial effects of the corresponding method embodiment, which is not described herein.
Based on the same inventive concept, the application also provides an electronic device corresponding to the method of any embodiment, which comprises a memory, a processor and a computer program stored on the memory and capable of running on the processor, wherein the processor realizes the method for recording the online learning duration according to any embodiment when executing the program.
Fig. 4 shows a more specific hardware architecture of an electronic device according to this embodiment, where the device may include: processor 410, memory 420, input/output interface 430, communication interface 440, and bus 450. Wherein processor 410, memory 420, input/output interface 430, and communication interface 1040 implement communication connections between each other within the device via bus 450.
The processor 410 may be implemented by a general-purpose CPU (Central Processing Unit ), a microprocessor, an application-specific integrated circuit (Application Specific Integrated Circuit, ASIC), or one or more integrated circuits, etc. for executing relevant programs to implement the technical solutions provided in the embodiments of the present disclosure.
The Memory 420 may be implemented in the form of ROM (Read Only Memory), RAM (Random Access Memory ), static storage device, dynamic storage device, or the like. Memory 420 may store an operating system and other application programs, and when the technical solutions provided by the embodiments of the present specification are implemented in software or firmware, the relevant program codes are stored in memory 420 and invoked for execution by processor 410.
The input/output interface 430 is used to connect with an input/output module to realize information input and output. The input/output module may be configured as a component in a device (not shown) or may be external to the device to provide corresponding functionality. Wherein the input devices may include a keyboard, mouse, touch screen, microphone, various types of sensors, etc., and the output devices may include a display, speaker, vibrator, indicator lights, etc.
The communication interface 440 is used to connect communication modules (not shown) to enable communication interactions of the device with other devices. The communication module may implement communication through a wired manner (such as USB, network cable, etc.), or may implement communication through a wireless manner (such as mobile network, WIFI, bluetooth, etc.).
Bus 450 includes a path to transfer information between components of the device (e.g., processor 410, memory 420, input/output interface 430, and communication interface 440).
It should be noted that although the above device only shows the processor 410, the memory 420, the input/output interface 430, the communication interface 440, and the bus 450, in the implementation, the device may further include other components necessary to achieve normal operation. Furthermore, it will be understood by those skilled in the art that the above-described apparatus may include only the components necessary to implement the embodiments of the present description, and not all the components shown in the drawings.
The electronic device of the foregoing embodiment is configured to implement the corresponding method for recording the online learning duration in any of the foregoing embodiments, and has the beneficial effects of the corresponding method embodiment, which is not described herein.
Based on the same inventive concept, the present application also provides a non-transitory computer readable storage medium storing computer instructions for causing the computer to perform the method of recording online learning duration according to any of the embodiments above, corresponding to the method of any of the embodiments above.
The computer readable media of the present embodiments, including both permanent and non-permanent, removable and non-removable media, may be used to implement information storage by any method or technology. The information may be computer readable instructions, data structures, modules of a program, or other data. Examples of storage media for a computer include, but are not limited to, phase change memory (PRAM), static Random Access Memory (SRAM), dynamic Random Access Memory (DRAM), other types of Random Access Memory (RAM), read Only Memory (ROM), electrically Erasable Programmable Read Only Memory (EEPROM), flash memory or other memory technology, compact disc read only memory (CD-ROM), digital Versatile Discs (DVD) or other optical storage, magnetic cassettes, magnetic tape magnetic disk storage or other magnetic storage devices, or any other non-transmission medium, which can be used to store information that can be accessed by a computing device.
The storage medium of the foregoing embodiment stores computer instructions for causing the computer to execute the method for recording the online learning duration according to any one of the foregoing embodiments, and has the beneficial effects of the corresponding method embodiments, which are not described herein.
Those of ordinary skill in the art will appreciate that: the discussion of any of the embodiments above is merely exemplary and is not intended to suggest that the scope of the application (including the claims) is limited to these examples; the technical features of the above embodiments or in the different embodiments may also be combined within the idea of the application, the steps may be implemented in any order, and there are many other variations of the different aspects of the embodiments of the application as described above, which are not provided in detail for the sake of brevity.
Additionally, well-known power/ground connections to Integrated Circuit (IC) chips and other components may or may not be shown within the provided figures, in order to simplify the illustration and discussion, and so as not to obscure the embodiments of the present application. Furthermore, the devices may be shown in block diagram form in order to avoid obscuring the embodiments of the present application, and also in view of the fact that specifics with respect to implementation of such block diagram devices are highly dependent upon the platform within which the embodiments of the present application are to be implemented (i.e., such specifics should be well within purview of one skilled in the art). Where specific details (e.g., circuits) are set forth in order to describe example embodiments of the application, it should be apparent to one skilled in the art that embodiments of the application can be practiced without, or with variation of, these specific details. Accordingly, the description is to be regarded as illustrative in nature and not as restrictive.
While the application has been described in conjunction with specific embodiments thereof, many alternatives, modifications, and variations of those embodiments will be apparent to those skilled in the art in light of the foregoing description. For example, other memory architectures (e.g., dynamic RAM (DRAM)) may use the embodiments discussed.
The present embodiments are intended to embrace all such alternatives, modifications and variances which fall within the broad scope of the appended claims. Therefore, any omissions, modifications, equivalent substitutions, improvements, and the like, which are within the spirit and principles of the embodiments of the application, are intended to be included within the scope of the application.

Claims (10)

1. A method of recording an online learning period, comprising:
receiving a first request message, wherein the first request message comprises a first user unique identifier and a first client random code;
controlling a first client corresponding to the first client random code to perform online learning, and recording a first learning duration;
receiving a second request message, wherein the second request message comprises a second user unique identifier and a second client random code;
comparing the first user unique identifier with the second user unique identifier, and comparing the first client random code with the second client random code;
In response to determining that the first user unique identifier is the same as the second user unique identifier and the first client random code is different from the second client random code, stopping online learning of the first client and recording of the first learning duration, controlling a second client corresponding to the second client random code to perform online learning, and recording a second learning duration;
and taking the sum of the first learning duration and the second learning duration as the online learning duration of the target user corresponding to the unique identification of the first user.
2. The method for recording online learning duration according to claim 1, wherein the controlling the first client corresponding to the first client random code to perform online learning and recording the first learning duration includes:
sending first request success information to the first client to control the first client to perform online learning;
establishing a first message channel connected with the first client, and determining the first learning duration according to data received by the first message channel.
3. The method of recording an online learning period of claim 2, wherein the determining the first learning period based on the data received by the first message channel comprises:
Receiving a first initial moment sent by the first client through the first message channel;
receiving a first moment sent by the first client at intervals of a certain duration;
and subtracting the first initial time from the latest received first time to obtain the first learning duration.
4. The method of recording an online learning period of claim 3, wherein the stopping the online learning of the first client and the recording of the first learning period comprises:
sending disconnection information to the first client to stop online learning of the first client;
disconnecting the first message channel with the first client to stop recording of the first learning duration.
5. The method for recording online learning time period of claim 4, wherein after the sending of the disconnection information to the first client, further comprising:
receiving a third moment sent by the first client through the first message channel;
and subtracting the first initial time from the third time to obtain the first learning duration.
6. The method for recording online learning duration according to claim 1, wherein the controlling the second client corresponding to the second client random code to perform online learning and recording the second learning duration includes:
Sending second request success information to the second client to control the second client to perform online learning;
and establishing a second message channel connected with the second client, and determining the second learning duration according to the data received by the second message channel.
7. The method of recording an online learning period of claim 6, wherein the determining the second learning period based on the data received by the second message channel comprises:
receiving a second initial moment sent by the second client through the second message channel;
receiving a second moment sent by the second client at intervals of a certain duration;
and subtracting the second initial time from the latest received second time to obtain the second learning duration.
8. An apparatus for recording online learning duration, comprising:
a first message receiving module configured to receive a first request message, the first request message comprising a first user unique identification and a first client random code;
the first learning module is configured to control a first client corresponding to the first client random code to perform online learning and record a first learning duration;
A second message receiving module configured to receive a second request message, the second request message comprising a second user unique identification and a second client random code;
a comparison module configured to compare the first user unique identification with the second user unique identification, and to compare the first client random code with the second client random code;
the second learning module is configured to respond to the fact that the first user unique identifier is the same as the second user unique identifier, the first client random code is different from the second client random code, stop online learning of the first client and recording of the first learning duration, control the second client corresponding to the second client random code to perform online learning, and record second learning duration;
and the duration module is configured to take the sum of the first learning duration and the second learning duration as the online learning duration of the target user corresponding to the first user unique identifier.
9. An electronic device comprising a memory, a processor and a computer program stored on the memory and executable on the processor, wherein the processor implements the method of any one of claims 1 to 7 when the program is executed by the processor.
10. A non-transitory computer readable storage medium storing computer instructions for causing the computer to implement the method of any one of claims 1 to 7.
CN202111546761.3A 2021-12-16 2021-12-16 Method for recording online learning duration and related equipment Active CN114449026B (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN202111546761.3A CN114449026B (en) 2021-12-16 2021-12-16 Method for recording online learning duration and related equipment

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN202111546761.3A CN114449026B (en) 2021-12-16 2021-12-16 Method for recording online learning duration and related equipment

Publications (2)

Publication Number Publication Date
CN114449026A CN114449026A (en) 2022-05-06
CN114449026B true CN114449026B (en) 2023-09-22

Family

ID=81364244

Family Applications (1)

Application Number Title Priority Date Filing Date
CN202111546761.3A Active CN114449026B (en) 2021-12-16 2021-12-16 Method for recording online learning duration and related equipment

Country Status (1)

Country Link
CN (1) CN114449026B (en)

Families Citing this family (1)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN115660910B (en) * 2022-10-29 2023-09-19 中国人民解放军国防科技大学 Learning duration calculation method and system

Citations (4)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
KR20120079918A (en) * 2011-01-06 2012-07-16 (주)비상교과서 Learning services providing method and system
CN106781753A (en) * 2017-01-06 2017-05-31 广州网才信息技术有限公司 A kind of training system suitable for different mobile terminal
CN109151602A (en) * 2018-09-26 2019-01-04 浙江浙大万朋软件有限公司 A kind of method of video class record on-line study duration
CN112016029A (en) * 2020-09-01 2020-12-01 北京弘远博学科技有限公司 Method for synchronously recording courseware learning of multiple terminals

Family Cites Families (1)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US10497272B2 (en) * 2016-11-23 2019-12-03 Broadband Education Pte. Ltd. Application for interactive learning in real-time

Patent Citations (4)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
KR20120079918A (en) * 2011-01-06 2012-07-16 (주)비상교과서 Learning services providing method and system
CN106781753A (en) * 2017-01-06 2017-05-31 广州网才信息技术有限公司 A kind of training system suitable for different mobile terminal
CN109151602A (en) * 2018-09-26 2019-01-04 浙江浙大万朋软件有限公司 A kind of method of video class record on-line study duration
CN112016029A (en) * 2020-09-01 2020-12-01 北京弘远博学科技有限公司 Method for synchronously recording courseware learning of multiple terminals

Non-Patent Citations (1)

* Cited by examiner, † Cited by third party
Title
"2018年中国科学院继续教育网科研人员在线学习数据集";赵以霞 等;《中国科学数据(中英文网络版)》;全文 *

Also Published As

Publication number Publication date
CN114449026A (en) 2022-05-06

Similar Documents

Publication Publication Date Title
CN106202453B (en) Multimedia resource recommendation method and device
US10726068B2 (en) App processing method and apparatus
US9788206B2 (en) Method and apparatus for sharing content
CN105099811A (en) Interface testing method and device
US11094215B2 (en) Internet-based recorded course learning following system and method
CN107182042B (en) Short message channel quality evaluation method, device, medium and system
CN110022260B (en) Cross-environment receipt message processing method and system
CN104216630A (en) Interface sharing method and interface sharing device
CN114449026B (en) Method for recording online learning duration and related equipment
CN112203111A (en) Multimedia resource preloading method and device, electronic equipment and storage medium
CN111209417A (en) Information display method, server, terminal and storage medium
CN111694757B (en) Application program testing method and device, electronic equipment and computer readable storage medium
CN111309632A (en) Application program testing method and device, computer equipment and storage medium
CN110022327B (en) Short message authentication test method and device
CN106909481B (en) Interface test method, interface test device and electronic equipment
CN110060477B (en) Method and device for pushing information
CN109348298B (en) Method and equipment for pushing and playing multimedia data stream
CN109344052B (en) Interface automation test method and device and electronic equipment
CN116257882A (en) Voting method, voting system, electronic equipment and storage medium
CN116662193A (en) Page testing method and device
CN108009247B (en) Information pushing method and device
CN113626402A (en) Log data acquisition method and device, electronic equipment and storage medium
CN111581356B (en) User behavior path analysis method and device
CN111935501B (en) Scene recognition method and device
CN108345418B (en) Interactive object display method and device in online teaching

Legal Events

Date Code Title Description
PB01 Publication
PB01 Publication
SE01 Entry into force of request for substantive examination
SE01 Entry into force of request for substantive examination
GR01 Patent grant
GR01 Patent grant